mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-08 11:17:27 +00:00
made terraform apply work
This commit is contained in:
parent
e6d994e0b0
commit
ffbb621282
2 changed files with 11 additions and 8 deletions
17
.github/workflows/_deploy_lambda.yml
vendored
17
.github/workflows/_deploy_lambda.yml
vendored
|
|
@ -23,6 +23,14 @@ on:
|
|||
required: true
|
||||
type: string
|
||||
|
||||
terraform_apply:
|
||||
required: false
|
||||
type: choice
|
||||
default: 'false'
|
||||
options:
|
||||
- 'true'
|
||||
- 'false'
|
||||
|
||||
secrets:
|
||||
AWS_ACCESS_KEY_ID:
|
||||
required: true
|
||||
|
|
@ -86,14 +94,7 @@ jobs:
|
|||
-var="image_digest=${{ inputs.image_digest }}" \
|
||||
-out=lambdaplan
|
||||
|
||||
- name: Wait for Approval
|
||||
uses: trstringer/manual-approval@v1
|
||||
with:
|
||||
secret: ${{ secrets.GITHUB_TOKEN }}
|
||||
approvers: developers
|
||||
issue-title: "Click to approve Terraform Apply for ${{ inputs.lambda_name }} (${{ inputs.stage }})"
|
||||
issue-body: "Press approve to proceed with Terraform Apply"
|
||||
|
||||
- name: Terraform Apply
|
||||
if: inputs.terraform_apply == 'true' || inputs.stage == 'dev' || inputs.stage == 'main'
|
||||
working-directory: ${{ inputs.lambda_path }}
|
||||
run: terraform apply -auto-approve lambdaplan
|
||||
|
|
|
|||
2
.github/workflows/deploy_terraform.yml
vendored
2
.github/workflows/deploy_terraform.yml
vendored
|
|
@ -133,6 +133,8 @@ jobs:
|
|||
stage: ${{ needs.determine_stage.outputs.stage }}
|
||||
ecr_repo: postcode_splitter-${{ needs.determine_stage.outputs.stage }}
|
||||
image_digest: ${{ needs.postcodeSplitter_image.outputs.image_digest }}
|
||||
# This should not be deployed in production!!!!
|
||||
terraform_apply: 'true'
|
||||
secrets:
|
||||
AWS_ACCESS_KEY_ID: ${{ secrets.DEV_AWS_ACCESS_KEY_ID }}
|
||||
AWS_SECRET_ACCESS_KEY: ${{ secrets.DEV_AWS_SECRET_ACCESS_KEY }}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue