amuck-landowner

Running your own vestacp instance

wlanboy

Content Contributer
VestaCP is a free and open source contol panel.

I am running two instances for about three months and have to admit that I do like it more than zpanel.

The basic configuration is solid and the integration of:

  • Nginx
  • SSL
  • SPF and DKIM
  • AntiSpam / Antivirus
  • Backups
is really well done.

Installation is done by following two commands:


curl -O http://vestacp.com/pub/vst-install.sh
sudo bash vst-install.sh

Enter a valid email address where the login information is sent to.

The welcome email looks like this:


Congratulations, you have just successfully installed the Vesta Control Panel

You can login in Vesta with following credentials:
username: admin
password: ***************
https://ip-address:8083

We hope that you enjoy your installation of Vesta. Please feel free to contact us anytime if you have any questions.
Thank you.

--
Sincerely yours
vestacp.com team

Things I changed:

1. Add SSL support for mail server:


nano nano /etc/exim4/exim4.conf.template

Uncomment following lines:


# tls_advertise_hosts = *
# tls_certificate = /usr/local/vesta/ssl/certificate.crt
# tls_privatekey = /usr/local/vesta/ssl/certificate.key

You should replace the generated certs with your own.

The SSL certs for web can be entered through the web frontend.

2. Add secondary DNS servers

The dns zone files are located at:


/home/[user]/conf/dns/[domainname].db

If you look to the bind config:


cat /etc/bind/named.conf

Content:


// This is the primary configuration file for the BIND DNS server named.
//
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the
// structure of BIND configuration files in Debian, *BEFORE* you customize
// this configuration file.
//
// If you are just adding zones, please do that in /etc/bind/named.conf.local

include "/etc/bind/named.conf.options";
include "/etc/bind/named.conf.local";
include "/etc/bind/named.conf.default-zones";

zone "domain.com" {type master; file "/home/admin/conf/dns/domain.com.db";};


The zone files themselfs are allready defined as master!

So we only have to definde the options:


nano /etc/bind/named.conf.options

And add:


options {
allow-transfer { [ip-address of slave]; };
notify yes;
};

On the secondary dns servers we just have to add the zones to the named.conf:


nano /etc/bind/named.conf

Add:


zone "domain.com" {
type slave;
masters { [ip of vestacp server]; };
file "domain.com.db";
};

Done.

As I said - everything prepared and well performed.

Really enjoying my VerstaCP time.
 

nunim

VPS Junkie
... The SSL certs for web can be entered through the web frontend. ...
How?  Editing default domain?  I haven't figured out how to do this yet for the CP only domains, been too lazy to install my cert through SSH.

Very happy with VestaCP so far, it's been 3x WordPress sites and some random others for me for the last 2 months and it's been working great.  Their UI could use a little bit of polish but they seem to be actively improving things and I've read support for nginx+php-fpm  only is not far off.
 
Last edited by a moderator:

wlanboy

Content Contributer
How?  Editing default domain?  I haven't figured out how to do this yet for the CP only domains, been too lazy to install my cert through SSH.
Quite simple.

Select "web" -> "edit" domain and klick on the "SSL" checkbox.

That will popup the SSL boxes:

vestadomainssl.jpg
 

jarland

The ocean is digital
How?  Editing default domain?  I haven't figured out how to do this yet for the CP only domains, been too lazy to install my cert through SSH.

Very happy with VestaCP so far, it's been 3x WordPress sites and some random others for me for the last 2 months and it's been working great.  Their UI could use a little bit of polish but they seem to be actively improving things and I've read support for nginx+php-fpm  only is not far off.
If you want SSL for the panel itself, you want /usr/local/vesta/nginx/conf/nginx.conf
 

nunim

VPS Junkie
If you want SSL for the panel itself, you want /usr/local/vesta/nginx/conf/nginx.conf
Ah, I figured as much.  I got confused when he said certs for the web, I assumed he meant the panel itself. At least my default domain has SSL now :)   I'll get around to it eventually, just haven't had much of a need as I'm the only one who sees the panel. 
 

Joodle

Member
Seems like a nice panel. Will try this out as soon as I have a new VPS xd.

Sent from my Samsung Galaxy S4 Mini LTE using Tapatalk
 

nehafarzana80

New Member
@wlanboy

Thanks for the nice tutorial. I have configured two DNS servers as ns1.mydomain.com, ns2.mydomain.com to other 2 VPSs. I want to use mydomain2.com to use ns1-ns2.mydomain.com too. But, each time I need to change DNS settings to slave servers  ie; [ zone "domain.com" {

type slave;
masters { [ip of vestacp server]; };
file "domain.com.db";
};

Is there any option to automate this process? I mean when I will add an addon domain, slave servers will sync the zone info automatically?

Thanks for your help.
 

wlanboy

Content Contributer
@wlanboy

Thanks for the nice tutorial. I have configured two DNS servers as ns1.mydomain.com, ns2.mydomain.com to other 2 VPSs. I want to use mydomain2.com to use ns1-ns2.mydomain.com too. But, each time I need to change DNS settings to slave servers  ie; [ zone "domain.com" {

type slave;

masters { [ip of vestacp server]; };

file "domain.com.db";

};

Is there any option to automate this process? I mean when I will add an addon domain, slave servers will sync the zone info automatically?

Thanks for your help.
Not an easy one.

You can create a dns-cluster using "/usr/local/vesta/bin/v-add-remote-dns-host".

First you have to create a new user "dns-cluster" to all instances.

Afterwards you have to add the dns hosts on the master:


root@devboxindallas:/usr/local/vesta/bin# ./v-add-remote-dns-host
Error: not enought arguments
Usage: v-add-remote-dns-host HOST PORT USER PASSWORD [TYPE] [DNS_USER]

So e.g.:
./v-add-remote-dns-host ns1.wlanboy.com 8083 admin password
This of course includes that all servers are running VestaCP...

I am using small 64 MB vps for dns slaves - so no chance to install Vesta CP on them.
 

jarland

The ocean is digital
I am using small 64 MB vps for dns slaves - so no chance to install Vesta CP on them.
New challenge: To strip Vesta to bare essentials for DNS clustering, in a way that Vesta reads as a slave without problem.
 

wlanboy

Content Contributer
New challenge: To strip Vesta to bare essentials for DNS clustering, in a way that Vesta reads as a slave without problem.
Would be a nice to have - but all the jobs/crons/auth is based on the database.

So php + Mysql + DNS on 64 MB RAM. Tough goal.
 

Reece-DM

New Member
Verified Provider
I will have to say I've been using this for a few weeks myself on various projects, its a nice bit of kit!
 
Top
amuck-landowner