Use only one target group for the listeners to fix sticky sessions #120
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: CI | |
on: | |
pull_request: | |
branches: [main] | |
types: [opened, reopened, synchronize, edited] | |
env: | |
tf_working_dir: "./examples/ci" | |
aws_account: "977306314792" | |
aws_gha_role: terraform-fargate-api-dev-gha | |
jobs: | |
format: | |
name: Terraform Format | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Terraform Setup | |
uses: hashicorp/setup-terraform@v2 | |
with: | |
terraform_version: '1.3.x' | |
- name: Terraform Format | |
working-directory: "./" | |
run: terraform fmt -check -recursive -diff | |
plan: | |
name: Terraform Plan | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
terraform: [ '1.3.x' ] | |
fail-fast: false | |
permissions: | |
contents: read | |
actions: read | |
pull-requests: write | |
id-token: write | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Configure AWS credentials | |
uses: aws-actions/configure-aws-credentials@v2 | |
with: | |
role-to-assume: "arn:aws:iam::${{ env.aws_account }}:role/${{ env.aws_gha_role }}" | |
role-session-name: ${{ github.sha }} | |
aws-region: us-west-2 | |
- name: Terraform Setup | |
uses: hashicorp/setup-terraform@v2 | |
with: | |
terraform_version: ${{ matrix.terraform }} | |
- name: Terraform Init | |
working-directory: ${{ env.tf_working_dir }} | |
run: terraform init | |
- name: Terraform Plan | |
working-directory: ${{ env.tf_working_dir }} | |
run: terraform plan.tfplan -input=false -out=plan.tfplan | |
- name: Comment Terraform Plan | |
uses: byu-oit/github-action-tf-plan-comment@v1 | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
working-directory: ${{ env.tf_working_dir }} | |
terraform-plan-file: plan.tfplan | |
- name: Analyze Terraform Plan | |
uses: byu-oit/github-action-tf-plan-analyzer@v2 | |
with: | |
divvycloud-username: ${{ secrets.DIVVYCLOUD_USERNAME }} | |
divvycloud-password: ${{ secrets.DIVVYCLOUD_PASSWORD }} | |
working-directory: ${{ env.tf_working_dir }} | |
terraform-plan-file: plan.tfplan |