]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Enable the geoip backend in the dynamic debian build
authorPieter Lexis <pieter.lexis@powerdns.com>
Tue, 12 May 2015 15:49:12 +0000 (17:49 +0200)
committerPieter Lexis <pieter.lexis@powerdns.com>
Wed, 10 Jun 2015 07:44:02 +0000 (09:44 +0200)
build-scripts/debian-authoritative/config/pdns.local.geoip.conf [new file with mode: 0644]
build-scripts/debian-authoritative/control
build-scripts/debian-authoritative/pdns-backend-geoip.examples [new file with mode: 0644]
build-scripts/debian-authoritative/pdns-backend-geoip.install [new file with mode: 0644]
build-scripts/debian-authoritative/pdns-backend-geoip.postinst [new file with mode: 0644]
build-scripts/debian-authoritative/pdns-backend-geoip.prerm [new file with mode: 0644]
build-scripts/debian-authoritative/rules

diff --git a/build-scripts/debian-authoritative/config/pdns.local.geoip.conf b/build-scripts/debian-authoritative/config/pdns.local.geoip.conf
new file mode 100644 (file)
index 0000000..48677ee
--- /dev/null
@@ -0,0 +1,8 @@
+# geoip Configuration
+#
+# See for more information https://doc.powerdns.com/md/authoritative/backend-geoip/
+#
+# geoip-database-file=
+# geoip-database-file6=
+# geoip-zones-file=
+# geoip-dnssec-keydir=
index ca80d95b663644965047a8e96e9929656e61c691..91b3eb7aa84199e547f6a4c126e6cf3ea9066634 100644 (file)
@@ -3,7 +3,7 @@ Section: net
 Priority: extra
 Standards-Version: 3.9.6
 Maintainer: PowerDNS AutoBuilder
-Build-Depends: debhelper (>= 9~), dh-autoreconf, dh-systemd, po-debconf, libtool, flex, bison, libmysqlclient-dev, libpq-dev, libssl-dev, libpolarssl-dev, libgdbm-dev, libldap2-dev, libsqlite3-dev, dpkg-dev (>= 1.17.0~), libboost-dev, libboost-serialization-dev, libboost-program-options-dev, libboost-test-dev, autotools-dev, automake, autoconf, liblua5.2-dev, pkg-config, libcrypto++-dev, ragel, libgmp-dev, libbotan1.10-dev, libcurl4-openssl-dev, libzmq-dev, liblmdb-dev
+Build-Depends: debhelper (>= 9~), dh-autoreconf, dh-systemd, po-debconf, libtool, flex, bison, libmysqlclient-dev, libpq-dev, libssl-dev, libpolarssl-dev, libgdbm-dev, libldap2-dev, libsqlite3-dev, dpkg-dev (>= 1.17.0~), libboost-dev, libboost-serialization-dev, libboost-program-options-dev, libboost-test-dev, autotools-dev, automake, autoconf, liblua5.2-dev, pkg-config, libcrypto++-dev, ragel, libgmp-dev, libbotan1.10-dev, libcurl4-openssl-dev, libzmq-dev, liblmdb-dev, libyaml-cpp-dev (>= 0.5), libgeoip-dev
 Homepage: http://www.powerdns.com/
 
 Package: pdns-server
@@ -99,6 +99,22 @@ Description: geo backend for PowerDNS
  balances the load throughout the world so that people access the
  geographically nearest available server.
 
+Package: pdns-backend-geoip
+Architecture: any
+Depends: pdns-server (>= ${source:Version}), ${shlibs:Depends}, ${misc:Depends}
+Recommends: geoip-database
+Provides: pdns-backend
+Description: geoip backend for PowerDNS
+ PowerDNS is a versatile nameserver which supports a large number
+ of different backends ranging from simple zonefiles to relational
+ databases and load balancing/failover algorithms.
+ PowerDNS tries to emphasize speed and security.
+ .
+ This package contains a geoipbackend for the PowerDNS nameserver. This backend
+ balances the load throughout the world so that people access the
+ geographically nearest available server based on the zonefile that is written
+ in yaml.
+
 Package: pdns-backend-mysql
 Architecture: any
 Depends: pdns-server (>= ${source:Version}), ucf (>= 0.28), ${shlibs:Depends}, ${misc:Depends}
diff --git a/build-scripts/debian-authoritative/pdns-backend-geoip.examples b/build-scripts/debian-authoritative/pdns-backend-geoip.examples
new file mode 100644 (file)
index 0000000..e3a59a4
--- /dev/null
@@ -0,0 +1 @@
+debian/config/pdns.local.geoip.conf
diff --git a/build-scripts/debian-authoritative/pdns-backend-geoip.install b/build-scripts/debian-authoritative/pdns-backend-geoip.install
new file mode 100644 (file)
index 0000000..d8ab64b
--- /dev/null
@@ -0,0 +1 @@
+usr/lib/*/pdns/libgeoipbackend.so*
diff --git a/build-scripts/debian-authoritative/pdns-backend-geoip.postinst b/build-scripts/debian-authoritative/pdns-backend-geoip.postinst
new file mode 100644 (file)
index 0000000..6511fad
--- /dev/null
@@ -0,0 +1,21 @@
+#!/bin/sh
+#
+# postinst script for pdns-backend-geo
+
+set -e
+
+if [ -n "$PDNSDEBUG" ]; then
+  echo "now debugging $0 $@"
+  set -x
+fi
+
+# Activate trigger
+dpkg-trigger pdns-server
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
+
diff --git a/build-scripts/debian-authoritative/pdns-backend-geoip.prerm b/build-scripts/debian-authoritative/pdns-backend-geoip.prerm
new file mode 100644 (file)
index 0000000..3298654
--- /dev/null
@@ -0,0 +1,14 @@
+#!/bin/sh
+#
+# Add call to init script to actually stop pdns.
+
+set -e
+
+if [ -x "/etc/init.d/pdns" ]; then
+       invoke-rc.d pdns stop || exit $?
+fi
+
+#DEBHELPER#
+
+exit 0
+
index 67e284940b58df414d5eb03e35f4f97c593853d0..97d3ad8cf4d909cbe5f3cd0ed80399d2eb225186 100755 (executable)
@@ -5,7 +5,7 @@ version := $(shell dpkg-parsechangelog -SVersion).$(shell dpkg-vendor --query Ve
 CXXFLAGS += -DPACKAGEVERSION='"$(version)"'
 
 # Backends
-backends := bind ldap pipe gmysql gpgsql gsqlite3 geo lua lmdb mydns remote
+backends := bind ldap pipe gmysql gpgsql gsqlite3 geo geoip lua lmdb mydns remote
 
 DEB_HOST_MULTIARCH  ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)