Skip to content

Commit

Permalink
add missing vars and env processing
Browse files Browse the repository at this point in the history
  • Loading branch information
tmclaugh committed Sep 1, 2024
1 parent bdc2043 commit a1534e3
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -182,14 +182,22 @@ jobs:
- name: Process AWS Cloudformation Parameters
id: process-aws-parameters
shell: bash
env:
GHA_SECRETS: ${{ tojson(secrets) }}
GHA_ENV: ${{ toJson(env) }}
run: >-
AWS_CFN_PARAMS=$(
cat cfn-parameters.json |
jq -r '
to_entries |
map("\(.key)=\(.value|tostring)") |
join(" ")
'
jq \
-n \
--argjson secrets "$GHA_SECRETS" \
--argjson env "$GHA_ENV" \
-f cfn-parameters.json |
jq \
-r '
to_entries |
map("\(.key)=\(.value|tostring)") |
join(" ")
'
) &&
echo "AWS_CFN_PARAMS=--parameter-overrides ${AWS_CFN_PARAMS}" >> $GITHUB_ENV
Expand Down

0 comments on commit a1534e3

Please sign in to comment.