Home
Head's Up: I'm in the middle of upgrading my site. Most things are in place, but there are something missing and/or broken including image alt text. Please bear with me while I'm getting things fixed.

Hugo to AWS S3 Deploy Command

TODO: Figure out why this isn't working in MDX


Here's a quick snippet of code to put your shell aliases file that cds into your Hugo directory, builds the site, deploys it to AWS S3, and then invalidates the cache. 


	function hugo-deploy () {
	    cd /path/to/hugo/site
	    hugo
	    aws s3 sync /path/to/hugo/site s3://your_site_s3_bucket/
	    aws cloudfront create-invalidation --distribution-id AAAAWWWWWSSSS1111 --paths "/*"
	}