Hosting a static website with HTTPS on an S3 bucket

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello today I will show you how to add ssl to a static website hosted on s3 bucket let's get started in this video I will use our cloud breadless website as an example we have our s3 setup with two buckets one being cloud Pradas i/o which actually contains the static website and which is configured using using static website hosting to host the actual website so if you go to our domain you will see the website there and then we have a second bucket www-where which is just set up to redirect to the cloud brothers IL domain because we would like to catch all the users coming in using www as well now f3 hosting does not support SSL on its own so we will use cloud front we will use a well front distribution to act as an HTTP endpoint for our static website this is quite straightforward first this is a neat little trick we will copy the actual end point for our static website and use this as an origin for our distribution so here we create a cloud from distribution you can directly set the origin to an s3 bucket as well but there's a drawback to that because then all subdirectories will not automatically serve the containing index.html file this is why I am using the HTTP endpoint as an origin so here we say that we would like to redirect HTTP to HTTPS everything else you can leave fairly straightforward and the important thing is here what we would like to create our own certificate and another one and we will request a certificate from AWS so just make sure that you set up your emails one of these emails to catch the actual requests because you need to verify that you own the domain before you continue and you can see that we now have a validation pending we have to wait for the email to arrive where we can confirm that we actually own this domain let's check we already got the requests here so I will approve both of these I will go back here to the certificate manager and we see that now the certificate has been issued and we can use it now you can see that our cloud products certificate is already suggested here which we will use and now we just create a distribution this will take some time as CloudFront distributes the content to edge locations where it will be cached so it will take some time I actually forgot to fill in the scene name which is important so that we can later use route 53 to point our domain to this cloud font and a point so this this current distribution is being set up in the meantime we are going to create a second distribution which will point to our second bucket which will do the redirection from www.rottertube.com as a so let me just go back to the bucket copy the URL and we will set up a second CloudFront distribution so we would like to redirect fill in the cname and select the custom SSL certificate we created before now we will finish up creating the second distribution they are both now in the queue to be set up and as soon as this is done our website will be available through HTTPS wire this domain name here so what we have to do next is we have to go to route 53 and point the domains to the cloud fund distributions so you see here we still have the s3 bucket in our a record which we will exchange with the CloudFront distribution here we go save record set and we will do the same thing with the www and that's it now we just have to wait for our CloudFront distributions to finish distributing and then our website will be available our CloudFront distributions are still syncing but they are already available and some end points so if we go to the HTTP version of our domain it's already there congratulations you're now hosting your website using HTTPS and s3 buckets my name is Christopher sotnik and I'm recording for cloud Prentiss I hope you enjoyed this little tutorial if you like more tutorials like these just follow us and we will keep you posted
Info
Channel: cloud brothers
Views: 17,568
Rating: undefined out of 5
Keywords: AWS, CloudFront, S3, Static Website, Hosting
Id: uwgB_sIhIko
Channel Id: undefined
Length: 8min 7sec (487 seconds)
Published: Wed Nov 22 2017
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.