December 2019
Intermediate to advanced
382 pages
9h 43m
English
First up is Amazon S3. This is where we store all of the static content, including the images, web pages, style sheets, JavaScript files, and any other content such as PDFs. Website hosting is a feature that you can enable in an S3 bucket, so this component replaces the need to run something such as Apache HTTPD or NGINX on web servers combined with a load balancer.
To enable static hosting, you can run this command on an existing bucket. This will enable the website hosting feature and configure S3 to load a particular HTML file for the index and error pages:
aws s3 website s3://hello-website/ --index-document index.html --error-document error.html
Alternatively, you can find the options to enable website hosting in the properties ...