File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed
Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -18,10 +18,8 @@ permissions:
1818 id-token : write
1919
2020env :
21- ENVNAME : ${{ inputs.environment }}
22- ACCT : ${{ inputs.environment == 'production' && '990880627107' || '327995277200' }}
23- BUCKET : ${{ inputs.environment == 'production' && 'tiny-cloud-antora-docs-release' || 'tiny-cloud-antora-docs-preview' }}
24- RUN : run-${{ github.run_number }}-${{ github.run_attempt }}
21+ # inputs are only defined on a dispatch event, so to test we provide a default...
22+ TARGET : ${{ inputs.environment || 'staging' }}
2523
2624jobs :
2725 build :
3129
3230 runs-on : ubuntu-latest
3331
32+ env :
33+ ACCT : ${{ env.TARGET == 'production' && '990880627107' || '327995277200' }}
34+ BUCKET : ${{ env.TARGET == 'production' && 'tiny-cloud-antora-docs-release' || 'tiny-cloud-antora-docs-preview' }}
35+ RUN : run-${{ github.run_number }}-${{ github.run_attempt }}
36+
3437 defaults :
3538 run :
3639 shell : bash
6265 - name : configure aws credentials
6366 uses :
aws-actions/[email protected] 6467 with :
65- role-to-assume : ' arn:aws:iam::${{ env.ACCT }}:role/${{ env.ENVNAME }}-tinymce-docs-update'
66- role-session-name : tinymce-docs-${{ env.ENVNAME }}-release
68+ role-to-assume : ' arn:aws:iam::${{ env.ACCT }}:role/${{ env.TARGET }}-tinymce-docs-update'
69+ role-session-name : tinymce-docs-${{ env.TARGET }}-release
6770 aws-region : us-east-1
6871
6972 - name : Upload website preview to S3
You can’t perform that action at this time.
0 commit comments