1 00:00:08,179 --> 00:00:15,420 okay so we've created a website, we've hosted that on Amazon s3 we've created a 2 00:00:15,420 --> 00:00:21,240 cloudfront distribution, we've purchased a domain name and we got traffic 3 00:00:21,240 --> 00:00:25,710 directed from that domain name through to this cloudfront distribution. 4 00:00:25,710 --> 00:00:32,880 We've got HTTPS encrypted traffic and we've created a SSL certificate using 5 00:00:32,880 --> 00:00:38,100 the AWS certificate manager and, yes we've done quite a lot so give yourself 6 00:00:38,100 --> 00:00:41,309 a pat on the back, you've come this far and we're just going to finish up with 7 00:00:41,309 --> 00:00:48,059 talking about another feature of Amazon s3 that is quite handy 8 00:00:48,059 --> 00:00:53,039 if you have got multiple domain names and you want them all to get redirected through 9 00:00:53,039 --> 00:00:58,410 to a single domain name, so for example we've got backspace.academy but we 10 00:00:58,410 --> 00:01:04,769 might have backspaceacademy.com, .net net.au, .com.br 11 00:01:04,769 --> 00:01:09,000 we might have all these different domain names out there just in case someone 12 00:01:09,000 --> 00:01:14,430 types in the wrong thing into their browser and we want those all to 13 00:01:14,430 --> 00:01:20,189 get directed through to our Backspace Academy website, so what we can do is 14 00:01:20,189 --> 00:01:26,189 we can set up buckets for each one of those domain names and we can have 15 00:01:26,189 --> 00:01:32,490 that redirected through to whatever domain that we want and we do that using 16 00:01:32,490 --> 00:01:38,880 the s3 website hosting redirection feature. Now what we need to do is 17 00:01:38,880 --> 00:01:46,409 we need to go into s3 to make this happen, so what we'll do is we'll go into 18 00:01:46,409 --> 00:01:52,649 this bucket that we had before and we go into properties and we go into static 19 00:01:52,649 --> 00:01:59,640 website hosting and what we're going to do is redirect requests to somewhere 20 00:01:59,640 --> 00:02:04,469 I've just put in there google.com and and I just did that so that you know 21 00:02:04,469 --> 00:02:08,640 that it doesn't have to be a website that you own you can direct it to anywhere 22 00:02:08,640 --> 00:02:13,319 on the Internet as long as it's a publicly accessed endpoint 23 00:02:13,319 --> 00:02:15,480 so I'm just putting there google.com so if I want everything to 24 00:02:15,480 --> 00:02:21,959 come into thedevkid.com it's going to get forwarded over to or redirected over 25 00:02:21,959 --> 00:02:28,319 to Google.com. So I'm just going to save that, now if I go to this static website 26 00:02:28,319 --> 00:02:34,620 again and I click on the endpoint, it's taking me to Google instead of 27 00:02:34,620 --> 00:02:39,300 taking me to somewhere else, so the only thing we need to do now is to go into 28 00:02:39,300 --> 00:02:44,160 route 53 and create a record that is going to direct traffic for our thedevkid.com 29 00:02:44,160 --> 00:02:51,030 through to this endpoint here, okay so let's jump into the route 53 management console 30 00:02:51,030 --> 00:02:56,340 so what I need to do now is I need to get this thedevkid.com 31 00:02:56,340 --> 00:03:00,330 and it's going to delete the a record that we've set up that's going to 32 00:03:00,330 --> 00:03:03,810 redirect to our cloud front distribution. I'm going to delete that one and 33 00:03:03,810 --> 00:03:10,049 recreate it, so create record set, we'll leave that the same it's an a record still 34 00:03:10,049 --> 00:03:15,959 but it's an alias again but this time instead of selecting that CloudFront distribution 35 00:03:15,959 --> 00:03:23,070 we're going to select our s3 website endpoint, what will happen is that 36 00:03:23,070 --> 00:03:26,340 when it hits that website endpoint it's going to redirect all that traffic 37 00:03:26,340 --> 00:03:29,910 through to google.com because that's the way we've got it set up, so just click on create 38 00:03:29,910 --> 00:03:34,890 once that's propagated through we'll be able to do that, now I've already 39 00:03:34,890 --> 00:03:39,480 done it before, so it should already have been propagated, so I'm just going to put it 40 00:03:39,480 --> 00:03:43,530 in here into what's my DNS, search on that, and there we can see it has come through 41 00:03:43,530 --> 00:03:49,320 so if I go to that domain again have a look and there we go 42 00:03:49,320 --> 00:03:55,260 it's redirected automatically to google.com which is pretty good, now we can do the same 43 00:03:55,260 --> 00:04:01,890 for the www, what we need to do to make that happen is that we need to 44 00:04:01,890 --> 00:04:07,140 create another bucket so we've got our thedevkid.com bucket, we need to 45 00:04:07,140 --> 00:04:14,280 create another bucket called WWW thedevkid.com and then again we create the static 46 00:04:14,280 --> 00:04:22,320 website and this time we would grab that domain - the HTTP stuff and we 47 00:04:22,320 --> 00:04:27,120 would copy that over into here and we would put that in and in the cname and 48 00:04:27,120 --> 00:04:29,910 we would get rid of that delete that and we would 49 00:04:29,910 --> 00:04:36,360 put that in there and and that will redirect that traffic through to that www 50 00:04:36,360 --> 00:04:41,220 it won't if you put the the apex domain one in there it won't work 51 00:04:41,220 --> 00:04:45,930 so you need to have one specifically for www, a bucket for that and redirect that traffic 52 00:04:45,930 --> 00:04:52,320 using that here, so I'm not going to go into that because it's just extra 53 00:04:52,320 --> 00:04:55,530 work that it's not really going to add any value it's all in the notes if you want to 54 00:04:55,530 --> 00:04:59,280 go through and do that bit yourself as well. so that brings us to 55 00:04:59,280 --> 00:05:05,040 the end, you have covered a great deal of stuff, so you now will have a very good 56 00:05:05,040 --> 00:05:11,310 knowledge of AWS I'm sure and now it's time for you to download those lab notes 57 00:05:11,310 --> 00:05:17,070 go through them very carefully and take your time because there's a lot going on 58 00:05:17,070 --> 00:05:20,670 here and make sure that everything's right and hopefully you get to the end 59 00:05:20,670 --> 00:05:24,900 if not just drop me a question and I'll be able to help you out I look forward 60 00:05:24,900 --> 00:05:27,920 to seeing you in the next one.