@@ -108,7 +108,7 @@ jobs:
108108 - name : Install terraform
109109 uses : hashicorp/setup-terraform@v3
110110 with :
111- terraform_version : 1.11.4
111+ terraform_version : 1.13.3
112112 outputs :
113113 SNAPSHOT_ARN : ${{ steps.get-latest-snapshot.outputs.SNAPSHOT_ARN }}
114114
@@ -167,7 +167,7 @@ jobs:
167167 - name : Install terraform
168168 uses : hashicorp/setup-terraform@v3
169169 with :
170- terraform_version : 1.11.4
170+ terraform_version : 1.13.3
171171 - name : Get db secret arn
172172 id : get-db-secret-arn
173173 working-directory : terraform/app
@@ -201,6 +201,25 @@ jobs:
201201 with :
202202 name : tfplan_infrastructure-${{ inputs.environment }}
203203 path : ${{ runner.temp }}/tfplan
204+ - name : Notify pending approval
205+ if : inputs.environment == 'production'
206+ uses : slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a
207+ with :
208+ webhook : ${{ secrets.SLACK_MAVIS_TECH_WEBHOOK_URL }}
209+ webhook-type : incoming-webhook
210+ payload : |
211+ text: ":hourglass: Approval required :hourglass:"
212+ blocks:
213+ - type: "section"
214+ text:
215+ type: "mrkdwn"
216+ text: "${{ github.workflow }} requires approval"
217+ - type: "section"
218+ fields:
219+ - type: "mrkdwn"
220+ text: "<${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View workflow run>"
221+ - type: "mrkdwn"
222+ text: "*Triggered by:*\n${{ github.actor }}"
204223
205224 apply :
206225 name : Terraform apply
@@ -226,7 +245,7 @@ jobs:
226245 - name : Install terraform
227246 uses : hashicorp/setup-terraform@v3
228247 with :
229- terraform_version : 1.11.4
248+ terraform_version : 1.13.3
230249 - name : Apply the changes
231250 run : |
232251 set -e
0 commit comments