Dogfood & Dogfood Free - Terraform deprecation fixes (#32101)

Added support to allow terraform plan (dry-run) without apply for
dogfood deployment action

Updated infrastructure/dogfood/terraform/aws-tf-module/docker/main.tf
- Allow hashicorp/aws `>= 5.68.0` instead of `~> 5.0`

Updated infrastructure/dogfood/terraform/aws-tf-module/main.tf
- Updated occurences of `data.aws_region.current.id` ->
`data.aws_region.current.region`
- Updated occurences of `data.aws_region.current.name` ->
`data.aws_region.current.region`
- Allow hashicorp/aws `>= 5.68.0` instead of `~> 5.0`
- `tf-mod-root-v1.15.2` -> `tf-mod-root-v1.17.0`
- `tf-mod-addon-migrations-v2.0.1` -> `tf-mod-addon-migrations-v2.1.0`
- `tf-mod-addon-osquery-carve-v1.1.0` ->
`tf-mod-addon-osquery-carve-v1.1.1`
- `tf-mod-addon-logging-alb-v1.3.0` -> `tf-mod-addon-logging-alb-v1.4.0`
- `tf-mod-addon-ses-v1.3.0` -> `tf-mod-addon-ses-v1.4.0`
- `tf-mod-addon-external-vuln-scans-v2.2.1` ->
`tf-mod-addon-external-vuln-scans-v2.3.0`

Updated infrastructure/dogfood/terraform/aws-tf-module/free.tf
- Updated occurences of `data.aws_region.current.id` ->
`data.aws_region.current.region`
- Updated occurences of `data.aws_region.current.name` ->
`data.aws_region.current.region`
- `tf-mod-byo-vpc-v1.13.0` -> `tf-mod-byo-vpc-v1.18.3`
- `tf-mod-addon-ses-v1.3.0` -> `tf-mod-addon-ses-v1.4.0`
- `tf-mod-addon-migrations-v2.0.1` -> `tf-mod-addon-migrations-v2.1.0`

Updated infrastructure/dogfood/terraform/aws-tf-module/free-ecs-hosts.tf
- Updated occurences of `data.aws_region.current.name` ->
`data.aws_region.current.region`
This commit is contained in:
Jorge Falcon
2025-08-19 22:48:19 -04:00
committed by GitHub
parent e50d913bc0
commit fc94901cac
6 changed files with 130 additions and 114 deletions
+7 -1
View File
@@ -6,6 +6,10 @@ on:
DOCKER_IMAGE:
description: "The full name of the docker image to be deployed. (e.g. fleetdm/fleet:v4.30.0). Note: do not use fleetdm/fleet:main directly. Use the short hash instead. If pull-rate limited, try using the quay.io/fleetdm/fleet mirror."
required: true
dry_run:
description: Dry run only? No "terraform apply"
type: boolean
default: false
# This allows a subsequently queued workflow run to interrupt previous runs
concurrency:
@@ -87,7 +91,7 @@ jobs:
run: terraform plan -no-color
continue-on-error: true
- name: Slack Notification
if: success()
if: success() && inputs.dry_run == false
uses: slackapi/slack-github-action@e28cf165c92ffef168d23c5c9000cffc8a25e117 # v1.24.0
with:
payload: |
@@ -108,8 +112,10 @@ jobs:
SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK
# Note: This will cause the geolite2 image to be built twice, but that cannot be avoided without refactoring the terraform to not tag it based upon timestamp.
- name: Terraform Apply Free
if: inputs.dry_run == false
id: apply-free
run: terraform apply -target=module.free -target=module.migrations_free -target=module.geolite2 -auto-approve
- name: Terraform Apply
if: inputs.dry_run == false
id: apply
run: terraform apply -auto-approve