Add a budget alert for when we use a lot of cloudwatch data scanning #5829
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Terragrunt plan STAGING" | |
env: | |
ENVIRONMENT: staging | |
ACCOUNT_ID: ${{ secrets.STAGING_AWS_ACCOUNT_ID }} | |
AWS_REGION: ca-central-1 | |
OP_SERVICE_ACCOUNT_TOKEN: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN_STAGING }} | |
WORKFLOW: true | |
on: | |
workflow_dispatch: | |
pull_request: | |
paths: | |
- ".env" | |
- "aws/**" | |
- "env/$ENVIRONMENT/**" | |
- "env/terragrunt.hcl" | |
- "env/*.tfvars" | |
- ".github/workflows/terragrunt_plan_$ENVIRONMENT.yml" | |
permissions: | |
id-token: write # This is required for requesting the OIDC JWT | |
contents: write # This is required for actions/checkout | |
pull-requests: write | |
jobs: | |
terragrunt-filter: | |
runs-on: ubuntu-latest | |
outputs: | |
config: ${{ steps.filter.outputs.config }} | |
common: ${{ steps.filter.outputs.common }} | |
ecr: ${{ steps.filter.outputs.ecr }} | |
ecr-us-east: ${{ steps.filter.outputs.ecr-us-east }} | |
ses_receiving_emails: ${{ steps.filter.outputs.ses_receiving_emails }} | |
ses_to_sqs_email_callbacks: ${{ steps.filter.outputs.ses_to_sqs_email_callbacks }} | |
sns_to_sqs_sms_callbacks: ${{ steps.filter.outputs.sns_to_sqs_sms_callbacks }} | |
pinpoint_to_sqs_sms_callbacks: ${{ steps.filter.outputs.pinpoint_to_sqs_sms_callbacks }} | |
dns: ${{ steps.filter.outputs.dns }} | |
ses_validation_dns_entries: ${{ steps.filter.outputs.ses_validation_dns_entries }} | |
eks: ${{ steps.filter.outputs.eks }} | |
rds: ${{ steps.filter.outputs.rds }} | |
lambda-api: ${{ steps.filter.outputs.lambda-api }} | |
heartbeat: ${{ steps.filter.outputs.heartbeat }} | |
database-tools: ${{ steps.filter.outputs.database-tools }} | |
quicksight: ${{ steps.filter.outputs.quicksight }} | |
lambda-google-cidr: ${{ steps.filter.outputs.lambda-google-cidr }} | |
system_status: ${{ steps.filter.outputs.system_status }} | |
system_status_static_site: ${{ steps.filter.outputs.system_status_static_site }} | |
newrelic: ${{ steps.filter.outputs.newrelic }} | |
manifest_secrets: ${{ steps.filter.outputs.manifest_secrets }} | |
github: ${{ steps.filter.outputs.github }} | |
steps: | |
- uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 | |
id: filter | |
with: | |
filters: | | |
config: | |
- 'env/*.tfvars' | |
common: | |
- '.github/workflows/terragrunt-plan-${{env.ENVIRONMENT}}.yml' | |
- 'aws/common/**' | |
- 'env/${{env.ENVIRONMENT}}/common/**' | |
- 'env/terragrunt.hcl' | |
dns: | |
- 'aws/dns/**' | |
- 'env/${{env.ENVIRONMENT}}/dns/**' | |
ses_validation_dns_entries: | |
- 'aws/ses_validation_dns_entries/**' | |
- 'env/${{env.ENVIRONMENT}}/ses_validation_dns_entries/**' | |
ecr: | |
- 'aws/ecr/**' | |
- 'env/${{env.ENVIRONMENT}}/ecr/**' | |
ecr-us-east: | |
- 'aws/ecr-us-east/**' | |
- 'env/${{env.ENVIRONMENT}}/ecr-us-east/**' | |
eks: | |
- 'aws/eks/**' | |
- 'env/${{env.ENVIRONMENT}}/eks/**' | |
elasticache: | |
- 'aws/elasticache/**' | |
- 'env/${{env.ENVIRONMENT}}/elasticache/**' | |
rds: | |
- 'aws/rds/**' | |
- 'env/${{env.ENVIRONMENT}}/rds/**' | |
cloudfront: | |
- 'aws/cloudfront/**' | |
- 'env/${{env.ENVIRONMENT}}/cloudfront/**' | |
lambda-api: | |
- 'aws/lambda-api/**' | |
- 'env/${{env.ENVIRONMENT}}/lambda-api/**' | |
lambda-admin-pr: | |
- 'aws/lambda-admin-pr/**' | |
- 'env/${{env.ENVIRONMENT}}/lambda-admin-pr/**' | |
performance-test: | |
- 'aws/performance-test/**' | |
- 'env/${{env.ENVIRONMENT}}/performance-test/**' | |
heartbeat: | |
- 'aws/heartbeat/**' | |
- 'env/${{env.ENVIRONMENT}}/heartbeat/**' | |
database-tools: | |
- 'aws/database-tools/**' | |
- 'env/${{env.ENVIRONMENT}}/database-tools/**' | |
system_status: | |
- 'aws/system_status/**' | |
- 'env/${{env.ENVIRONMENT}}/system_status/**' | |
system_status_static_site: | |
- 'aws/system_status_static_site/**' | |
- 'env/${{env.ENVIRONMENT}}/system_status_static_site/**' | |
quicksight: | |
- 'aws/quicksight/**' | |
- 'env/${{env.ENVIRONMENT}}/quicksight/**' | |
lambda-google-cidr: | |
- 'aws/lambda-google-cidr/**' | |
- 'env/${{env.ENVIRONMENT}}/lambda-google-cidr/**' | |
ses_receiving_emails: | |
- 'aws/ses_receiving_emails/**' | |
- 'env/${{env.ENVIRONMENT}}/ses_receiving_emails/**' | |
ses_to_sqs_email_callbacks: | |
- 'aws/ses_to_sqs_email_callbacks/**' | |
- 'env/${{env.ENVIRONMENT}}/ses_to_sqs_email_callbacks/**' | |
sns_to_sqs_sms_callbacks: | |
- 'aws/sns_to_sqs_sms_callbacks/**' | |
- 'env/${{env.ENVIRONMENT}}/sns_to_sqs_sms_callbacks/**' | |
pinpoint_to_sqs_sms_callbacks: | |
- 'aws/pinpoint_to_sqs_sms_callbacks/**' | |
- 'env/${{env.ENVIRONMENT}}/pinpoint_to_sqs_sms_callbacks/**' | |
newrelic: | |
- 'aws/newrelic/**' | |
- 'env/${{env.ENVIRONMENT}}/newrelic/**' | |
manifest_secrets: | |
- 'aws/manifest_secrets/**' | |
- 'env/${{env.ENVIRONMENT}}/manifest_secrets/**' | |
github: | |
- 'aws/github/**' | |
- 'env/${{env.ENVIRONMENT}}/github/**' | |
terragrunt-plan-common: | |
if: | | |
needs.terragrunt-filter.outputs.common == 'true' || | |
needs.terragrunt-filter.outputs.config == 'true' | |
needs: terragrunt-filter | |
runs-on: ubuntu-latest | |
env: | |
COMPONENT: "common" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-ecr: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.ecr == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
needs: terragrunt-filter | |
runs-on: ubuntu-latest | |
env: | |
COMPONENT: "ecr" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws | |
cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-ecr-us-east: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.ecr-us-east == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
needs: terragrunt-filter | |
runs-on: ubuntu-latest | |
env: | |
COMPONENT: "ecr-us-east" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws | |
cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-ses_receiving_emails: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.ses_receiving_emails == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
env: | |
COMPONENT: "ses_receiving_emails" | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr,terragrunt-plan-ecr-us-east] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-dns: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.dns == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
env: | |
COMPONENT: "dns" | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ses_receiving_emails] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-ses_validation_dns_entries: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.ses_validation_dns_entries == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
env: | |
COMPONENT: "ses_validation_dns_entries" | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-dns] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-cloudfront: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.cloudfront == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common] | |
env: | |
COMPONENT: "cloudfront" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-eks: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.eks == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-dns,terragrunt-plan-cloudfront] | |
env: | |
COMPONENT: "eks" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-elasticache: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.elasticache == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks] | |
env: | |
COMPONENT: "elasticache" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-rds: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.rds == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks] | |
env: | |
COMPONENT: "rds" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-lambda-api: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.lambda-api == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-ecr,terragrunt-plan-rds] | |
env: | |
COMPONENT: "lambda-api" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-lambda-admin-pr: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.lambda-admin-pr == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-elasticache,terragrunt-plan-ecr] | |
env: | |
COMPONENT: "lambda-admin-pr" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-performance-test: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.performance-test == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-ecr] | |
env: | |
COMPONENT: "performance-test" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
skip-conftest: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-heartbeat: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.heartbeat == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr] | |
env: | |
COMPONENT: "heartbeat" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-database-tools: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.database-tools == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-rds] | |
env: | |
COMPONENT: "database-tools" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-quicksight: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.quicksight == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-rds] | |
env: | |
COMPONENT: "quicksight" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-lambda-google-cidr: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.lambda-google-cidr == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-eks,terragrunt-plan-ecr] | |
env: | |
COMPONENT: "lambda-google-cidr" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-ses_to_sqs_email_callbacks: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.ses_to_sqs_email_callbacks == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr] | |
env: | |
COMPONENT: "ses_to_sqs_email_callbacks" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-sns_to_sqs_sms_callbacks: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.sns_to_sqs_sms_callbacks == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr] | |
env: | |
COMPONENT: "sns_to_sqs_sms_callbacks" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-pinpoint_to_sqs_sms_callbacks: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.pinpoint_to_sqs_sms_callbacks == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr] | |
env: | |
COMPONENT: "pinpoint_to_sqs_sms_callbacks" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-system_status: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.system_status == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
runs-on: ubuntu-latest | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-ecr,terragrunt-plan-rds,terragrunt-plan-eks] | |
env: | |
COMPONENT: "system_status" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-system_status_static_site: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.system_status_static_site == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
needs: [terragrunt-filter,terragrunt-plan-common,terragrunt-plan-system_status] | |
runs-on: ubuntu-latest | |
env: | |
COMPONENT: "system_status_static_site" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-newrelic: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.newrelic == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
needs: [terragrunt-filter,terragrunt-plan-common] | |
runs-on: ubuntu-latest | |
env: | |
COMPONENT: "newrelic" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-manifest_secrets: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.manifest_secrets == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
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" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade | |
terragrunt-plan-github: | |
if: | | |
always() && | |
needs.terragrunt-filter.outputs.github == 'true' && | |
!contains(needs.*.result, 'failure') && | |
!contains(needs.*.result, 'cancelled') || | |
needs.terragrunt-filter.outputs.config == 'true' | |
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: "github" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- uses: ./.github/actions/setup-terraform | |
with: | |
role_to_assume: arn:aws:iam::${{env.ACCOUNT_ID}}:role/notification-terraform-plan | |
role_session_name: NotifyTerraformPlan | |
- name: Install 1Pass CLI and Download TFVars | |
run: | | |
curl -o 1pass.deb https://downloads.1password.com/linux/debian/amd64/stable/1password-cli-amd64-latest.deb | |
sudo dpkg -i 1pass.deb | |
sudo mkdir -p aws && cd aws | |
op read op://4eyyuwddp6w4vxlabrr2i2duxm/"TERRAFORM_SECRETS_${{env.ENVIRONMENT}}"/notesPlain > ${{env.ENVIRONMENT}}.tfvars | |
- name: Terragrunt plan ${{env.COMPONENT}} | |
uses: cds-snc/terraform-plan@7f4ce4a4bdffaba639d32a45272804e37a569408 # v3.0.6 | |
with: | |
directory: "env/${{env.ENVIRONMENT}}/${{env.COMPONENT}}" | |
comment-delete: "true" | |
comment-title: "${{env.ENVIRONMENT}}: ${{env.COMPONENT}}" | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
terragrunt: "true" | |
terraform-init: | | |
-upgrade |