Proper DNS setup?

General questions about VestaCP
brafi
Posts: 2
Joined: Sat Sep 16, 2017 9:41 pm

Proper DNS setup?

Postby brafi » Sun Sep 17, 2017 10:39 am

Hi

I have my domains hosted at a free DNS-provider in Denmark (gratisdns.dk) and have the following setup here:

A record:
"domain.dk" pointing to my IP
"mail.domain.dk" pointing to my IP

CNAME:
*domain.dk pointing to "domain.dk"

MX:
mail.domain.dk pointing to mail.domain.dk (Preference 10, TTL 43200)


My question is:
How should I setup the DNS on vestacp?

raiden
Posts: 7
Joined: Sun Sep 17, 2017 11:17 am

Re: Proper DNS setup?

Postby raiden » Sun Sep 17, 2017 11:25 am

Use same record, but your not good, try this
A record:
"domain.dk" to IP
"mail.domain.dk" to IP
"*.domain.dk" to IP
CNAME:
www.domain.dk to "domain.dk"
MX:
mail.domain.dk to domain.dk (Preference 10, TTL 43200)

brafi
Posts: 2
Joined: Sat Sep 16, 2017 9:41 pm

Re: Proper DNS setup?

Postby brafi » Sun Sep 17, 2017 12:24 pm

So I should use the same records on Vespa, on my local network?
What IP, should I use? The public IP, or the internal local IP?

And why are I not good, with the solution?
What should be the optimal solution?

And meanwhile I am asking about DNS, is it then possible to have a subdomain pointing to another internal server?
Case:
I have one public ip, and would like vestacp to host mail, web, DNS and ftp on the same server.
Then I would like to add a subdomain / new domain for another local machine (owncloud)?

So one server with vestaCP and another server with owncloud, and only one public IP for both?

adamjedgar
Posts: 14
Joined: Tue Apr 18, 2017 7:55 am

Re: Proper DNS setup?

Postby adamjedgar » Tue Sep 19, 2017 7:24 pm

Just dont get confused with whuch dns records go on your machines...you are not providing dns records for your own domain name...you say you have done this part via A records at your own registrar. You do not need to do it twice.

If you are setting up dns on your server, the dns records you are talking about are for any of your client domains. This does require an additional step at your registrar...your registrar nameservers need to know where to send requests to find dns records for your own clients webhosting ipadresses. For the ns lookup to work, your nameservers need to be registered at your own domain registrar so it knows to send web browsers to your nameservers to retrieve a website hosting ipaddress.

An easier option in the short term is to do the following...

1. Your webserver ip address never changes (must be static)
2. All your clients point appropriate A records at your webserver external ip adress for their website
3. Vestacp looks after the rest automatically...ensuring the requested website is loaded on a users browser.

I hve not talked about configuring subdomains, email, ptr or any of that stuff...the above is just a simple basic solution for client websites hosting. If mail is also needed, then they would also need to add zone record pointing at a mail server with appropriate client email account on it. This can be the same server as the webhosting one if you have setup vesta to run mail as well, or it can be a different one run by you or somebody else (eg office 365 outlook, gmail, yahoomail etc)

Essentially i am saying,you do not need to host your own dns service (ie running your own nameservers) for any of this. It can be done via A records at registrars. Hosting your own dns is more convenient for you, but also a disaster if your dns service comes under attack and the system you have configured isnt powerful enough to absorb the attack an remain functional...every one of your clients using your dns will be affected because YOU are acting as the SOA. By using the A record method, the respective registrars for each of your clients are the SOA.

Finally, unless you are running your own infrastructure(your own servers) most providers who wholesale services to you already use cloud infrastructure. Unless there is a specific reason for it, i am not convinced its worth the trouble to reinvent the wheel by setting up a cloud within a cloud.


Return to “General Discussion”



Who is online

Users browsing this forum: No registered users and 7 guests

cron