fix: require explicit confirm_dns_switch flag to run switch_dns job
This commit is contained in:
parent
77d2ba9067
commit
d24b434f63
7
.github/workflows/deploy-env-migration.yaml
vendored
7
.github/workflows/deploy-env-migration.yaml
vendored
@ -41,6 +41,11 @@ on:
|
|||||||
default: "apply"
|
default: "apply"
|
||||||
type: choice
|
type: choice
|
||||||
options: [apply, destroy]
|
options: [apply, destroy]
|
||||||
|
confirm_dns_switch:
|
||||||
|
description: "危险: 勾选此项将在最后一步接管原域名的生产流量 (仅真实灾备启用)"
|
||||||
|
required: false
|
||||||
|
default: false
|
||||||
|
type: boolean
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
@ -303,7 +308,7 @@ jobs:
|
|||||||
switch_dns:
|
switch_dns:
|
||||||
name: Switch DNS Traffic (Manual Approval)
|
name: Switch DNS Traffic (Manual Approval)
|
||||||
needs: migrate_data
|
needs: migrate_data
|
||||||
if: ${{ always() && github.event.inputs.terraform_action == 'apply' }}
|
if: ${{ always() && github.event.inputs.terraform_action == 'apply' && github.event.inputs.confirm_dns_switch == 'true' }}
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
environment: production
|
environment: production
|
||||||
steps:
|
steps:
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user