projects
/
hvlinux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add option to enable/disable httpd, lighttpd, webkit and gnash packages
[hvlinux.git]
/
stage3
/
bootscripts
/
named
diff --git
a/stage3/bootscripts/named
b/stage3/bootscripts/named
index
80c9dc6
..
289215a
100755
(executable)
--- a/
stage3/bootscripts/named
+++ b/
stage3/bootscripts/named
@@
-8,6
+8,10
@@
source /etc/sysconfig/network/network-parameters
log_script_name "$0 $*"
log_script_name "$0 $*"
+DAEMON=/usr/sbin/named
+DAEMON_DESC="BIND server"
+DAEMON_OPTS="-u named -t /srv/named -c /etc/named.conf"
+
init_resolver()
{
echo "search ${DOMAINNAME}" > /etc/resolv.conf &&
init_resolver()
{
echo "search ${DOMAINNAME}" > /etc/resolv.conf &&
@@
-16,14
+20,14
@@
init_resolver()
case $1 in
start)
case $1 in
start)
- cmd_run_log_box_warn "
Starting named" loadproc /usr/sbin/named -u named -t /home/named -c /etc/named.conf
&&
+ cmd_run_log_box_warn "
${DAEMON_DESC} start" loadproc ${DAEMON} ${DAEMON_OPTS}
&&
init_resolver
;;
init_resolver
;;
-
+
stop)
stop)
- cmd_run_log_box_warn "
Stopping named" killproc named
+ cmd_run_log_box_warn "
${DAEMON_DESC} stop" killproc ${DAEMON}
;;
;;
-
+
restart)
$0 stop
sleep 1
restart)
$0 stop
sleep 1
@@
-31,13
+35,13
@@
case $1 in
;;
reload)
;;
reload)
- cmd_run_log_box "
Reloading name
d" /usr/sbin/rndc -c /etc/rndc.conf reload
+ cmd_run_log_box "
${DAEMON_DESC} reloa
d" /usr/sbin/rndc -c /etc/rndc.conf reload
;;
;;
-
+
status)
status)
- statusproc
named
+ statusproc
${DAEMON}
;;
;;
-
+
*)
echo "Usage: $0 {start|stop|restart|status}"
exit ${EXIT_CODE_FAILURE}
*)
echo "Usage: $0 {start|stop|restart|status}"
exit ${EXIT_CODE_FAILURE}