From dda4262bceeaa2407c933964f644c6bceff44852 Mon Sep 17 00:00:00 2001 From: Douglas Muth Date: Tue, 9 May 2023 21:26:46 -0400 Subject: [PATCH] Added CloudFront invalidation to deployment script. --- go-sync-to-s3.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/go-sync-to-s3.sh b/go-sync-to-s3.sh index 23b9f9b..6a05214 100755 --- a/go-sync-to-s3.sh +++ b/go-sync-to-s3.sh @@ -8,6 +8,11 @@ set -e pushd $(dirname $0) > /dev/null +echo "# Syncing files to AWS S3 bucket..." aws s3 sync . s3://diceware.dmuth.org/ --exclude ".*" --exclude "node_modules/*" --delete +echo "# Invalidating CloudFront cache..." +aws cloudfront create-invalidation --distribution-id E2TUL4ST85ZH5Y --paths "/*" + +echo "# Done!"