Skip to content

Commit

Permalink
ci: removing env from deploy so workflow can set (#1029)
Browse files Browse the repository at this point in the history
  • Loading branch information
cberg-aot authored Jan 5, 2024
1 parent a91f0ea commit 98ab32e
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ on:
required: false
type: string
default: ${{ github.event.number }}
namespace:
license:
description: 'BC Gov LICENSE_PLATE of deployment env'
required: false
type: string
Expand All @@ -51,6 +51,7 @@ on:
required: false
type: string


### Usually a bad idea / not recommended
directory:
description: 'Chart directory.'
Expand Down Expand Up @@ -100,7 +101,7 @@ on:
required: false
type: string
default: "latest"
namespace:
license:
description: 'BC Gov LICENSE_PLATE of deployment env'
required: false
type: string
Expand Down Expand Up @@ -141,7 +142,6 @@ jobs:
# https://github.com/bcgov-nr/action-deployer-openshift
deploys:
name: Helm
environment: ${{ inputs.environment }}
runs-on: ubuntu-22.04
timeout-minutes: 10
steps:
Expand Down Expand Up @@ -180,8 +180,8 @@ jobs:
working-directory: ${{ inputs.directory }}
shell: bash
run: |
oc login --token=${{ secrets.oc_token }} --server=${{ vars.oc_server }}
oc project ${{ vars.OC_NAMESPACE }} # Safeguard!
oc login --token=${{ secrets.OC_TOKEN }} --server=${{ vars.OC_SERVER }}
oc project ${{inputs.license}}-{{inputs.environment}} # Safeguard!
# Interrupt any previous jobs (status = pending-upgrade)
PREVIOUS=$(helm status ${{ env.repo_release }} -o json | jq .info.status || true)
Expand All @@ -197,7 +197,7 @@ jobs:
--set global.autoscaling=${{ inputs.autoscaling || true }} \
--set-string global.repository=${{ github.repository }} \
--set-string global.tag=${{ inputs.tag }} \
--set-string global.license=${{ inputs.namespace }} \
--set-string global.license=${{ inputs.license }} \
--set-string global.zone=${{ inputs.environment }} \
--set-string global.vault.role=${{ inputs.vault_role }} \
--set-string global.vault.zone=${{ inputs.vault_zone }} \
Expand All @@ -206,7 +206,6 @@ jobs:
--values ${{ inputs.values }} \
${{ inputs.params }} .
# print history
helm history ${{ env.repo_release }}
Expand Down

0 comments on commit 98ab32e

Please sign in to comment.