diff options
author | 2007-09-21 20:06:01 +0000 | |
---|---|---|
committer | 2007-09-21 20:06:01 +0000 | |
commit | 4c3720896a3d81f205fc1400c05f76bbfe26741c (patch) | |
tree | 6b6bebcd727ce0c38dd21774db11cd6f78aa324f | |
parent | fix #192025 (diff) | |
download | apache-4c3720896a3d81f205fc1400c05f76bbfe26741c.tar.gz apache-4c3720896a3d81f205fc1400c05f76bbfe26741c.tar.bz2 apache-4c3720896a3d81f205fc1400c05f76bbfe26741c.zip |
fix #193295, #193354, #192179
-rw-r--r-- | 2.2/conf/modules.d/00_mpm.conf | 2 | ||||
-rw-r--r-- | 2.2/conf/modules.d/45_mod_dav.conf | 5 | ||||
-rw-r--r-- | 2.2/conf/modules.d/46_mod_ldap.conf | 2 | ||||
-rw-r--r-- | 2.2/init/apache2.confd | 48 | ||||
-rwxr-xr-x | 2.2/init/apache2.initd | 20 |
5 files changed, 46 insertions, 31 deletions
diff --git a/2.2/conf/modules.d/00_mpm.conf b/2.2/conf/modules.d/00_mpm.conf index 49faa16..0183305 100644 --- a/2.2/conf/modules.d/00_mpm.conf +++ b/2.2/conf/modules.d/00_mpm.conf @@ -91,7 +91,7 @@ PidFile /var/run/apache2.pid # # MinSpareServers: Minimum number of idle child server processes # MaxSpareServers: Maximum number of idle child server processes -<IfModule mpm_prefork_module> +<IfModule mpm_itk_module> StartServers 5 MinSpareServers 5 MaxSpareServers 10 diff --git a/2.2/conf/modules.d/45_mod_dav.conf b/2.2/conf/modules.d/45_mod_dav.conf index 1191024..362ef52 100644 --- a/2.2/conf/modules.d/45_mod_dav.conf +++ b/2.2/conf/modules.d/45_mod_dav.conf @@ -15,10 +15,15 @@ Alias /uploads "/var/www/uploads" AuthType Digest AuthName DAV-upload + # You can use the htdigest program to create the password database: # htdigest -c "/var/www/.htpasswd-dav" DAV-upload admin AuthUserFile "/var/www/.htpasswd-dav" + # Allow access from any host + Order allow,deny + Allow from all + # Allow universal read-access, but writes are restricted # to the admin user. <LimitExcept GET OPTIONS> diff --git a/2.2/conf/modules.d/46_mod_ldap.conf b/2.2/conf/modules.d/46_mod_ldap.conf index f7fb302..837bc6e 100644 --- a/2.2/conf/modules.d/46_mod_ldap.conf +++ b/2.2/conf/modules.d/46_mod_ldap.conf @@ -19,7 +19,7 @@ LDAPOpCacheTTL 600 </IfModule> </IfDefine> -<IfDefine AUTH_LDAP> +<IfDefine AUTHNZ_LDAP> <IfModule authnz_ldap_module> #AuthLDAPURL ldap://ldap1.airius.com:389/ou=People, o=Airius?uid?sub?(objectClass=*) #require valid-user diff --git a/2.2/init/apache2.confd b/2.2/init/apache2.confd index a331643..dbe5a6e 100644 --- a/2.2/init/apache2.confd +++ b/2.2/init/apache2.confd @@ -2,30 +2,36 @@ # When you install a module it is easy to activate or deactivate the modules # and other features of apache using the APACHE2_OPTS line. Every module should -# install a configuration in /etc/apache2/modules.d. In that file will be an -# <IfDefine NNN> where NNN is the option to enable that module. +# install a configuration in /etc/apache2/modules.d. In that file will have an +# <IfDefine NNN> directive where NNN is the option to enable that module. +# # Here are the options available in the default configuration: # -# CACHE Enables mod_cache -# MEM_CACHE Enables default configuration mod_mem_cache -# DAV Enables mod_dav -# DEFAULT_VHOST Enables name-based virtual hosts, with the default -# virtual host being in /var/www/localhost/htdocs -# ERRORDOCS Enables default error documents for many languages. -# INFO Enables mod_info, a useful module for debugging -# LANGUAGE Enables content-negotiation based on language and charset. -# LDAP Enables mod_ldap (available if USE=ldap) -# AUTH_LDAP Enables authentication through mod_ldap (available if USE=ldap) -# MANUAL Enables /manual/ to be the apache manual (available if USE=docs) -# PROXY Enables mod_proxy -# SSL Enables SSL (available if USE=ssl) -# SSL_DEFAULT_VHOST Enables default vhost for SSL (you should enable this -# when you enable SSL unless you know what you are doing) -# SUEXEC Enables running CGI scripts (in USERDIR) through suexec. -# USERDIR Enables /~username mapping to /home/username/public_html +# AUTH_DIGEST Enables mod_auth_digest +# AUTHNZ_LDAP Enables authentication through mod_ldap (available if USE=ldap) +# CACHE Enables mod_cache +# DAV Enables mod_dav +# ERRORDOCS Enables default error documents for many languages. +# INFO Enables mod_info, a useful module for debugging +# LANGUAGE Enables content-negotiation based on language and charset. +# LDAP Enables mod_ldap (available if USE=ldap) +# MANUAL Enables /manual/ to be the apache manual (available if USE=docs) +# MEM_CACHE Enables default configuration mod_mem_cache +# PROXY Enables mod_proxy +# SSL Enables SSL (available if USE=ssl) +# SUEXEC Enables running CGI scripts (in USERDIR) through suexec. +# USERDIR Enables /~username mapping to /home/username/public_html +# +# +# The following two options provide the default virtual host for the HTTP and +# HTTPS protocol. YOU NEED TO ENABLE AT LEAST ONE OF THEM, otherwise apache +# will not listen for incomming connections on the approriate port. +# +# DEFAULT_VHOST Enables name-based virtual hosts, with the default +# virtual host being in /var/www/localhost/htdocs +# SSL_DEFAULT_VHOST Enables default vhost for SSL (you should enable this +# when you enable SSL) # -# Warning: You need one of DEFAULT_VHOST or SSL_DEFAULT_VHOST, otherwise apache -# will not listen for incomming connections on any port. APACHE2_OPTS="-D DEFAULT_VHOST -D LANGUAGE -D INFO" # Extended options for advanced uses of Apache ONLY diff --git a/2.2/init/apache2.initd b/2.2/init/apache2.initd index addbee4..aafb464 100755 --- a/2.2/init/apache2.initd +++ b/2.2/init/apache2.initd @@ -16,7 +16,7 @@ configtest() { eend $? } -checkconfig() { +checkconfd() { SERVERROOT="${SERVERROOT:-/usr/lib/apache2}" if [ ! -d ${SERVERROOT} ]; then eerror "SERVERROOT does not exist: ${SERVERROOT}" @@ -35,6 +35,10 @@ checkconfig() { [ -n "${STARTUPERRORLOG}" ] && APACHE2_OPTS="${APACHE2_OPTS} -E ${STARTUPERRORLOG}" APACHE2="/usr/sbin/apache2" +} + +checkconfig() { + checkconfd || return 1 ${APACHE2} ${APACHE2_OPTS} -t 1>/dev/null 2>&1 ret=$? @@ -51,13 +55,14 @@ start() { ebegin "Starting apache2" [ -f /var/log/apache2/ssl_scache ] && rm /var/log/apache2/ssl_scache - start-stop-daemon --start --exec ${APACHE2} -- ${APACHE2_OPTS} -k start + ${APACHE2} ${APACHE2_OPTS} -k start eend $? } stop() { + checkconfd || return 1 ebegin "Stopping apache2" - start-stop-daemon --stop --retry -TERM/5/-KILL/5 --exec ${APACHE2} --pidfile /var/run/apache2.pid + ${APACHE2} ${APACHE2_OPTS} -k stop eend $? } @@ -67,11 +72,11 @@ reload() { checkconfig || return 1 if [ "${RELOAD_TYPE}" = "restart" ]; then ebegin "Restarting apache2" - start-stop-daemon --stop --oknodo --signal HUP --exec ${APACHE2} --pidfile /var/run/apache2.pid + ${APACHE2} -k restart eend $? elif [ "${RELOAD_TYPE}" = "graceful" ]; then ebegin "Gracefully restarting apache2" - start-stop-daemon --stop --oknodo --signal USR1 --exec ${APACHE2} --pidfile /var/run/apache2.pid + ${APACHE2} -k graceful eend $? else eerror "${RELOAD_TYPE} is not a valid RELOAD_TYPE. Please edit /etc/conf.d/apache2" @@ -81,7 +86,7 @@ reload() { graceful() { checkconfig || return 1 ebegin "Gracefully restarting apache2" - start-stop-daemon --stop --signal USR1 --exec ${APACHE2} --pidfile /var/run/apache2.pid + ${APACHE2} -k graceful eend $? } @@ -94,8 +99,7 @@ gracefulstop() { fi ebegin "Gracefully stopping apache2" - # 28 is SIGWINCH - start-stop-daemon --stop --signal 28 --exec ${APACHE2} --pidfile /var/run/apache2.pid + ${APACHE2} -k gracefulstop eend $? } |