File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1313 options :
1414 - plan
1515 - apply
16+ ref :
17+ description : " 체크아웃할 커밋 SHA (apply 시 필수, plan은 선택)"
18+ required : false
19+ type : string
1620
1721concurrency :
1822 group : terraform-v3-k8s-dev
3943 plan_exitcode : ${{ steps.plan.outputs.exitcode }}
4044 steps :
4145 - uses : actions/checkout@v4
46+ with :
47+ ref : ${{ inputs.ref || '' }}
4248
4349 - uses : aws-actions/configure-aws-credentials@v4
4450 with :
@@ -131,10 +137,16 @@ jobs:
131137 apply :
132138 name : " Terraform Apply"
133139 needs : plan
134- if : github.event_name == 'workflow_dispatch' && github.event.inputs.action == 'apply' && needs.plan.outputs.plan_exitcode == '2'
140+ if : >-
141+ github.event_name == 'workflow_dispatch' &&
142+ github.event.inputs.action == 'apply' &&
143+ github.event.inputs.ref != '' &&
144+ needs.plan.outputs.plan_exitcode == '2'
135145 runs-on : ubuntu-latest
136146 steps :
137147 - uses : actions/checkout@v4
148+ with :
149+ ref : ${{ inputs.ref }}
138150
139151 - uses : aws-actions/configure-aws-credentials@v4
140152 with :
You can’t perform that action at this time.
0 commit comments