docs / integrations

Enhance Panel integration

This is experimental, since pdns.conf isn’t yet persistent in docker container, but it will be soon. 

Enhance runs on Ubuntu, so we gonna need our .deb packages.

  1. Install Agent on Ubuntu
mkdir -p /etc/apt/keyrings/ 
wget -O /etc/apt/keyrings/nixpal.gpg -q https://repo.nixpal.com/debian/KEY.gpg 
apt-key add /etc/apt/keyrings/nixpal.gpg 
wget -O /etc/apt/sources.list.d/nixpal.list https://repo.nixpal.com/debian/nixpal.list 
apt-get update
apt install zcloudagent

2. Configure Agent:

In /etc/zcloudagent.conf add your Token, License, and CONTROLLER’s Hostname:

TOKEN=Token_From_zCloud_Server
SERVER_HOSTNAME=controller.yourdomain.com
LICENSE=ZCAgent-xxxxxxxxxxx

Because we gonna use PowerDNS Don’t Forget we also need:

DNS_SERVER_TYPE=PDNS

and PDNSUTIL_BINARY_PATH. 

But because PowerDNS Is in a container we move slightly different. So we need:

PDNSUTIL_BINARY_PATH=docker exec dnscd /usr/bin/pdnsutil

So our complete conf should be something like:

ZONES_FILE=/etc/named.conf
TOKEN=Token_From_zCloud_Server
SERVER_HOSTNAME=controller.yourdomain.com
UPDATE_INTERVAL=60
LOG_LEVEL=1
LICENSE=ZCAgent-xxxxxxxxxxx
//If your server uses PowerDNS uncomment the following 2 lines
DNS_SERVER_TYPE=PDNS
PDNSUTIL_BINARY_PATH=docker exec dnscd /usr/bin/pdnsutil

We can enable  zcloudagent now. But we still got work to do.

systemctl enable zcloudagent

You should see your zones syncing.

ENHANCE SETUP

On the Enhance Panel you are going to add your custom Zonecloud nameservers.

Go to Settings > Platform > DNS zone templating and add your records like this:

KIND NAME VALUE TTL OVERRIDE
NS

|

@

|

ns1.myip.gr.

|

1 day

| YES |

| |

NS

|

@

|

ns2.myip.gr.

|

1 day

| YES |

|

You also need to make PowerDNS notify our Nameservers.

We need to get inside the docker container of dns.

docker exec -it dnscd bash

There is no vi, vim or nano, so let’s install something.

root@e22be4081067:/# apt install nano -y

We need to add our pdns.conf config.
Config is located at:

/etc/powerdns/pdns.conf

Grab the config from your Controller web interface > Servers > Configuration button.
Paste it on top of the file, save, exit.

No systemd on container. Sorry systemd. You Have No Power Here.
Let’s restart PowerDNS and check if it’s ok:

root@e22be4081067:/etc/powerdns# service pdns restart
Restarting PowerDNS Authoritative Server: pdns ...done
root@e22be4081067:/etc/powerdns# service pdns status

pdns is running: 580: Child running on pid 582
root@e22be4081067:/etc/powerdns#

root@e22be4081067:/etc/powerdns# ps aux
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 1 0.0 0.2 378888 11924 ? Ssl 14:14 0:04 ./dnscd
root 17 0.0 0.0 0 0 ? Zs 14:14 0:00 [pdns_server]
pdns 19 0.0 0.0 0 0 ? Z 14:14 0:00 [pdns_server]
root 76 0.0 0.0 4116 3536 pts/0 Ss+ 14:20 0:00 bash
root 533 0.0 0.0 4248 3656 pts/1 Ss 15:50 0:00 bash
root 580 0.0 0.2 107216 8980 ? Ssl 15:52 0:00 /usr/sbin/pdns_server –daemon –guardian=yes
pdns 582 0.0 0.5 577580 20692 ? Sl 15:52 0:00 /usr/sbin/pdns_server-instance –daemon –guardian=yes
root 616 0.0 0.0 5900 3064 pts/1 R+ 15:54 0:00 ps aux
root@e22be4081067:/etc/powerdns#

Seems ok.

You can start and check zcloudagent now,

systemctl start zcloudagent

systemctl status zcloudagent

It should sync your Enhance’s zones with your own nameservers and per server zones only without conflicts.

If there any problems don’t forget to check pdns inside the docker container!