diff options
| author | Norikatsu Shigemura <nork@FreeBSD.org> | 2004-04-30 21:44:50 +0000 |
|---|---|---|
| committer | Norikatsu Shigemura <nork@FreeBSD.org> | 2004-04-30 21:44:50 +0000 |
| commit | 576de236ac1db51deadd2bae145b318268f556a2 (patch) | |
| tree | d8f99df1da194de1c24d9d05256c95b8ff391def /www/apache13/files/apache.sh | |
| parent | - Update to 1.7 (diff) | |
rcNG-fy.
Approved by: ache
Suggested by: hrs
Diffstat (limited to 'www/apache13/files/apache.sh')
| -rw-r--r-- | www/apache13/files/apache.sh | 41 |
1 files changed, 28 insertions, 13 deletions
diff --git a/www/apache13/files/apache.sh b/www/apache13/files/apache.sh index da657b5307ba..1b57c7853e5a 100644 --- a/www/apache13/files/apache.sh +++ b/www/apache13/files/apache.sh @@ -1,15 +1,30 @@ #!/bin/sh +# $FreeBSD$ -case "$1" in -start) - [ -x %%PREFIX%%/sbin/apachectl ] && %%PREFIX%%/sbin/apachectl start > /dev/null && echo -n ' apache' - ;; -stop) - [ -r /var/run/httpd.pid ] && %%PREFIX%%/sbin/apachectl stop > /dev/null && echo -n ' apache' - ;; -*) - echo "Usage: `basename $0` {start|stop}" >&2 - ;; -esac - -exit 0 +# PROVIDE: apache +# REQUIRE: DAEMON +# BEFORE: LOGIN +# KEYWORD: FreeBSD shutdown + +# Define these apache_* variables in one of these files: +# /etc/rc.conf +# /etc/rc.conf.local +# /etc/rc.conf.d/apache +# +# DO NOT CHANGE THESE DEFAULT VALUES HERE +# +apache_enable="NO" +apache_flags="" +apache_pidfile="/var/run/httpd.pid" + +. %%RC_SUBR%% + +name="apache" +rcvar=`set_rcvar` +command="%%PREFIX%%/sbin/httpd" + +load_rc_config $name + +pidfile="${apache_pidfile}" + +run_rc_commmand "$1" |
