1010 - ' .gitignore'
1111env :
1212 node_version : " 22.x"
13- tf_version : " 1.9.8 " # must match value in terraform-iac/*/app/main.tf
13+ tf_version : " 1.9.0 " # must match value in terraform-iac/*/app/main.tf
1414 FORCE_COLOR : 3
1515concurrency : ${{ github.ref }}
1616jobs :
@@ -151,22 +151,22 @@ jobs:
151151 aws-region : us-west-2
152152
153153 - name : Terraform Setup
154- uses : hashicorp /setup-terraform@v3
154+ uses : opentofu /setup-opentofu@v1
155155 with :
156- terraform_version : ${{ env.tf_version }}
157- terraform_wrapper : false
156+ tofu_version : ${{ env.tf_version }}
157+ tofu_wrapper : false
158158
159159 - name : Terraform Init
160160 working-directory : ${{ matrix.env.tf_working_dir }}
161- run : terraform init
161+ run : tofu init
162162
163163 - name : Terraform Format
164164 working-directory : " ./"
165- run : terraform fmt -check -recursive
165+ run : tofu fmt -check -recursive
166166
167167 - name : Terraform Plan
168168 working-directory : ${{ matrix.env.tf_working_dir }}
169- run : terraform plan -input=false -out=plan
169+ run : tofu plan -input=false -out=plan
170170
171171 - name : Analyze Terraform Plan
172172 uses : byu-oit/github-action-tf-plan-analyzer@v2
@@ -188,16 +188,16 @@ jobs:
188188
189189 - name : Terraform Apply
190190 working-directory : ${{ matrix.env.tf_working_dir }}
191- run : terraform apply plan
191+ run : tofu apply plan
192192
193193 - name : Get Terraform Outputs
194194 id : terraform-outputs
195195 working-directory : ${{ matrix.env.tf_working_dir }}
196196 run : |
197- echo "codedeploy_app_name=$(terraform output -raw codedeploy_app_name)" >> $GITHUB_OUTPUT
198- echo "codedeploy_deployment_group_name=$(terraform output -raw codedeploy_deployment_group_name)" >> $GITHUB_OUTPUT
199- echo "codedeploy_appspec_json_file=$(terraform output -raw codedeploy_appspec_json_file)" >> $GITHUB_OUTPUT
200- echo "url=$(terraform output -raw url)" >> $GITHUB_OUTPUT
197+ echo "codedeploy_app_name=$(tofu output -raw codedeploy_app_name)" >> $GITHUB_OUTPUT
198+ echo "codedeploy_deployment_group_name=$(tofu output -raw codedeploy_deployment_group_name)" >> $GITHUB_OUTPUT
199+ echo "codedeploy_appspec_json_file=$(tofu output -raw codedeploy_appspec_json_file)" >> $GITHUB_OUTPUT
200+ echo "url=$(tofu output -raw url)" >> $GITHUB_OUTPUT
201201
202202 - name : CodeDeploy
203203 id : deploy
0 commit comments