A new user interface for you! Read more...

File start_apache2 of Package Apache2

#!/bin/sh
#
# Copyright (c) 1996, 1997, 1998 S.u.S.E. GmbH
# Copyright (c) 1998, 1999, 2000, 2001 SuSE GmbH
# Copyright (c) 2002, 2003, (2004?) SuSE Linux AG
# Copyright (c) 2004(?), 2005, 2006, 2007, 2008 SUSE Linux Products GmbH
#
# Authors: Rolf Haberrecker <apache@suse.de>, 2001
#          Peter Poeml <apache@suse.de>, 2002, 2003, 2004, 2005, 2006, 2007, 
#                                        2008, 2009, 2010
#
#
pname=apache2
. /usr/share/$pname/load_configuration

export ${!APACHE_*}

apache_link=/usr/sbin/httpd2
apache_bin=$(/usr/share/$pname/find_mpm 2>/dev/null)
httpd_conf=${APACHE_HTTPD_CONF:-/etc/apache2/httpd.conf}

test -L $apache_link && apache_bin=$(readlink $apache_link)

if [ -z "$APACHE_MPM" ]; then 
	APACHE_MPM=${apache_bin##*-}
fi

if ! [ -x $apache_bin ]; then
	echo >&2 $apache_bin-$APACHE_MPM is not a valid httpd2 binary. 
	echo >&2 Check your APACHE_MPM setting in /etc/sysconfig/$pname.
	exit 5
fi

# a proper home should be set, otherwise the server might end up 
# with HOME=/root and some script might try to use that
HOME=/var/lib/apache2

unset server_flags
case "$action" in startssl) server_flags="-DSSL";; esac
for i in $APACHE_SERVER_FLAGS; do
	case $i in 
	-D)	;;
	-D*)	server_flags="$server_flags $i";;
	*)	server_flags="$server_flags -D$i";;
	esac
done
${get_module_list_done:=false} || /usr/share/$pname/get_module_list && export get_module_list_done=true
${get_includes:=false} || /usr/share/$pname/get_includes && export get_includes_done=true

export -n ${!APACHE_*}
exec $apache_bin -f $httpd_conf $server_flags $@