Skip to content

Commit

Permalink
Adding filter back (#1624)
Browse files Browse the repository at this point in the history
  • Loading branch information
ben851 authored Oct 24, 2024
1 parent 2f72900 commit fcda637
Showing 1 changed file with 49 additions and 21 deletions.
70 changes: 49 additions & 21 deletions .github/workflows/terragrunt_plan_staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,9 @@ jobs:
- 'env/${{env.ENVIRONMENT}}/manifest_secrets/**'
terragrunt-plan-common:
if: |
needs.terragrunt-filter.outputs.common == 'true'
needs: terragrunt-filter
runs-on: ubuntu-latest
env:
COMPONENT: "common"
Expand Down Expand Up @@ -156,8 +159,10 @@ jobs:
terragrunt-plan-ecr:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
needs: terragrunt-filter
runs-on: ubuntu-latest
env:
COMPONENT: "ecr"
Expand Down Expand Up @@ -189,8 +194,10 @@ jobs:
terragrunt-plan-ecr-us-east:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
needs: terragrunt-filter
runs-on: ubuntu-latest
env:
COMPONENT: "ecr-us-east"
Expand Down Expand Up @@ -223,12 +230,13 @@ jobs:
terragrunt-plan-ses_receiving_emails:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
env:
COMPONENT: "ses_receiving_emails"
needs: [terragrunt-plan-common,terragrunt-plan-ecr,terragrunt-plan-ecr-us-east]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr,terragrunt-plan-ecr-us-east]
steps:
- name: Checkout
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
Expand Down Expand Up @@ -256,12 +264,13 @@ jobs:
terragrunt-plan-dns:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
env:
COMPONENT: "dns"
needs: [terragrunt-plan-common,terragrunt-plan-ses_receiving_emails]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ses_receiving_emails]
steps:
- name: Checkout
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
Expand Down Expand Up @@ -289,12 +298,13 @@ jobs:
terragrunt-plan-ses_validation_dns_entries:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
env:
COMPONENT: "ses_validation_dns_entries"
needs: [terragrunt-plan-common,terragrunt-plan-dns]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-dns]
steps:
- name: Checkout
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
Expand Down Expand Up @@ -322,10 +332,11 @@ jobs:
terragrunt-plan-cloudfront:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common]
needs: [terragrunt-filter,terragrunt-plan-common]
env:
COMPONENT: "cloudfront"
steps:
Expand Down Expand Up @@ -355,10 +366,11 @@ jobs:
terragrunt-plan-eks:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-dns,terragrunt-plan-cloudfront]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-dns,terragrunt-plan-cloudfront]
env:
COMPONENT: "eks"
steps:
Expand Down Expand Up @@ -388,10 +400,11 @@ jobs:
terragrunt-plan-elasticache:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-eks]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks]
env:
COMPONENT: "elasticache"
steps:
Expand Down Expand Up @@ -421,10 +434,11 @@ jobs:
terragrunt-plan-rds:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-eks]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks]
env:
COMPONENT: "rds"
steps:
Expand Down Expand Up @@ -454,10 +468,11 @@ jobs:
terragrunt-plan-lambda-api:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-ecr,terragrunt-plan-rds]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-ecr,terragrunt-plan-rds]
env:
COMPONENT: "lambda-api"
steps:
Expand Down Expand Up @@ -487,10 +502,11 @@ jobs:
terragrunt-plan-lambda-admin-pr:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-elasticache,terragrunt-plan-ecr]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-elasticache,terragrunt-plan-ecr]
env:
COMPONENT: "lambda-admin-pr"
steps:
Expand Down Expand Up @@ -520,10 +536,11 @@ jobs:
terragrunt-plan-performance-test:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-ecr]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-ecr]
env:
COMPONENT: "performance-test"
steps:
Expand Down Expand Up @@ -554,10 +571,11 @@ jobs:
terragrunt-plan-heartbeat:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-ecr]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr]
env:
COMPONENT: "heartbeat"
steps:
Expand Down Expand Up @@ -587,10 +605,11 @@ jobs:
terragrunt-plan-database-tools:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-rds]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-rds]
env:
COMPONENT: "database-tools"
steps:
Expand Down Expand Up @@ -620,10 +639,11 @@ jobs:
terragrunt-plan-quicksight:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-rds]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-rds]
env:
COMPONENT: "quicksight"
steps:
Expand Down Expand Up @@ -653,10 +673,11 @@ jobs:
terragrunt-plan-lambda-google-cidr:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-ecr]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-ecr]
env:
COMPONENT: "lambda-google-cidr"
steps:
Expand Down Expand Up @@ -686,10 +707,11 @@ jobs:
terragrunt-plan-ses_to_sqs_email_callbacks:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-ecr]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr]
env:
COMPONENT: "ses_to_sqs_email_callbacks"
steps:
Expand Down Expand Up @@ -719,10 +741,11 @@ jobs:
terragrunt-plan-sns_to_sqs_sms_callbacks:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-ecr]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr]
env:
COMPONENT: "sns_to_sqs_sms_callbacks"
steps:
Expand Down Expand Up @@ -752,10 +775,11 @@ jobs:
terragrunt-plan-pinpoint_to_sqs_sms_callbacks:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-ecr]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr]
env:
COMPONENT: "pinpoint_to_sqs_sms_callbacks"
steps:
Expand Down Expand Up @@ -785,10 +809,11 @@ jobs:
terragrunt-plan-system_status:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
runs-on: ubuntu-latest
needs: [terragrunt-plan-common,terragrunt-plan-ecr,terragrunt-plan-rds,terragrunt-plan-eks]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr,terragrunt-plan-rds,terragrunt-plan-eks]
env:
COMPONENT: "system_status"
steps:
Expand Down Expand Up @@ -818,9 +843,10 @@ jobs:
terragrunt-plan-system_status_static_site:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
needs: [terragrunt-plan-common,terragrunt-plan-system_status]
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-system_status]
runs-on: ubuntu-latest
env:
COMPONENT: "system_status_static_site"
Expand Down Expand Up @@ -851,9 +877,10 @@ jobs:
terragrunt-plan-newrelic:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
needs: [terragrunt-plan-common]
needs: [terragrunt-filter,terragrunt-plan-common]
runs-on: ubuntu-latest
env:
COMPONENT: "newrelic"
Expand Down Expand Up @@ -884,9 +911,10 @@ jobs:
terragrunt-plan-manifest_secrets:
if: |
always() &&
needs.terragrunt-filter.outputs.common == 'true' &&
!contains(needs.*.result, 'failure') &&
!contains(needs.*.result, 'cancelled')
needs: [terragrunt-plan-rds, terragrunt-plan-elasticache, terragrunt-plan-eks, terragrunt-plan-lambda-api, terragrunt-plan-lambda-admin-pr, terragrunt-plan-performance-test, terragrunt-plan-heartbeat, terragrunt-plan-database-tools, terragrunt-plan-quicksight, terragrunt-plan-lambda-google-cidr, terragrunt-plan-ses_to_sqs_email_callbacks, terragrunt-plan-sns_to_sqs_sms_callbacks, terragrunt-plan-pinpoint_to_sqs_sms_callbacks, terragrunt-plan-system_status, terragrunt-plan-system_status_static_site, terragrunt-plan-newrelic]
needs: [terragrunt-filter,terragrunt-plan-rds, terragrunt-plan-elasticache, terragrunt-plan-eks, terragrunt-plan-lambda-api, terragrunt-plan-lambda-admin-pr, terragrunt-plan-performance-test, terragrunt-plan-heartbeat, terragrunt-plan-database-tools, terragrunt-plan-quicksight, terragrunt-plan-lambda-google-cidr, terragrunt-plan-ses_to_sqs_email_callbacks, terragrunt-plan-sns_to_sqs_sms_callbacks, terragrunt-plan-pinpoint_to_sqs_sms_callbacks, terragrunt-plan-system_status, terragrunt-plan-system_status_static_site, terragrunt-plan-newrelic]
runs-on: ubuntu-latest
env:
COMPONENT: "manifest_secrets"
Expand Down

0 comments on commit fcda637

Please sign in to comment.