[arch-commits] Commit in bind/trunk (PKGBUILD install)

Gaetan Bisson bisson at archlinux.org
Sun Jan 23 08:36:28 EST 2011


    Date: Sunday, January 23, 2011 @ 08:36:28
  Author: bisson
Revision: 107320

- remove "chmod -R" from install script
- make most configuration file just readable for named

Modified:
  bind/trunk/PKGBUILD
  bind/trunk/install

----------+
 PKGBUILD |   24 ++++++++++++------------
 install  |   10 ----------
 2 files changed, 12 insertions(+), 22 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2011-01-23 11:59:04 UTC (rev 107319)
+++ PKGBUILD	2011-01-23 13:36:28 UTC (rev 107320)
@@ -5,7 +5,7 @@
 pkgname=bind
 pkgver=9.7.2.P3
 _pkgver=9.7.2-P3
-pkgrel=2
+pkgrel=3
 pkgdesc='Berkeley Internet Name Daemon (BIND) is the reference implementation of the Domain Name System (DNS) protocols'
 arch=('i686' 'x86_64')
 url='http://www.isc.org/software/bind/'
@@ -59,19 +59,19 @@
 
 	make DESTDIR="${pkgdir}" install
 
+	install -D -m644 COPYRIGHT "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+
+	install -d "${pkgdir}"/usr/share/doc/bind
+	install ./doc/arm/*.html "${pkgdir}"/usr/share/doc/bind/
+
 	install -D -m755 ../named "${pkgdir}"/etc/rc.d/named
-	install -D -m640 ../named.conf "${pkgdir}"/etc/named.conf
 	install -D -m644 ../named.conf.d "${pkgdir}"/etc/conf.d/named
 	install -D -m600 ../named.logrotate "${pkgdir}"/etc/logrotate.d/named
+	install -D -m640 -o  0 -g 40 ../named.conf "${pkgdir}"/etc/named.conf
 
-	install -D -m600 ../db.cache "${pkgdir}"/var/named/root.hint
-	install -D -m600 ../127.0.0.zone "${pkgdir}"/var/named/127.0.0.zone
-	install -D -m600 ../localhost.zone "${pkgdir}"/var/named/localhost.zone
-
-	install -d -m755 "${pkgdir}"/var/run/named
-	install -D -m644 COPYRIGHT "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
-
-	# documentation
-	install -d "${pkgdir}"/usr/share/doc/bind
-	install ./doc/arm/*.html "${pkgdir}"/usr/share/doc/bind/
+	install -d -m750 -o  0 -g 40 "${pkgdir}"/var/named
+	install -d -m755 -o 40 -g 40 "${pkgdir}"/var/run/named
+	install    -m640 -o  0 -g 40 ../db.cache "${pkgdir}"/var/named/root.hint
+	install    -m640 -o  0 -g 40 ../127.0.0.zone "${pkgdir}"/var/named/
+	install    -m640 -o  0 -g 40 ../localhost.zone "${pkgdir}"/var/named/
 }

Modified: install
===================================================================
--- install	2011-01-23 11:59:04 UTC (rev 107319)
+++ install	2011-01-23 13:36:28 UTC (rev 107320)
@@ -3,14 +3,8 @@
 	getent passwd named >/dev/null || useradd -u 40 -c "BIND DNS Server" -g named -d /var/named -s /bin/false named
 	passwd -l named &>/dev/null
 
-	chown -R named:named var/named
-	chmod 700 var/named
-
 	touch var/log/named.log
 	chown named:named var/log/named.log
-	chown named:named ${pkgdir}/var/run/named
-	chown root:named etc/named.conf
-	chmod 640 etc/named.conf
 
 	# create an rndc.key if it doesn't already exist
 	if [ ! -s etc/rndc.key ]; then
@@ -20,10 +14,6 @@
 	fi
 }
 
-post_upgrade() {
-	post_install
-}
-
 pre_remove() {
 	getent passwd named &>/dev/null && userdel named >/dev/null
 	getent group named &>/dev/null && groupdel named >/dev/null



More information about the arch-commits mailing list