b26a90a102
o Changes in httpd.conf - mod_userdir: . set Userdir if mod_userdir is loaded [1] . Userdir is denied for users from /etc/ftpusers - set more "secure" permissions. By default, policy is to deny access to filesystem. You HAVE to _ENABLE_ access to your filesystem in httpd.conf. - Add an "Includes" directory to ${PREFIX}/etc/apache2/ to make configuration more flexible ${PREFIX}/etc/apache2/*.conf files are now automatically loaded. o apache.sh - be closer to apachectl, apache.sh need envvars [2] It should restore subversion behavior. Partially submitted by: kuriyama [1], Gregory (Grisha) Trubetskoy <grisha at apache dot org> [2] Future changes are mostly written, they should be committed during the week-end. If you're interrested in changes, feel free contact me.
65 lines
1.8 KiB
Bash
65 lines
1.8 KiB
Bash
#!/bin/sh
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
# PROVIDE: apache2
|
|
# REQUIRE: NETWORKING SERVERS
|
|
# BEFORE: DAEMON
|
|
# KEYWORD: FreeBSD shutdown
|
|
|
|
#
|
|
# Add the following lines to /etc/rc.conf to enable apache2:
|
|
# apache2_enable (bool): Set to "NO" by default.
|
|
# Set it to "YES" to enable apache2
|
|
# apache2ssl_enable (bool): Set to "NO" by default.
|
|
# Set it to "YES" to start apache with SSL
|
|
# (if <IfDefined SSL> exists in httpd.conf)
|
|
# apache2limits_enable (bool):Set to "NO" by default.
|
|
# Set it to yes to run `limits $limits_args`
|
|
# just before apache starts.
|
|
# apache2_flags (str): Set to "" by default.
|
|
# Extra flags passed to start command
|
|
# apache2limits_args (str): Default to "-e -C daemon"
|
|
# Arguments of pre-start limits run.
|
|
#
|
|
. %%RC_SUBR%%
|
|
|
|
name="apache2"
|
|
rcvar=`set_rcvar`
|
|
|
|
start_precmd="apache2_precmd"
|
|
command="%%PREFIX%%/sbin/httpd"
|
|
pidfile="/var/run/httpd.pid"
|
|
required_files=%%PREFIX%%/etc/apache2/httpd.conf
|
|
|
|
[ -z "$apache2_enable" ] && apache2_enable="NO"
|
|
[ -z "$apache2ssl_enable" ] && apache2ssl_enable="NO"
|
|
[ -z "$apache2_flags" ] && apache2_flags=""
|
|
[ -z "$apache2limits_enable" ] && apache2limits_enable="NO"
|
|
[ -z "$apache2limits_args" ] && apache2limits_args="-e -C daemon"
|
|
|
|
load_rc_config $name
|
|
|
|
checkyesno apache2ssl_enable && \
|
|
apache2_flags="-DSSL $apache2_flags"
|
|
|
|
apache2_precmd()
|
|
{
|
|
if test -f %%PREFIX%%/sbin/envvars
|
|
then
|
|
. %%PREFIX%%/sbin/envvars
|
|
fi
|
|
if checkyesno apache2limits_enable
|
|
then
|
|
eval `/usr/bin/limits ${apache2limits_args}` 2>/dev/null
|
|
else
|
|
return 0
|
|
fi
|
|
|
|
}
|
|
|
|
sig_reload=SIGUSR1
|
|
|
|
extra_commands="reload"
|
|
run_rc_command "$1"
|