Uploading a static website to your s3 bucket from the terminal without clicking around.

July 31, 2015 [ aws | cli ]

For the following, you will need to has the AWS Command Line Interface installeded and configured. Let’s assume you have a website (html, css, js files and folders) which is called website. You want it to go into an s3 bucket called mybucket-website which resides on in Frankfurt (eu-central-1). The following command will upload the content, delete unnecessary files (which are not in your local folder) and do so quickly.

$ aws s3 sync website s3://mybucket-website --region eu-central-1 --delete --acl public-read

No more unnecessary navigation and uploading via the tedious AWS console. You can find the complete documentation of the sync command here

Get emails from me: