Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: remove BS NR VAULT #65

Merged
merged 1 commit into from
Feb 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 5 additions & 27 deletions .github/workflows/pr-open.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,29 +56,7 @@ jobs:
secret_path_env: dev # this path is different from the path in the broker
steps:
- uses: actions/checkout@v4
- name: Broker
id: broker
uses: bcgov-nr/action-vault-broker-approle@v1.1.0
with:
broker_jwt: ${{ secrets.BROKER_JWT }}
provision_role_id: ${{ secrets.PROVISION_ROLE }}
project_name: ${{ env.project_name }}
app_name: ${{ env.app_name }}
environment: ${{ env.environment }}
- name: Import Secrets
id: secrets
uses: hashicorp/vault-action@v2.7.5
with:
url: https://vault-iit.apps.silver.devops.gov.bc.ca
token: ${{ steps.broker.outputs.vault_token }}
exportEnv: 'true'
secrets: |
apps/data/${{ env.secret_path_env }}/${{ env.project_name }}/${{ env.app_name }}/rar dbHost | DB_HOST;
apps/data/${{ env.secret_path_env }}/${{ env.project_name }}/${{ env.app_name }}/rar dbName | DB_NAME;
apps/data/${{ env.secret_path_env }}/${{ env.project_name }}/${{ env.app_name }}/rar dbPassword | DB_PWD;
apps/data/${{ env.secret_path_env }}/${{ env.project_name }}/${{ env.app_name }}/rar dbUser | DB_USER;



- name: Deploy to Openshift
working-directory: charts/nr-oracle-service
shell: bash
Expand All @@ -93,10 +71,10 @@ jobs:
helm package --app-version="${{ github.event.number }}" --version=${{ github.event.number }} .

helm upgrade \
--set-string app.envs.DB_HOST=${{ steps.secrets.outputs.DB_HOST }} \
--set-string app.envs.DB_NAME=${{ steps.secrets.outputs.DB_NAME }} \
--set-string app.envs.DB_PASSWORD=${{ steps.secrets.outputs.DB_PWD }} \
--set-string app.envs.DB_USER=${{ steps.secrets.outputs.DB_USER }} \
--set-string app.envs.DB_HOST=${{ secrets.DB_HOST }} \
--set-string app.envs.DB_NAME=${{ secrets.DB_NAME }} \
--set-string app.envs.DB_PASSWORD=${{ secrets.DB_PWD }} \
--set-string app.envs.DB_USER=${{ secrets.DB_USER }} \
--set-string app.envs.DB_PORT="1543" \
--set-string image.tag="${{ github.event.number }}" \
--set-string namespace=${{ vars.oc_namespace }} \
Expand Down