From 2590a0fbcef2e0748f87883e9ae58182bbcfe0f7 Mon Sep 17 00:00:00 2001 From: frank Date: Mon, 23 Apr 2012 19:22:09 +0200 Subject: [PATCH] saving uncommitted changes in /etc prior to emerge run --- .etckeeper | 5 +- apache2/modules.d/00_apache_manual.conf | 4 +- .../apache2/modules.d/00_apache_manual.conf | 4 +- .../apache2/modules.d/00_apache_manual.conf.1 | 4 +- .../modules.d/00_apache_manual.conf.dist | 4 +- config-archive/etc/init.d/nscd | 63 +++++++++++++++++++ .../etc/init.d/nscd.dist | 0 init.d/nscd | 21 ++++--- 8 files changed, 86 insertions(+), 19 deletions(-) rename apache2/modules.d/._cfg0000_00_apache_manual.conf => config-archive/etc/apache2/modules.d/00_apache_manual.conf.1 (88%) create mode 100755 config-archive/etc/init.d/nscd rename init.d/._cfg0000_nscd => config-archive/etc/init.d/nscd.dist (100%) diff --git a/.etckeeper b/.etckeeper index 0b17675..863f46e 100755 --- a/.etckeeper +++ b/.etckeeper @@ -56,7 +56,6 @@ maybe chmod 0755 './apache2' maybe chmod 0644 './apache2/httpd.conf' maybe chmod 0644 './apache2/magic' maybe chmod 0755 './apache2/modules.d' -maybe chmod 0644 './apache2/modules.d/._cfg0000_00_apache_manual.conf' maybe chmod 0644 './apache2/modules.d/.keep_dev-vcs_subversion-0' maybe chmod 0644 './apache2/modules.d/.keep_www-servers_apache-2' maybe chmod 0644 './apache2/modules.d/00_apache_manual.conf' @@ -208,6 +207,7 @@ maybe chmod 0644 './config-archive/etc/ImageMagick/type-ghostscript.xml.dist' maybe chmod 0755 './config-archive/etc/apache2' maybe chmod 0755 './config-archive/etc/apache2/modules.d' maybe chmod 0644 './config-archive/etc/apache2/modules.d/00_apache_manual.conf' +maybe chmod 0644 './config-archive/etc/apache2/modules.d/00_apache_manual.conf.1' maybe chmod 0644 './config-archive/etc/apache2/modules.d/00_apache_manual.conf.dist' maybe chmod 0755 './config-archive/etc/bash' maybe chmod 0644 './config-archive/etc/bash/bashrc' @@ -274,6 +274,8 @@ maybe chmod 0755 './config-archive/etc/init.d/net.lo.1' maybe chmod 0755 './config-archive/etc/init.d/net.lo.dist' maybe chmod 0755 './config-archive/etc/init.d/network' maybe chmod 0755 './config-archive/etc/init.d/network.dist' +maybe chmod 0755 './config-archive/etc/init.d/nscd' +maybe chmod 0755 './config-archive/etc/init.d/nscd.dist' maybe chmod 0755 './config-archive/etc/init.d/numlock' maybe chmod 0755 './config-archive/etc/init.d/numlock.dist' maybe chmod 0755 './config-archive/etc/init.d/postgresql-9.1' @@ -727,7 +729,6 @@ maybe chmod 0644 './idn.conf.sample' maybe chmod 0644 './idnalias.conf' maybe chmod 0644 './idnalias.conf.sample' maybe chmod 0755 './init.d' -maybe chmod 0755 './init.d/._cfg0000_nscd' maybe chmod 0755 './init.d/acpid' maybe chmod 0755 './init.d/amavisd' maybe chmod 0755 './init.d/apache2' diff --git a/apache2/modules.d/00_apache_manual.conf b/apache2/modules.d/00_apache_manual.conf index 25de5d1..c08b2a6 100644 --- a/apache2/modules.d/00_apache_manual.conf +++ b/apache2/modules.d/00_apache_manual.conf @@ -3,9 +3,9 @@ # The documentation is always available at # http://httpd.apache.org/docs/2.2/ -AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|pt-br))?(/.*)?$ "/usr/share/doc/apache-2.2.22/manual$1" +AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|pt-br))?(/.*)?$ "/usr/share/doc/apache-2.2.22-r1/manual$1" - + Options Indexes AllowOverride None Order allow,deny diff --git a/config-archive/etc/apache2/modules.d/00_apache_manual.conf b/config-archive/etc/apache2/modules.d/00_apache_manual.conf index a1bfed2..25de5d1 100644 --- a/config-archive/etc/apache2/modules.d/00_apache_manual.conf +++ b/config-archive/etc/apache2/modules.d/00_apache_manual.conf @@ -3,9 +3,9 @@ # The documentation is always available at # http://httpd.apache.org/docs/2.2/ -AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|pt-br))?(/.*)?$ "/usr/share/doc/apache-2.2.21-r1/manual$1" +AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|pt-br))?(/.*)?$ "/usr/share/doc/apache-2.2.22/manual$1" - + Options Indexes AllowOverride None Order allow,deny diff --git a/apache2/modules.d/._cfg0000_00_apache_manual.conf b/config-archive/etc/apache2/modules.d/00_apache_manual.conf.1 similarity index 88% rename from apache2/modules.d/._cfg0000_00_apache_manual.conf rename to config-archive/etc/apache2/modules.d/00_apache_manual.conf.1 index c08b2a6..a1bfed2 100644 --- a/apache2/modules.d/._cfg0000_00_apache_manual.conf +++ b/config-archive/etc/apache2/modules.d/00_apache_manual.conf.1 @@ -3,9 +3,9 @@ # The documentation is always available at # http://httpd.apache.org/docs/2.2/ -AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|pt-br))?(/.*)?$ "/usr/share/doc/apache-2.2.22-r1/manual$1" +AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|pt-br))?(/.*)?$ "/usr/share/doc/apache-2.2.21-r1/manual$1" - + Options Indexes AllowOverride None Order allow,deny diff --git a/config-archive/etc/apache2/modules.d/00_apache_manual.conf.dist b/config-archive/etc/apache2/modules.d/00_apache_manual.conf.dist index 25de5d1..c08b2a6 100644 --- a/config-archive/etc/apache2/modules.d/00_apache_manual.conf.dist +++ b/config-archive/etc/apache2/modules.d/00_apache_manual.conf.dist @@ -3,9 +3,9 @@ # The documentation is always available at # http://httpd.apache.org/docs/2.2/ -AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|pt-br))?(/.*)?$ "/usr/share/doc/apache-2.2.22/manual$1" +AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|pt-br))?(/.*)?$ "/usr/share/doc/apache-2.2.22-r1/manual$1" - + Options Indexes AllowOverride None Order allow,deny diff --git a/config-archive/etc/init.d/nscd b/config-archive/etc/init.d/nscd new file mode 100755 index 0000000..70fb3ea --- /dev/null +++ b/config-archive/etc/init.d/nscd @@ -0,0 +1,63 @@ +#!/sbin/runscript +# Copyright 1999-2005 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo/src/patchsets/glibc/extra/etc/nscd,v 1.3 2009/09/18 12:29:46 flameeyes Exp $ + +depend() { + use dns ldap net slapd +} + +checkconfig() { + if [ ! -d /var/run/nscd ] ; then + mkdir -p /var/run/nscd + chmod 755 /var/run/nscd + fi + if [ -z "${NSCD_PERMS_OK}" ] && [ "$(stat -c %a /var/run/nscd)" != "755" ] ; then + echo "" + ewarn "nscd run dir is not world readable, you should reset the perms:" + ewarn "chmod 755 /var/run/nscd" + ewarn "chmod a+rw /var/run/nscd/socket" + echo "" + ewarn "To disable this warning, set 'NSCD_PERMS_OK' in /etc/conf.d/nscd" + echo "" + fi +} + +start() { + checkconfig + + ebegin "Starting Name Service Cache Daemon" + local secure=`while read curline ; do + table=${curline%:*} + entries=${curline##$table:} + table=${table%%[^a-z]*} + case $table in + passwd*|group*|hosts) + for entry in $entries ; do + case $entry in + nisplus*) + /usr/sbin/nscd_nischeck $table || \ + /echo "-S $table,yes" + ;; + esac + done + ;; + esac + done < /etc/nsswitch.conf` + local pidfile=/var/run/nscd/nscd.pid + mkdir -p "$(dirname ${pidfile})" + start-stop-daemon --start --quiet \ + --exec /usr/sbin/nscd --pidfile ${pidfile} \ + -- $secure + eend $? +} + +stop() { + local pidfile=/var/run/nscd/nscd.pid + ebegin "Shutting down Name Service Cache Daemon" + start-stop-daemon --stop --quiet \ + --exec /usr/sbin/nscd --pidfile ${pidfile} + eend $? +} + +# vim:ts=4 diff --git a/init.d/._cfg0000_nscd b/config-archive/etc/init.d/nscd.dist similarity index 100% rename from init.d/._cfg0000_nscd rename to config-archive/etc/init.d/nscd.dist diff --git a/init.d/nscd b/init.d/nscd index 70fb3ea..e613715 100755 --- a/init.d/nscd +++ b/init.d/nscd @@ -1,7 +1,7 @@ #!/sbin/runscript # Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo/src/patchsets/glibc/extra/etc/nscd,v 1.3 2009/09/18 12:29:46 flameeyes Exp $ +# $Header: /var/cvsroot/gentoo/src/patchsets/glibc/extra/etc/nscd,v 1.5 2011/08/29 05:21:40 vapier Exp $ depend() { use dns ldap net slapd @@ -9,17 +9,17 @@ depend() { checkconfig() { if [ ! -d /var/run/nscd ] ; then - mkdir -p /var/run/nscd - chmod 755 /var/run/nscd + checkpath -d -m 755 /var/run/nscd fi if [ -z "${NSCD_PERMS_OK}" ] && [ "$(stat -c %a /var/run/nscd)" != "755" ] ; then - echo "" ewarn "nscd run dir is not world readable, you should reset the perms:" ewarn "chmod 755 /var/run/nscd" ewarn "chmod a+rw /var/run/nscd/socket" - echo "" ewarn "To disable this warning, set 'NSCD_PERMS_OK' in /etc/conf.d/nscd" - echo "" + fi + + if grep -qs '^[[:space:]]*persistent\>' /etc/nscd.conf ; then + checkpath -d -m 700 /var/db/nscd fi } @@ -27,6 +27,7 @@ start() { checkconfig ebegin "Starting Name Service Cache Daemon" + local secure=`while read curline ; do table=${curline%:*} entries=${curline##$table:} @@ -44,8 +45,10 @@ start() { ;; esac done < /etc/nsswitch.conf` - local pidfile=/var/run/nscd/nscd.pid - mkdir -p "$(dirname ${pidfile})" + + local pidfile="/var/run/nscd/nscd.pid" + mkdir -p "${pidfile%/*}" + start-stop-daemon --start --quiet \ --exec /usr/sbin/nscd --pidfile ${pidfile} \ -- $secure @@ -53,7 +56,7 @@ start() { } stop() { - local pidfile=/var/run/nscd/nscd.pid + local pidfile="/var/run/nscd/nscd.pid" ebegin "Shutting down Name Service Cache Daemon" start-stop-daemon --stop --quiet \ --exec /usr/sbin/nscd --pidfile ${pidfile} -- 2.39.5