Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Cloud DNS or Google Public DNS

Why would you want to use "Google Cloud DNS" when "Google Public DNS" is free?

How do you setup a DNS/nameserver to point to a compute engine:
1. Set you domain registrator(GoDaddy.com in my case) settings/"nameserver" to point to the DSN server provider you are using.
2. Login into DNS server provider(any suggestions?) and set the static ip address to be mapped to you domain name.

Is the above, the right process to setup a DNS for a web server?

Regards Chris

like image 865
Chris G. Avatar asked Feb 11 '23 17:02

Chris G.


2 Answers

Google Cloud DNS provides you with authoritative name servers which you can configure with your DNS records. Google Public DNS is only a name resolver which looks up data from the authoritative name server. See http://en.wikipedia.org/wiki/Name_server for more detailed information about authoritative name servers and caching resolvers.

And yes, that process should work. Google Cloud DNS is one example of the provider you are looking for.

like image 172
Alyssa Pittman Avatar answered Mar 04 '23 04:03

Alyssa Pittman


To setup Google DNS with Google Compute Engine, this is what you would do:

Create your managed zone

gcloud dns managed-zone create --dns_name="example.com." --description="Something descriptive" "myzonename"

Get your nameservers, and update them at your domain registrar

gcloud dns records --zone="myzonename" list

Create your records and edit them

gcloud dns records --zone="myzonename" edit

Under Additions, add the A records that point to your Compute Engine VM's IP address

{ "additions": [ { "kind": "dns#resourceRecordSet", "name": "example.com.", "rrdatas": [ "192.168.2.20" ], "ttl": 86400, "type": "A" }, { "kind": "dns#resourceRecordSet", "name": "www.example.com.", "rrdatas": [ "192.168.2.20" ], "ttl": 86400, "type": "A" } ], "deletions": [ { "kind": "dns#resourceRecordSet", "name": "example.com.", "rrdatas": [ "ns-cloud1.googledomains.com. dns-admin.google.com. 2 21600 3600 1209600 300" ], "ttl": 21600, "type": "SOA" } ] }

Save and exit. You should be good to go now.

like image 40
Thien Hoang Avatar answered Mar 04 '23 04:03

Thien Hoang