@@ -674,12 +674,17 @@ jobs:
674674 addon-name : ${{ needs.setup.outputs.addon-name }}
675675 sc4s-version : ${{ matrix.sc4s.version }}
676676 sc4s-docker-registry : ${{ matrix.sc4s.docker_registry }}
677+ - name : Read secrets from AWS Secrets Manager again into environment variables in case credential rotation
678+ id : update-argo-token
679+ run : |
680+ ARGO_TOKEN=$(aws secretsmanager get-secret-value --secret-id ta-github-workflow-automation-token | jq -r '.SecretString')
681+ echo "::set-output name=argo-token::$ARGO_TOKEN"
677682 - name : Check if pod was deleted
678683 id : is-pod-deleted
679684 if : always()
680685 shell : bash
681686 env :
682- ARGO_TOKEN : ${{ steps.get -argo-token.outputs.argo-token }}
687+ ARGO_TOKEN : ${{ steps.update -argo-token.outputs.argo-token }}
683688 run : |
684689 set -o xtrace
685690 if argo watch ${{ steps.run-tests.outputs.workflow-name }} -n workflows | grep "pod deleted"; then
@@ -689,7 +694,7 @@ jobs:
689694 id : retry-wf
690695 shell : bash
691696 env :
692- ARGO_TOKEN : ${{ steps.get -argo-token.outputs.argo-token }}
697+ ARGO_TOKEN : ${{ steps.update -argo-token.outputs.argo-token }}
693698 if : always()
694699 run : |
695700 set -o xtrace
@@ -706,7 +711,7 @@ jobs:
706711 fi
707712 - name : check if workflow completed
708713 env :
709- ARGO_TOKEN : ${{ steps.get -argo-token.outputs.argo-token }}
714+ ARGO_TOKEN : ${{ steps.update -argo-token.outputs.argo-token }}
710715 shell : bash
711716 if : always()
712717 run : |
@@ -1001,12 +1006,17 @@ jobs:
10011006 addon-name : ${{ needs.setup.outputs.addon-name }}
10021007 vendor-version : ${{ matrix.vendor-version.image }}
10031008 sc4s-version : " No"
1009+ - name : Read secrets from AWS Secrets Manager again into environment variables in case credential rotation
1010+ id : update-argo-token
1011+ run : |
1012+ ARGO_TOKEN=$(aws secretsmanager get-secret-value --secret-id ta-github-workflow-automation-token | jq -r '.SecretString')
1013+ echo "::set-output name=argo-token::$ARGO_TOKEN"
10041014 - name : Check if pod was deleted
10051015 id : is-pod-deleted
10061016 if : always()
10071017 shell : bash
10081018 env :
1009- ARGO_TOKEN : ${{ steps.get -argo-token.outputs.argo-token }}
1019+ ARGO_TOKEN : ${{ steps.update -argo-token.outputs.argo-token }}
10101020 run : |
10111021 set -o xtrace
10121022 if argo watch ${{ steps.run-tests.outputs.workflow-name }} -n workflows | grep "pod deleted" ; then
@@ -1016,7 +1026,7 @@ jobs:
10161026 id : retry-wf
10171027 shell : bash
10181028 env :
1019- ARGO_TOKEN : ${{ steps.get -argo-token.outputs.argo-token }}
1029+ ARGO_TOKEN : ${{ steps.update -argo-token.outputs.argo-token }}
10201030 if : always()
10211031 run : |
10221032 set -o xtrace
@@ -1033,7 +1043,7 @@ jobs:
10331043 fi
10341044 - name : check if workflow completed
10351045 env :
1036- ARGO_TOKEN : ${{ steps.get -argo-token.outputs.argo-token }}
1046+ ARGO_TOKEN : ${{ steps.update -argo-token.outputs.argo-token }}
10371047 if : always()
10381048 shell : bash
10391049 run : |
@@ -1171,12 +1181,17 @@ jobs:
11711181 addon-name : ${{ needs.setup.outputs.addon-name }}
11721182 vendor-version : ${{ matrix.vendor-version.image }}
11731183 sc4s-version : " No"
1184+ - name : Read secrets from AWS Secrets Manager again into environment variables in case credential rotation
1185+ id : update-argo-token
1186+ run : |
1187+ ARGO_TOKEN=$(aws secretsmanager get-secret-value --secret-id ta-github-workflow-automation-token | jq -r '.SecretString')
1188+ echo "::set-output name=argo-token::$ARGO_TOKEN"
11741189 - name : Check if pod was deleted
11751190 id : is-pod-deleted
11761191 if : always()
11771192 shell : bash
11781193 env :
1179- ARGO_TOKEN : ${{ steps.get -argo-token.outputs.argo-token }}
1194+ ARGO_TOKEN : ${{ steps.update -argo-token.outputs.argo-token }}
11801195 run : |
11811196 set -o xtrace
11821197 if argo watch ${{ steps.run-tests.outputs.workflow-name }} -n workflows | grep "pod deleted"; then
@@ -1186,7 +1201,7 @@ jobs:
11861201 id : retry-wf
11871202 shell : bash
11881203 env :
1189- ARGO_TOKEN : ${{ steps.get -argo-token.outputs.argo-token }}
1204+ ARGO_TOKEN : ${{ steps.update -argo-token.outputs.argo-token }}
11901205 if : always()
11911206 run : |
11921207 set -o xtrace
@@ -1203,7 +1218,7 @@ jobs:
12031218 fi
12041219 - name : check if workflow completed
12051220 env :
1206- ARGO_TOKEN : ${{ steps.get -argo-token.outputs.argo-token }}
1221+ ARGO_TOKEN : ${{ steps.update -argo-token.outputs.argo-token }}
12071222 if : always()
12081223 shell : bash
12091224 run : |
0 commit comments