|
1 |
| -# Parition Layer Verification |
| 1 | +# Partition Layer Verification |
2 | 2 | # ---
|
3 |
| -# This workflow queries the Parition layer info in production only |
| 3 | +# This workflow queries the Partition layer info in production only |
4 | 4 |
|
5 | 5 | on:
|
6 | 6 | workflow_dispatch:
|
@@ -51,11 +51,11 @@ jobs:
|
51 | 51 | runs-on: ubuntu-latest
|
52 | 52 | outputs:
|
53 | 53 | regions: ${{ format('{0}{1}', steps.regions_china.outputs.regions, steps.regions_govcloud.outputs.regions) }}
|
54 |
| - parition: ${{ format('{0}{1}', steps.regions_china.outputs.partition, steps.regions_govcloud.outputs.parition) }} |
| 54 | + partition: ${{ format('{0}{1}', steps.regions_china.outputs.partition, steps.regions_govcloud.outputs.partition) }} |
55 | 55 | aud: ${{ format('{0}{1}', steps.regions_china.outputs.aud, steps.regions_govcloud.outputs.aud) }}
|
56 | 56 | steps:
|
57 | 57 | - id: regions_china
|
58 |
| - name: Parition (China) |
| 58 | + name: Partition (China) |
59 | 59 | if: ${{ inputs.partition == 'China' }}
|
60 | 60 | run: |
|
61 | 61 | echo regions='["cn-north-1"]'>> "$GITHUB_OUTPUT"
|
@@ -129,7 +129,7 @@ jobs:
|
129 | 129 | - name: Verify Layer
|
130 | 130 | run: |
|
131 | 131 | export layer_output='AWSLambdaPowertoolsTypeScriptV2-${{matrix.region}}.json'
|
132 |
| - aws --region ${{ matrix.region}} lambda get-layer-version-by-arn --arn "arn:${{ needs.setup.outputs.parition }}:lambda:${{ matrix.region}}:${{ secrets[format('AWS_ACCOUNT_{0}', steps.transform.outputs.CONVERTED_REGION)] }}:layer:AWSLambdaPowertoolsTypeScriptV2:${{ steps.partition_version.outputs.partition_version }}" > $layer_output |
| 132 | + aws --region ${{ matrix.region}} lambda get-layer-version-by-arn --arn "arn:${{ needs.setup.outputs.partition }}:lambda:${{ matrix.region}}:${{ secrets[format('AWS_ACCOUNT_{0}', steps.transform.outputs.CONVERTED_REGION)] }}:layer:AWSLambdaPowertoolsTypeScriptV2:${{ steps.partition_version.outputs.partition_version }}" > $layer_output |
133 | 133 | REMOTE_SHA=$(jq -r '.Content.CodeSha256' $layer_output)
|
134 | 134 | LOCAL_SHA=$(jq -r '.Content.CodeSha256' AWSLambdaPowertoolsTypeScriptV2.json)
|
135 | 135 | test "$REMOTE_SHA" == "$LOCAL_SHA" && echo "SHA OK: ${LOCAL_SHA}" || exit 1
|
|
0 commit comments