mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-08 11:17:27 +00:00
change branch requirements on dev and prod deploy statements
This commit is contained in:
parent
d7b24ccdd1
commit
112c7bedbb
1 changed files with 2 additions and 2 deletions
4
.github/workflows/deploy_terraform.yml
vendored
4
.github/workflows/deploy_terraform.yml
vendored
|
|
@ -57,7 +57,7 @@ jobs:
|
|||
terraform workspace select ${{ github.event.pull_request.base.ref }} || terraform workspace new ${{ github.event.pull_request.base.ref }}
|
||||
|
||||
- name: Deploy to Dev
|
||||
if: github.event.pull_request.base.ref == 'dev' && github.event.pull_request.merged == true
|
||||
if: github.event.pull_request.base.ref == 'main' && github.event.pull_request.head.ref == 'dev' && github.event.pull_request.merged == true
|
||||
run: cd infrastructure/terraform && terraform apply -var-file=dev.tfvars -auto-approve
|
||||
env:
|
||||
name: dev
|
||||
|
|
@ -72,7 +72,7 @@ jobs:
|
|||
AWS_PROFILE: "ProdAdmin"
|
||||
|
||||
- name: Deploy to Prod
|
||||
if: github.event.pull_request.base.ref == 'prod' && github.event.pull_request.merged == true
|
||||
if: github.event.pull_request.base.ref == 'dev' && github.event.pull_request.head.ref == 'prod' && github.event.pull_request.merged == true
|
||||
run: cd infrastructure/terraform && terraform apply -var-file=prod.tfvars -auto-approve
|
||||
env:
|
||||
name: prod
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue