Skip to content

Commit

Permalink
Merge pull request #3 from ServerlessOpsIO/feature/params-and-tags
Browse files Browse the repository at this point in the history
fix some issues with params and tags handling
  • Loading branch information
tmclaugh authored Sep 10, 2024
2 parents e24011d + 2f2fca9 commit 02f05e3
Showing 1 changed file with 6 additions and 10 deletions.
16 changes: 6 additions & 10 deletions action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -104,23 +104,19 @@ runs:
env:
BRANCH: ${{ env.GITHUB_EVENT_REF_SLUG_URL }}
TAGS_FILE: ${{ inputs.cfn_tags_file }}
GITHUB_REPOSITORY: ${{ env.GITHUB_REPOSITORY }}
GITHUB_REF_NAME: ${{ env.GITHUB_REF_NAME }}
GITHUB_SHA: ${{ env.GITHUB_SHA }}
STACK_NAME: ${{ steps.set-stack-name.outputs.name }}
run: |
AWS_CFN_TAGS=$(
cat $TAGS_FILE |
jq -r '
to_entries |
map("\(.key)=\(.value|tostring)") |
. += [
"org:repo=${GITHUB_REPOSITORY}",
"org:branch=${GITHUB_REF_NAME}",
"org:commit=${GITHUB_SHA}",
"org:stackName=${STACK_NAME}"
"org:repo=${{ env.GITHUB_REPOSITORY }}",
"org:branch=${{ env.GITHUB_REF_NAME }}",
"org:commit=${{ env.GITHUB_SHA }}",
"org:stackName=${{ steps.set-stack-name.outputs.name }}"
] |
join(",")
join(" ")
'
)
echo "Resolved Cloudformation tags: ${AWS_CFN_TAGS}"
Expand All @@ -144,7 +140,7 @@ runs:
-r '
to_entries |
map("\(.key)=\(.value|tostring)") |
join(",")
join(" ")
'
)
echo "Resolved CFN parameters: $AWS_CFN_PARAMS"
Expand Down

0 comments on commit 02f05e3

Please sign in to comment.