Skip to content

BAU: Upgrade GOV.UK Frontend Analytics package to v3 #841

BAU: Upgrade GOV.UK Frontend Analytics package to v3

BAU: Upgrade GOV.UK Frontend Analytics package to v3 #841

name: Pre-merge checks for Terraform
on:
pull_request:
paths: ["ci/terraform/**"]
types:
- opened
- reopened
- ready_for_review
- synchronize
jobs:
terraform-checks:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
- name: Get Terraform version
id: get-terraform-version
run: echo "version=$(cat ci/terraform/.terraform-version)" >> "${GITHUB_OUTPUT}"
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd # v3.1.2
with:
terraform_version: ${{ steps.get-terraform-version.outputs.version }}
- name: Terraform Format Check
working-directory: ci/terraform/
run: terraform fmt -check -recursive
- name: Terraform Validate
working-directory: ci/terraform/
run: |
terraform init -input=false -backend=false
terraform validate