Skip to content

Commit

Permalink
chore: set github workflow to be triggered manually or on push to set…
Browse files Browse the repository at this point in the history
… path
  • Loading branch information
eshiettjoseph committed Feb 8, 2024
1 parent f3052b4 commit 70635f3
Showing 1 changed file with 3 additions and 19 deletions.
22 changes: 3 additions & 19 deletions .github/workflows/terraform.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
on:
workflow_dispatch:
push:
paths:
- terraform/infrastructure
branches:
- main
pull_request:
Expand All @@ -14,27 +17,8 @@ jobs:
- name: Checkout
uses: actions/checkout@v3


# Don't trigger associated workflow until changes made to filters as set below
changes:
runs-on: ubuntu-latest
outputs:
backend: ${{ steps.changes.outputs.backend }}
ecr: ${{ steps.changes.outputs.ecr }}
infra: ${{ steps.changes.outputs.infra }}
steps:
- uses: actions/checkout@v3
- uses: dorny/paths-filter@v2
id: changes
with:
filters: |
infra:
- 'terraform/infrastructure/**'
infra:
runs-on: ubuntu-latest
needs: changes
if: ${{ needs.changes.outputs.infra == 'true' }}
defaults:
run:
working-directory: terraform/infrastructure
Expand Down

0 comments on commit 70635f3

Please sign in to comment.