Deploying a website to a S3 Bucket and use CloudFront for the website distribution to enhance cache content thus improving access speed for the content.
The project does the following:
- Create S3 Bucket.
- Upload content from website folder to S3 Bucket.
- Change S3 bucket to static website hosting.
- Change object policy access within S3 bucket.
- Create CloudFront.
- Create AWS Account.
- Create CircleCI Account.
- Guide on getting started with CircleCi.
- Add Environment Variables in the CircleCi project for AWS_SECRET_KEY, AWS_REGION and AWS_ACCESS_KEY.
- Trigger CircleCI either through Setup of project or change the contents inside the website folder.
In AWS S3 objects content type for html can default to binary/octet-stream. Go to the bucket, select the index.html and click on Object actions then select Edit metadata and change Content Type to text/html. For reference AWS S3 not serving files