Skip to content

Instantly share code, notes, and snippets.

@tolleiv
Created July 16, 2017 20:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tolleiv/c60a5eec2e2a227625b68301586fe66a to your computer and use it in GitHub Desktop.
Save tolleiv/c60a5eec2e2a227625b68301586fe66a to your computer and use it in GitHub Desktop.
set -e # Fail fast
DISTRIBUTION_ID=xxxxxxxxxxxxxxxx
BUCKET_NAME=xxxxxxxxxxxxxx
aws s3 sync --acl "public-read" --sse "AES256" public/ s3://$BUCKET_NAME --exclude 'post'
aws cloudfront create-invalidation --distribution-id $DISTRIBUTION_ID --paths /index.html / /page/*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment