Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=frugalware-current.git;a=commitdiff;h=585f30f71833044ededf13c0519c80846c79be4c

commit 585f30f71833044ededf13c0519c80846c79be4c
Author: James Buren <r...@frugalware.org>
Date:   Sat Jul 14 11:37:58 2012 -0500

pdns-3.1-1-x86_64
* version bump
* convert to systemd schema
* backup /etc/powerdns/pdns.conf
* provide systemd service
* add documentation about how to use mysql or postgresql locally

diff --git a/source/network-extra/pdns/FrugalBuild 
b/source/network-extra/pdns/FrugalBuild
index a18a05c..8e3c0ca 100644
--- a/source/network-extra/pdns/FrugalBuild
+++ b/source/network-extra/pdns/FrugalBuild
@@ -4,23 +4,26 @@
# Contributor: Zoltan Kiss <djsmi...@frugalware.org>

pkgname=pdns
-pkgver=3.0
-pkgrel=2
+pkgver=3.1
+pkgrel=1
pkgdesc="Power DNS Server and Recursor"
url="http://www.powerdns.com/";
-depends=('libstdc++' 'sqlite2' 'libmysqlclient' 'libpq' 'pdns-recursor>=3.3-1' 
'libboost>=1.49.0')
+depends=('libstdc++' 'sqlite2' 'libmysqlclient' 'libpq' 'libboost>=1.49.0')
makedepends=('mysql' 'postgresql' 'boost')
groups=('network-extra')
archs=('i686' 'x86_64')
up2date="lynx --dump 'http://downloads.powerdns.com/releases/?C=M;O=D' | grep 
pdns-.*gz$ | egrep -v '(rc|beta|pre)' | sed 's/.*-\(.*\)\.t.*/\1/;q'"
+backup=(etc/powerdns/pdns.conf)
source=(http://downloads.powerdns.com/releases/$pkgname-$pkgver.tar.gz \
rc.pdns \
-       pdns.conf)
-signatures=($source.sig '' '')
-#sha1sums=('2c0888c8252299c5a17dc69eec289e90c7e8f3ff' \
-#          'a51e9ff119af06e682452b640c47a4732642ee3a' \
-#          '7c8e2c75ff2d070d2b15a7430285062edf972b59' \
-#        '1f5be126c92b78509ca542532a03d1c42a3effbb')
+       pdns.service \
+       pdns.conf \
+       README.Frugalware)
+signatures=($source.sig '' '' '' '')
+_F_sysvinit_units=(pdns)
+_F_systemd_units=(pdns=)
+Finclude systemd
+
build()
{
Fbuild \
@@ -30,11 +33,14 @@ build()
--with-pgsql-includes=/usr/include \
--with-sqlite-includes=/usr/include \
--with-modules="geo" \
-               --with-dynmodules="mysql gmysql gpgsql gsqlite pipe"
+               --with-dynmodules="gmysql gpgsql gsqlite pipe"
Fmkdir /lib/initscripts/messages/hu/LC_MESSAGES
msgfmt -o $Fdestdir/lib/initscripts/messages/hu/LC_MESSAGES/$pkgname.mo 
$startdir/hu.po
Frcd2 pdns
Ffile /etc/powerdns/pdns.conf
+       Ffile /lib/systemd/system/pdns.service
+       Fgenscriptlet
+       Frm /etc/powerdns/pdns.conf-dist
}

# optimization OK
diff --git a/source/network-extra/pdns/README.Frugalware 
b/source/network-extra/pdns/README.Frugalware
new file mode 100644
index 0000000..e149a12
--- /dev/null
+++ b/source/network-extra/pdns/README.Frugalware
@@ -0,0 +1,26 @@
+If you wish to use the gmysql or gpgsql backends with a local server, then
+follow these instructions.
+
+For gmysql, install `mysql` package.
+
+----
+pacman-g2 -Sy mysql
+----
+
+For gpgsql, install `postgresql` package.
+
+----
+pacman-g2 -Sy postgresql
+----
+
+Now, copy `/lib/systemd/system/pdns.service` to 
`/etc/systemd/system/pdns.service`.
+
+----
+cp -f /lib/systemd/system/pdns.service /etc/systemd/system/pdns.service
+----
+
+Uncomment the lines appropriate for your selected backend. The comments in
+the file will guide you. After all this, you must still ensure the specific
+database backend you are wanting to use is properly configured. This means
+both the pdns configuration and the setup for the mysql or postgresql daemon.
+Refer to pdns, mysql, and/or postgresql documentation for more information.
diff --git a/source/network-extra/pdns/pdns.conf 
b/source/network-extra/pdns/pdns.conf
index 29d3a8c..804b57c 100644
--- a/source/network-extra/pdns/pdns.conf
+++ b/source/network-extra/pdns/pdns.conf
@@ -1,13 +1,18 @@
# Autogenerated configuration file template
#################################
-# allow-axfr-ips       If disabled, DO allow zonetransfers from these IP 
addresses
+# allow-axfr-ips       Allow zonetransfers only to these subnets
#
-# allow-axfr-ips=
+# allow-axfr-ips=0.0.0.0/0,::/0

#################################
-# allow-recursion      List of netmasks that are allowed to recurse
+# allow-recursion      List of subnets that are allowed to recurse
#
-allow-recursion=127.0.0.1
+# allow-recursion=0.0.0.0/0
+
+#################################
+# allow-recursion-override     Set this so that local data fully overrides the 
recursor
+#
+# allow-recursion-override=no

#################################
# cache-ttl     Seconds to store packets in the PacketCache
@@ -22,7 +27,7 @@ allow-recursion=127.0.0.1
#################################
# config-dir    Location of configuration directory (pdns.conf)
#
-config-dir=/etc/powerdns/
+# config-dir=/usr/local/etc

#################################
# config-name   Name of this virtual configuration - will rename the binary 
image
@@ -45,6 +50,11 @@ config-dir=/etc/powerdns/
# default-soa-name=a.misconfigured.powerdns.server

#################################
+# default-ttl  Seconds a result is valid if not set otherwise
+#
+# default-ttl=3600
+
+#################################
# disable-axfr  Disable zonetransfers but do allow TCP queries
#
# disable-axfr=no
@@ -60,6 +70,26 @@ config-dir=/etc/powerdns/
# distributor-threads=3

#################################
+# do-ipv6-additional-processing        Do AAAA additional processing
+#
+# do-ipv6-additional-processing=no
+
+#################################
+# edns-subnet-option-number    EDNS option number to use
+#
+# edns-subnet-option-number=20730
+
+#################################
+# edns-subnet-processing       If we should act on EDNS Subnet options
+#
+# edns-subnet-processing=no
+
+#################################
+# entropy-source       If set, read entropy from this file
+#
+# entropy-source=/dev/urandom
+
+#################################
# fancy-records Process URL and MBOXFW records
#
# fancy-records=no
@@ -72,7 +102,7 @@ config-dir=/etc/powerdns/
#################################
# launch        Which backends to launch and order to query them in
#
-launch=bind
+# launch=

#################################
# lazy-recursion        Only recurse if question cannot be answered locally
@@ -85,7 +115,7 @@ launch=bind
# load-modules=

#################################
-# local-address        Local IP address to which we bind
+# local-address        Local IP addresses to which we bind
#
# local-address=0.0.0.0

@@ -100,17 +130,22 @@ launch=bind
# local-port=53

#################################
-# log-dns-details      If PDNS should log failed update requests
+# log-dns-details      If PDNS should log DNS non-erroneous details
#
# log-dns-details=

#################################
+# log-dns-queries      If PDNS should log all incoming DNS queries
+#
+# log-dns-queries=no
+
+#################################
# log-failed-updates    If PDNS should log failed update requests
#
# log-failed-updates=

#################################
-# logfile      Logfile to use
+# logfile      Logfile to use (Windows only)
#
# logfile=pdns.log

@@ -130,6 +165,11 @@ launch=bind
# master=no

#################################
+# max-cache-entries    Maximum number of cache entries
+#
+# max-cache-entries=1000000
+
+#################################
# max-queue-length      Maximum queuelength before considering situation lost
#
# max-queue-length=5000
@@ -142,29 +182,49 @@ launch=bind
#################################
# module-dir    Default directory for modules
#
-# module-dir=/usr/lib/pdns
+# module-dir=/usr/local/lib

#################################
-# negquery-cache-ttl   Seconds to store packets in the PacketCache
+# negquery-cache-ttl   Seconds to store negative query results in the 
QueryCache
#
# negquery-cache-ttl=60

#################################
-# only-soa     Make sure that no SOA serial is less than this number
+# no-shuffle   Set this to prevent random shuffling of answers - for 
regression testing
#
-# only-soa=org
+# no-shuffle=off

#################################
# out-of-zone-additional-processing     Do out of zone additional processing
#
-# out-of-zone-additional-processing=no
+# out-of-zone-additional-processing=yes
+
+#################################
+# overload-queue-length        Maximum queuelength moving to packetcache only
+#
+# overload-queue-length=0
+
+#################################
+# pipebackend-abi-version      Version of the pipe backend ABI
+#
+# pipebackend-abi-version=1

#################################
-# query-cache-ttl      Seconds to store packets in the PacketCache
+# query-cache-ttl      Seconds to store query results in the QueryCache
#
# query-cache-ttl=20

#################################
+# query-local-address  Source IP address for sending queries
+#
+# query-local-address=0.0.0.0
+
+#################################
+# query-local-address6 Source IPv6 address for sending queries
+#
+# query-local-address6=::
+
+#################################
# query-logging Hint backends that queries should be logged
#
# query-logging=no
@@ -175,12 +235,12 @@ launch=bind
# queue-limit=1500

#################################
-# receiver-threads     Number of receiver threads to launch
+# receiver-threads     Default number of Distributor (backend) threads to start
#
# receiver-threads=1

#################################
-# recursive-cache-ttl  Seconds to store packets in the PacketCache
+# recursive-cache-ttl  Seconds to store packets for recursive queries in the 
PacketCache
#
# recursive-cache-ttl=10

@@ -190,6 +250,21 @@ launch=bind
# recursor=no

#################################
+# retrieval-threads    Number of AXFR-retrieval threads for slave operation
+#
+# retrieval-threads=2
+
+#################################
+# send-root-referral   Send out old-fashioned root-referral instead of 
ServFail in case of no authority
+#
+# send-root-referral=no
+
+#################################
+# server-id    Returned when queried for 'server.id' TXT or NSID, defaults to 
hostname
+#
+# server-id=
+
+#################################
# setgid        If set, change group id to this gid for more security
#
# setgid=
@@ -200,9 +275,9 @@ launch=bind
# setuid=

#################################
-# skip-cname   Do not perform CNAME indirection for each query
+# signing-threads      Default number of signer threads to start
#
-# skip-cname=no
+# signing-threads=3

#################################
# slave Act as a slave
@@ -215,16 +290,36 @@ launch=bind
# slave-cycle-interval=60

#################################
+# slave-renotify       If we should send out notifications for slaved updates
+#
+# slave-renotify=no
+
+#################################
# smtpredirector        Our smtpredir MX host
#
# smtpredirector=a.misconfigured.powerdns.smtp.server

#################################
-# soa-minimum-ttl      Default SOA mininum ttl
+# soa-expire-default   Default SOA expire
+#
+# soa-expire-default=604800
+
+#################################
+# soa-minimum-ttl      Default SOA minimum ttl
#
# soa-minimum-ttl=3600

#################################
+# soa-refresh-default  Default SOA refresh
+#
+# soa-refresh-default=10800
+
+#################################
+# soa-retry-default    Default SOA retry
+#
+# soa-retry-default=3600
+
+#################################
# soa-serial-offset     Make sure that no SOA serial is less than this number
#
# soa-serial-offset=0
@@ -240,16 +335,46 @@ launch=bind
# strict-rfc-axfrs=no

#################################
+# tcp-control-address  If set, PowerDNS can be controlled over TCP on this 
address
+#
+# tcp-control-address=
+
+#################################
+# tcp-control-port     If set, PowerDNS can be controlled over TCP on this 
address
+#
+# tcp-control-port=53000
+
+#################################
+# tcp-control-range    If set, remote control of PowerDNS is possible over 
these networks only
+#
+# tcp-control-range=127.0.0.0/8, 10.0.0.0/8, 192.168.0.0/16, 172.16.0.0/12, 
::1/128, fe80::/10
+
+#################################
+# tcp-control-secret   If set, PowerDNS can be controlled over TCP after 
passing this secret
+#
+# tcp-control-secret=
+
+#################################
+# trusted-notification-proxy   IP address of incoming notification proxy
+#
+# trusted-notification-proxy=
+
+#################################
# urlredirector Where we send hosts to that need to be url redirected
#
# urlredirector=127.0.0.1

#################################
-# use-logfile  Use a log file
+# use-logfile  Use a log file (Windows only)
#
# use-logfile=no

#################################
+# version-string       PowerDNS version in packets - full, anonymous, powerdns 
or custom
+#
+# version-string=full
+
+#################################
# webserver     Start a webserver for monitoring
#
# webserver=no
@@ -279,9 +404,4 @@ launch=bind
#
# wildcard-url=no

-#################################
-# wildcards    Honor wildcards in the database
-#
-# wildcards=
-

diff --git a/source/network-extra/pdns/pdns.service 
b/source/network-extra/pdns/pdns.service
new file mode 100644
index 0000000..1e57f7d
--- /dev/null
+++ b/source/network-extra/pdns/pdns.service
@@ -0,0 +1,21 @@
+[Unit]
+Description=PDNS DNS Server
+After=syslog.target network.target
+
+# Uncomment these lines if you are using gmysql backend locally.
+#After=mysqld.service
+#Requires=mysqld.service
+
+# Uncomment these lines if you are using gpgsql backend locally.
+#After=postgresql.service
+#Requires=postgresql.service
+
+[Service]
+Type=forking
+ExecStart=/usr/sbin/pdns_server --daemon=yes --guardian=yes
+ExecReload=/usr/bin/pdns_control cycle
+ExecStop=/usr/bin/pdns_control quit
+PIDFile=/var/run/pdns.pid
+
+[Install]
+WantedBy=multi-user.target
_______________________________________________
Frugalware-git mailing list
Frugalware-git@frugalware.org
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to