Setting up DNS records
There are many popular domain name registrars that allow you to pay to rent a domain name. Professor S has paid for the is404.net domain name, and uses the Cloudflare registry, which has its own page to edit DNS records. Unfortunately he can't share his Cloudflare credentials with all of you, so instead he created a super janky website where you can manage the DNS records yourself.
Objectives
- Use Professor S's custom website to create and edit DNS records for your website
- Learn how to use A and CNAME records
Prerequisites
- An EC2 instance with an Elastic IP address
- Access to a domain name (for current students, access is provided through dns.schuetzler.net)
Steps
Creating an A record
A records are the workhorses of DNS. It's where the rubber hits the road of turning a name into an IP address.
- Go to https://dns.schuetzler.net to manage domains for the is404.net domain
- Click the "Create new record" button to create a new record
- On the new record form, input the following information:
- Name: This needs to be the full domain name (including is404.net). For example, if my netID was "rms96", I could put
rms96.is404.net
- Type: For the A record, choose A as the record type
- Content: This needs to contain the public IPv4 address of your server (e.g.,
54.69.14.191
) - TTL:
1
lets Cloudflare manage the TTL, which is just fine, so leave it as1
.
- Name: This needs to be the full domain name (including is404.net). For example, if my netID was "rms96", I could put
- Click Save to save the record.
If all of the information was correct, you will get a JSON message indicating the record was created successfully. If there is an issue with your form, you will receive an error message from the server indicating that part of the record had a problem. Correct the error and try again.
If you had a working website you could visit at http://your.ip.address, you can now visit it at http://yourdomain.is404.net. Note that it still uses only HTTP (not HTTPS), and you'll have to specify the http
(not https) in the URL.
Creating a CNAME record
CNAME records are aliases - a way to give a server another name so that multiple DNS records can resolve to the same IP address. Creating a CNAME works pretty much the same as an A record, but the Content of the record is different.
- Go to https://dns.schuetzler.net
- Click the button to Create new record
- In the form, put in the information:
- Name: This will be the new domain name alias you want to create. For example, I could create
coolsite.rms96.is404.net
- Type: Select CNAME
- Content: This needs to be the A record you want to point to. In my case, I would use
rms96.is404.net
- TTL: 1 is fine
- Name: This will be the new domain name alias you want to create. For example, I could create
- Click Save to create the record
If all of the information was correct, you will get a JSON message indicating the record was created successfully. If there is an issue with your form, you will receive an error message from the server indicating that part of the record had a problem. Correct the error and try again.