How To Connect Your Domain To Ec2 Instance With Route 53

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hey guys welcome back again to another tutorial today we're going to connect our domain name to our ec2 instance that we created in the previous videos um right now the domain we're going to be using is this domain the codes and pixels dot me registered at pogba um they're not sponsoring me anyway so uh we go to route 53 on adws firstly we need to create an uh a hosted zone basically like a like a container that will hold this particular domain for us and we put in the domain name i usually put in the domain name and then i also give it a description so i and a tag so i can be able to uh distinguish which domain in switch because as you keep adding more domains you're probably going to end up confusing yourself with which domain is quite so i give it a name on the tag and then we proceed once you do once you create a hosted zone it's gonna create dns servers and that it's gonna create some name servers for you to use so you're gonna copy that and go back to your uh where you registered your domain maybe code id i use pogba enum is another one and you replace your default name service with the amazon name service and that's what i'm doing here once you do that there's actually not much else you need the only thing i figured is that sometimes you have to add the ipr the elastic ip address of the ec2 server on your domain register as well i do that it's not necessary but i do that as well so now we go back to our so here we've we've actually added the name servers now we'll go back to our instance we go we pick the ip address which is the elastic ip that i've been working with and we go to the zone file on our registrar and we create an error code for the the domain i'll call some pixels we save that and then i also create another uh a couple of them i think three of them so we have the one for cuts and pixels the one with the wildcat and then the www uh domain and we tie those two to the ip addresses the rest of those zone records we're going to delete them because we don't need it so once we're done we close this i will come back here to delete those later stage and then we go to our route 53 and we start creating our records on the route 53 since once the the domain resolves and everything is routed via aws servers then we have to now create our records on the on the hosted on the hosted zone on aws so here i'm removing the the records that are on pogba so that it doesn't conflict with the one on aws if you just registered your domain and you've not used it for anything you probably won't have much of this on your on your domain records but i've been playing around with this uh in previous tutorials and testing that i've been doing so that's how i have a lot of these uh on i'll still share those tutorials later on so this is what you should have on your zone file uh and and they should be good to go so you have the the domain the wildcard and the www and that's it you're done basically with pogba or your domain register and here you go back to route 53 and we go to our hosted zone before we do that i usually use dns checker to check the name server to see if it's resolved is a very good tool actually so here i type in the domain and i select the name server and i click on search once you click on search it's going to go through and it's going to try and see if it's uh if it's resolving correctly so you'll see the the name service that we we added it's now showing up with the with a green check mark on it if it's not resolving you'll see it as a as a red red cross on it so everything seems to be fine um right now so the next thing we have to do uh is to go back to the ec2 server the instance and once we are there we're going to pick the copy the ip address the elastic ip address and we go back to route 53 and we go to our hosted zone we only have one but as we grow we're gonna have other ones there so we go to code some pixels and we open that uh hosted zone and we're going to add more records on it so here we are in the normal record and we tie it to the ip address and it's going to be an a record and create that record we could have actually done all of them in the same window but let's do it one by one so you can understand and here with dwindle wildcard one and we also make it an a record and we add it at the ip address and the last one i think should be the www record so we type that in www and we add the ip address the elastic ip address and we create that record and i think that's uh pretty much all we need to do for now so um if we go to dns checker and we check the a record now as you can see the the setting is on the a record and you can see this takes a little bit more time to resolve so just be a bit patient with it because remember we removed uh some of the information on pogba so it's going to take a while to to to resolve all of it if we try the to access the domain we will not get um access to it i'll tell you well the reason is because our security group when we created the instance we only allowed access to ssh so now we need to add make some changes on the security group so we can add http and https access as well as mysql and any other ports we need to open so we open the security group you see here we only have the ssh enabled so the inbound rules is only ssh that is open so if you open the security group we go to edit i'm gonna go to edit rules and here you see that the only rule we have is inbound is a ssh so we're going to add http and we're going to add https and we're going to add my my secure because you're going to be running wordpress later on and this three we should do for now and we open the ports to anywhere or to specific ip addresses if you want that's up to you but i usually do do it this way and you save the rules now if we go back to the browser and we try to access the the domain we should see that the the new domain is now active and open and available publicly and there you go so thank you for watching and come back again for the next lesson like share and subscribe peace
Info
Channel: Codes and Pixels
Views: 3,492
Rating: undefined out of 5
Keywords: cloud computing, amazon web services, aws tutorial, aws training, aws tutorial for beginners, aws, how to, php, phpmyadmin, php tutorial, ubuntu, web development, ubuntu server, apache server, how to install ubuntu, web developer, apache2, route 53 aws tutorial, route 53, aws route 53, route 53 aws, routing policy in route 53, route 53 aws godaddy, nameserver change godaddy, route 53 resolver, aws route53, route 53 tutorial, aws route 53 tutorial, aws route 53 domain setup
Id: mIxVfS68_J0
Channel Id: undefined
Length: 9min 21sec (561 seconds)
Published: Fri Feb 26 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.