diff options
Diffstat (limited to 'www/apache6/files/apache.sh')
-rw-r--r-- | www/apache6/files/apache.sh | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/www/apache6/files/apache.sh b/www/apache6/files/apache.sh index 5777b3a8bf4..b8311698952 100644 --- a/www/apache6/files/apache.sh +++ b/www/apache6/files/apache.sh @@ -1,6 +1,6 @@ #!/bin/sh # -# $NetBSD: apache.sh,v 1.13 2002/02/26 20:28:41 jlam Exp $ +# $NetBSD: apache.sh,v 1.13.2.1 2002/08/25 21:22:12 jlam Exp $ # # PROVIDE: apache # REQUIRE: DAEMON @@ -19,9 +19,11 @@ rcvar=$name command="@PREFIX@/sbin/httpd" ctl_command="@PREFIX@/sbin/apachectl" required_files="@PKG_SYSCONFDIR@/httpd.conf" +extra_commands="reload" start_cmd="apache_doit start" stop_cmd="apache_doit stop" restart_cmd="apache_doit restart" +reload_cmd="apache_doit reload" # "${apache_start}" is the subcommand sent to apachectl to control how # httpd is started. It's value may be overridden in: @@ -43,15 +45,16 @@ apache_doit () { case $1 in start) action=${apache_start} ;; + reload) action=graceful ;; *) action=$1 ;; esac ${ctl_command} ${action} } -if [ -f /etc/rc.subr ] +if [ -f /etc/rc.subr -a -f /etc/rc.conf -a -d /etc/rc.d -a -f /etc/rc.d/DAEMON ] then load_rc_config $name run_rc_command "$1" else - eval ${start_cmd} + apache_doit "$1" fi |