dnsmasq/dnsmasq-2.30-initscript.patch
2006-05-02 16:19:59 +00:00

63 lines
1.5 KiB
Diff

diff -urN dnsmasq-2.30/rpm/dnsmasq.rh dnsmasq-2.30-patched/rpm/dnsmasq.rh
--- dnsmasq-2.30/rpm/dnsmasq.rh 2006-04-23 08:26:21.000000000 -0500
+++ dnsmasq-2.30-patched/rpm/dnsmasq.rh 2006-05-02 11:07:16.000000000 -0500
@@ -2,7 +2,7 @@
#
# Startup script for the DNS caching server
#
-# chkconfig: 2345 99 01
+# chkconfig: - 99 01
# description: This script starts your DNS caching server
# processname: dnsmasq
# pidfile: /var/run/dnsmasq.pid
@@ -19,33 +19,9 @@
dnsmasq=/usr/sbin/dnsmasq
[ -f $dnsmasq ] || exit 0
-# change this line if you want dnsmasq to serve an MX record for
-# the host it is running on.
-MAILHOSTNAME=""
-# change this line if you want dns to get its upstream servers from
-# somewhere other that /etc/resolv.conf
-RESOLV_CONF=""
-# change this if you want dnsmasq to cache any "hostname" or "client-hostname" from
-# a dhcpd's lease file
-DHCP_LEASE="/var/lib/dhcp/dhcpd.leases"
DOMAIN_SUFFIX=`dnsdomainname`
-
-OPTIONS=""
-
-if [ ! -z "${MAILHOSTNAME}" ]; then
- OPTIONS="$OPTIONS -m $MAILHOSTNAME"
-fi
-
-if [ ! -z "${RESOLV_CONF}" ]; then
- OPTIONS="$OPTIONS -r $RESOLV_CONF"
-fi
-
-if [ ! -z "${DHCP_LEASE}" ]; then
- OPTIONS="$OPTIONS -l $DHCP_LEASE"
-fi
-
if [ ! -z "${DOMAIN_SUFFIX}" ]; then
- OPTIONS="$OPTIONS -s $DOMAIN_SUFFIX"
+ OPTIONS="-s $DOMAIN_SUFFIX"
fi
RETVAL=0
@@ -72,7 +48,13 @@
status dnsmasq
RETVAL=$?
;;
- restart|reload)
+ reload)
+ echo -n "Reloading dnsmasq: "
+ killproc dnsmasq -HUP
+ RETVAL=$?
+ echo
+ ;;
+ restart)
$0 stop
$0 start
RETVAL=$?