Skip to content

Commit 10d9b5d

Browse files
author
Bob Strahan
committed
Add versioned template upload to publish script
1 parent 83c0e0e commit 10d9b5d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

publish.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -461,6 +461,9 @@ function build_main_template() {
461461
# Upload and validate main template
462462
aws s3 cp .aws-sam/${MAIN_TEMPLATE} s3://${BUCKET}/${PREFIX}/${MAIN_TEMPLATE} || exit 1
463463
local TEMPLATE_URL="https://s3.${REGION}.amazonaws.com/${BUCKET}/${PREFIX}/${MAIN_TEMPLATE}"
464+
465+
# Also make a version tagged copy of main template for easy installation of specific versions
466+
aws s3 cp .aws-sam/${MAIN_TEMPLATE} s3://${BUCKET}/${PREFIX}/${MAIN_TEMPLATE%.yaml}_${VERSION}.yaml
464467

465468
echo "Validating template: $TEMPLATE_URL"
466469
aws cloudformation validate-template --template-url $TEMPLATE_URL > /dev/null || exit 1

0 commit comments

Comments
 (0)