Skip to content

Commit

Permalink
feat(ci): Adjust CI for workflow dispatch
Browse files Browse the repository at this point in the history
  • Loading branch information
sylus committed Apr 20, 2024
1 parent dce167e commit 47a3122
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 33 deletions.
14 changes: 0 additions & 14 deletions .github/workflows/dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,3 @@ jobs:
branch: main
directory: tenant-gitops
repository: bcgov-c/tenant-gitops-ea352d

- name: Deploy to Test Workflow
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
event-type: 'Deploy to Test'
client-payload: '{"ref": "${{ github.ref }}", "sha": "${{ github.sha }}"}'

- name: Deploy to Prod Workflow
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
event-type: 'Deploy to Prod'
client-payload: '{"ref": "${{ github.ref }}", "sha": "${{ github.sha }}"}'
10 changes: 0 additions & 10 deletions .github/workflows/prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,9 @@ name: Deploy to Prod

on:
workflow_dispatch:
inputs:
approve:
description: 'Approve Deploy to Prod.'
required: true
type: boolean

jobs:
build:
if: ${{ github.event.inputs.approve == 'true' }}
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@master
Expand All @@ -25,16 +19,12 @@ jobs:

- name: Update Argo CD
uses: mikefarah/[email protected]
env:
GITHUB_REFERENCE: ${{ github.event.inputs.tag }}
with:
cmd: |
yq -i '.drupal.tag = strenv(GITHUB_REFERENCE) |
.nginx.tag = strenv(GITHUB_REFERENCE) ' tenant-gitops/helm-drupal/charts/drupal/values-mfin-data-catalogue-prod.yaml
- name: Commit files
env:
GITHUB_REFERENCE: ${{ github.event.inputs.tag }}
run: |
cd tenant-gitops
git config --local user.email "github-actions[bot]@users.noreply.github.com"
Expand Down
9 changes: 0 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@ name: Deploy to Test

on:
workflow_dispatch:
inputs:
approve:
description: 'Approve Deploy to Test.'
required: true
type: boolean

jobs:
build:
Expand All @@ -25,16 +20,12 @@ jobs:

- name: Update Argo CD
uses: mikefarah/[email protected]
env:
GITHUB_REFERENCE: ${{ github.event.inputs.tag }}
with:
cmd: |
yq -i '.drupal.tag = strenv(GITHUB_REFERENCE) |
.nginx.tag = strenv(GITHUB_REFERENCE) ' tenant-gitops/helm-drupal/charts/drupal/values-mfin-data-catalogue-test.yaml
- name: Commit files
env:
GITHUB_REFERENCE: ${{ github.event.inputs.tag }}
run: |
cd tenant-gitops
git config --local user.email "github-actions[bot]@users.noreply.github.com"
Expand Down

0 comments on commit 47a3122

Please sign in to comment.