Browse Source

added pdnsutil support in poweradmin

tags/v2.0.0
Robin Thoni 7 years ago
parent
commit
049eabb004

+ 1
- 0
.gitignore View File

@@ -1,2 +1,3 @@
1 1
 *.swp
2 2
 /data
3
+docker-compose.override.yml

+ 2
- 0
pdns/Dockerfile View File

@@ -23,6 +23,8 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get update &&\
23 23
 
24 24
 RUN rm -rf /var/log/*
25 25
 
26
+RUN rm -rf /etc/powerdns/*
27
+
26 28
 COPY ./vars-vars /etc/vars-vars
27 29
 
28 30
 COPY ./vars-files /etc/vars-files

+ 21
- 0
poweradmin/Dockerfile View File

@@ -28,6 +28,25 @@ RUN rm -rf /var/log/* &&\
28 28
     ln -s /dev/stdout /var/log/apache2/access.log &&\
29 29
     ln -s /dev/stdout /var/log/apache2/other_vhosts_access.log
30 30
 
31
+RUN apt-get update && \
32
+    apt-get install -y curl && \
33
+    apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
34
+
35
+RUN dist=$(if uname -m | grep -iq arm  ; then echo raspbian; else echo debian; fi) &&\
36
+     echo "deb http://repo.powerdns.com/${dist} jessie-auth-40 main" > /etc/apt/sources.list.d/pdns.list && \
37
+    echo 'Package: pdns-*\nPin: origin repo.powerdns.com\nPin-Priority: 600' > /etc/apt/preferences.d/pdns && \
38
+    curl https://repo.powerdns.com/FD380FBB-pub.asc | apt-key add -
39
+
40
+COPY ./preseed.txt /tmp/preseed.txt
41
+
42
+RUN debconf-set-selections /tmp/preseed.txt
43
+
44
+RUN DEBIAN_FRONTEND=noninteractive apt-get update &&\
45
+    apt-get install -y pdns-server pdns-backend-pgsql &&\
46
+    apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
47
+
48
+RUN rm -rf /etc/powerdns/*
49
+
31 50
 COPY apache2.conf /etc/apache2/apache2.conf
32 51
 
33 52
 COPY ./poweradmin-2.1.7/ /var/www/html/
@@ -44,6 +63,8 @@ RUN mkdir "${CONFIG_DIR}"
44 63
 
45 64
 COPY ./poweradmin-2.1.7/inc/config.inc.php "${CONFIG_DIR}"/config.inc.php
46 65
 
66
+COPY ./pdns.conf "${CONFIG_DIR}"/pdns.conf
67
+
47 68
 EXPOSE 80
48 69
 
49 70
 CMD ["/run.sh"]

+ 12
- 0
poweradmin/pdns.conf View File

@@ -0,0 +1,12 @@
1
+# PostgreSQL Configuration
2
+#
3
+# Launch gpgsql backend
4
+launch=gpgsql
5
+
6
+# gpgsql parameters
7
+gpgsql-host=POSTGRES_HOST
8
+gpgsql-port=
9
+gpgsql-dbname=POSTGRES_DB
10
+gpgsql-user=POSTGRES_USER
11
+gpgsql-password=POSTGRES_PASSWORD
12
+gpgsql-dnssec=yes

+ 3
- 0
poweradmin/poweradmin-2.1.7/inc/config.inc.php View File

@@ -15,3 +15,6 @@ $dns_hostmaster   = 'DNS_HOSTMASTER';
15 15
 $dns_ns1    = 'DNS_NS1';
16 16
 $dns_ns2    = 'DNS_NS2';
17 17
 $dns_ttl = DNS_TTL;
18
+
19
+$pdnssec_use = true;
20
+$pdnssec_command = '/usr/bin/pdnsutil';

+ 28
- 0
poweradmin/preseed.txt View File

@@ -0,0 +1,28 @@
1
+pdns-backend-pgsql  pdns-backend-pgsql/app-password-confirm password  
2
+pdns-backend-pgsql  pdns-backend-pgsql/password-confirm password  
3
+pdns-backend-pgsql  pdns-backend-pgsql/pgsql/admin-pass password  
4
+pdns-backend-pgsql  pdns-backend-pgsql/pgsql/app-pass password  
5
+pdns-backend-pgsql  pdns-backend-pgsql/dbconfig-upgrade boolean true
6
+pdns-backend-pgsql  pdns-backend-pgsql/remote/port  string  
7
+pdns-backend-pgsql  pdns-backend-pgsql/dbconfig-reinstall boolean false
8
+pdns-backend-pgsql  pdns-backend-pgsql/pgsql/authmethod-user  select  
9
+pdns-backend-pgsql  pdns-backend-pgsql/purge  boolean false
10
+pdns-backend-pgsql  pdns-backend-pgsql/upgrade-error  select  abort
11
+pdns-backend-pgsql  pdns-backend-pgsql/dbconfig-install boolean false
12
+pdns-backend-pgsql  pdns-backend-pgsql/db/app-user  string  pdns
13
+pdns-backend-pgsql  pdns-backend-pgsql/remote/newhost string  
14
+pdns-backend-pgsql  pdns-backend-pgsql/pgsql/manualconf note  
15
+pdns-backend-pgsql  pdns-backend-pgsql/remote/host  select  
16
+pdns-backend-pgsql  pdns-backend-pgsql/pgsql/admin-user string  postgres
17
+pdns-backend-pgsql  pdns-backend-pgsql/database-type  select  pgsql
18
+pdns-backend-pgsql  pdns-backend-pgsql/upgrade-backup boolean true
19
+pdns-backend-pgsql  pdns-backend-pgsql/internal/skip-preseed  boolean true
20
+pdns-backend-pgsql  pdns-backend-pgsql/remove-error select  abort
21
+pdns-backend-pgsql  pdns-backend-pgsql/missing-db-package-error select  abort
22
+pdns-backend-pgsql  pdns-backend-pgsql/pgsql/changeconf boolean false
23
+pdns-backend-pgsql  pdns-backend-pgsql/dbconfig-remove  boolean 
24
+pdns-backend-pgsql  pdns-backend-pgsql/pgsql/method select  unix socket
25
+pdns-backend-pgsql  pdns-backend-pgsql/pgsql/authmethod-admin select  ident
26
+pdns-backend-pgsql  pdns-backend-pgsql/install-error  select  abort
27
+pdns-backend-pgsql  pdns-backend-pgsql/internal/reconfiguring boolean false
28
+pdns-backend-pgsql  pdns-backend-pgsql/db/dbname  string  pdns

+ 1
- 0
poweradmin/vars-files View File

@@ -1 +1,2 @@
1 1
 config.inc.php /var/www/html/inc/config.inc.php
2
+pdns.conf /etc/powerdns/pdns.conf

Loading…
Cancel
Save