diff options
author | jlam <jlam> | 2000-09-12 14:50:51 +0000 |
---|---|---|
committer | jlam <jlam> | 2000-09-12 14:50:51 +0000 |
commit | e9286248cd289bc4062e9be9cfbf407c8d091903 (patch) | |
tree | 724343322d25eda875fcb4cd00364511ad4b0334 /www | |
parent | e8eb5b8c18bbdeb6c93ef2e8ae9176c3cdfc6858 (diff) | |
download | pkgsrc-e9286248cd289bc4062e9be9cfbf407c8d091903.tar.gz |
Provide mechanism to allow ap-ssl to force start of apache with "startssl".
Diffstat (limited to 'www')
-rw-r--r-- | www/apache/files/apache.sh | 35 |
1 files changed, 29 insertions, 6 deletions
diff --git a/www/apache/files/apache.sh b/www/apache/files/apache.sh index 3d85a5c5c46..61b1d4f9022 100644 --- a/www/apache/files/apache.sh +++ b/www/apache/files/apache.sh @@ -1,13 +1,36 @@ -#!/bin/sh +#! /bin/sh # -# $NetBSD: apache.sh,v 1.3 2000/07/10 12:22:27 hubertf Exp $ +# $NetBSD: apache.sh,v 1.4 2000/09/12 14:50:51 jlam Exp $ # +# PROVIDE: apache +# REQUIRE: DAEMON -CMD=${1:-start} +name="apache" +command="@PREFIX@/sbin/apachectl" +pidfile="/var/run/httpd.pid" +conffile="@PREFIX@/etc/httpd/httpd.conf" -if [ -x @PREFIX@/sbin/httpd -a -f @PREFIX@/etc/httpd/httpd.conf ] +apache_start="start" + +if [ -f @PREFIX@/etc/mod_ssl.conf ] then - @PREFIX@/sbin/apachectl $CMD >/dev/null - echo -n ' apache' + # This file can reset apache_start to "startssl" + . @PREFIX@/etc/httpd/mod_ssl.conf fi + +cmd=${1:-start} + +case ${cmd} in +start) + if [ -x ${command} -a -f ${conffile} ]; then + echo "Starting ${name}." + ${command} ${apache_start} + fi + ;; +*) + if [ -x ${command} ]; then + ${command} ${cmd} + fi + ;; +esac exit 0 |