httpd.conf.in revision 64292bd95fd5d70d1d718843b4da455015a0139e
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder#
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# This is the main Apache HTTP server configuration file. It contains the
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# configuration directives that give the server its instructions.
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# See <URL:http://httpd.apache.org/docs/trunk/> for detailed information.
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# In particular, see
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# <URL:http://httpd.apache.org/docs/trunk/mod/directives.html>
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# for a discussion of each configuration directive.
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder#
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# Do NOT simply read the instructions in here without understanding
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# what they do. They're here only as hints or reminders. If you are unsure
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# consult the online docs. You have been warned.
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder#
99b26e2ab8ba89bc9a050c1524137eb6269e2753Christian Maeder# Configuration and logfile names: If the filenames you specify for many
18548c6cc2dff13bf9f5f08b3f6cde6ca914df1dChristian Maeder# of the server's control files begin with "/" (or "drive:/" for Win32), the
92ae4d5885ea837ffe3dae9b2de742f871229b94Christian Maeder# server will use that explicit path. If the filenames do *not* begin
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# with "/", the value of ServerRoot is prepended -- so "@rel_logfiledir@/foo_log"
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# with ServerRoot set to "@@ServerRoot@@" will be interpreted by the
ef1c24c8229ade3ac872febebd18c181e32fb9c4Christian Maeder# server as "@@ServerRoot@@/@rel_logfiledir@/foo_log".
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder#
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder# ServerRoot: The top of the directory tree under which the server's
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder# configuration, error, and log files are kept.
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder#
99b26e2ab8ba89bc9a050c1524137eb6269e2753Christian Maeder# Do not add a slash at the end of the directory path. If you point
736fe640b202e3fe7288fad8251d5b210c5d8d87Christian Maeder# ServerRoot at a non-local disk, be sure to specify a local disk on the
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder# Mutex directive, if file-based mutexes are used. If you wish to share the
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder# same ServerRoot for multiple httpd daemons, you will need to change at
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder# least PidFile.
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder#
e84c877ad38ce9312eab222a79f44da2015572d2Christian MaederServerRoot "@@ServerRoot@@"
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder#
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# Mutex: Allows you to set the mutex mechanism and mutex file directory
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder# for individual mutexes, or change the global defaults
ef1c24c8229ade3ac872febebd18c181e32fb9c4Christian Maeder#
ef1c24c8229ade3ac872febebd18c181e32fb9c4Christian Maeder# Uncomment and change the directory if mutexes are file-based and the default
945e82ed7877917f3ab1657f555e71991372546aChristian Maeder# mutex file directory is not on a local disk or is not appropriate for some
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder# other reason.
c208973c890b8f993297720fd0247bc7481d4304Christian Maeder#
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder# Mutex default:@rel_runtimedir@
ef1c24c8229ade3ac872febebd18c181e32fb9c4Christian Maeder
ef1c24c8229ade3ac872febebd18c181e32fb9c4Christian Maeder#
7c99a6c982aaf61547de8054296c8055c8d1a13aSimon Ulbricht# Listen: Allows you to bind Apache to specific IP addresses and/or
ef1c24c8229ade3ac872febebd18c181e32fb9c4Christian Maeder# ports, instead of the default. See also the <VirtualHost>
d97700a22b2585ece83b05f3fff945fdfd0c44b4Christian Maeder# directive.
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder#
ea5ccb1c6e89486a54e1f4bd95840147e96093edChristian Maeder# Change this to Listen on specific IP addresses as shown below to
de8eee2014437ec4020be15cd363257f87e79943Christian Maeder# prevent Apache from glomming onto all bound IP addresses.
ea5ccb1c6e89486a54e1f4bd95840147e96093edChristian Maeder#
fd94a6f66ccb5cef99aa42069b61e4b8734dbd3fChristian Maeder#Listen 12.34.56.78:80
fd94a6f66ccb5cef99aa42069b61e4b8734dbd3fChristian MaederListen @@Port@@
fd94a6f66ccb5cef99aa42069b61e4b8734dbd3fChristian Maeder
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder#
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder# Dynamic Shared Object (DSO) Support
473f5af6e4803fbeecc814065952396f2501039bChristian Maeder#
473f5af6e4803fbeecc814065952396f2501039bChristian Maeder# To be able to use the functionality of a module which was built as a DSO you
473f5af6e4803fbeecc814065952396f2501039bChristian Maeder# have to place corresponding `LoadModule' lines at this location so the
473f5af6e4803fbeecc814065952396f2501039bChristian Maeder# directives contained in it are actually available _before_ they are used.
473f5af6e4803fbeecc814065952396f2501039bChristian Maeder# Statically compiled modules (those listed by `httpd -l') do not need
473f5af6e4803fbeecc814065952396f2501039bChristian Maeder# to be loaded here.
6a88f8edd881afaf4b865b01bfbb4faaf0e7a3c9Simon Ulbricht#
473f5af6e4803fbeecc814065952396f2501039bChristian Maeder# Example:
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder# LoadModule foo_module modules/mod_foo.so
844c7d2ec3917393e139e53503757098d568713eSimon Ulbricht#
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder@@LoadModule@@
734a5ebd38032798f0ab908e2d52862c71b2c127Simon Ulbricht
ea5ccb1c6e89486a54e1f4bd95840147e96093edChristian Maeder<IfModule unixd_module>
c99b0eb6632087d502dd4269599c5aa68a148eebSimon Ulbricht#
c99b0eb6632087d502dd4269599c5aa68a148eebSimon Ulbricht# If you wish httpd to run as a different user or group, you must run
b99c9606f2faafeabb3fa8c596992143a561c787Simon Ulbricht# httpd as root initially and it will switch.
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht#
df67ddf64192bfcae6ece65255ad796a17cbe532Christian Maeder# User/Group: The name (or #number) of the user/group to run httpd as.
3e87e1dc85fa76cc6eaeb8eafbc0bea77af939f4Christian Maeder# It is usually good practice to create a dedicated user and group for
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder# running httpd, as with most system services.
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder#
526e7f36639cb58e3c99a54bea082499a6b04a25Christian MaederUser daemon
473f5af6e4803fbeecc814065952396f2501039bChristian MaederGroup daemon
f675b8f0a612e37472640da57b48d795bef4427eChristian Maeder
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder</IfModule>
526e7f36639cb58e3c99a54bea082499a6b04a25Christian Maeder
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder# 'Main' server configuration
18548c6cc2dff13bf9f5f08b3f6cde6ca914df1dChristian Maeder#
dae8246f1f55b6a85e946fc1bfb6d32d556395f1Simon Ulbricht# The directives in this section set up the values used by the 'main'
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder# server, which responds to any requests that aren't handled by a
18548c6cc2dff13bf9f5f08b3f6cde6ca914df1dChristian Maeder# <VirtualHost> definition. These values also provide defaults for
6a6689ad6d4c70af2ce3389f39a50982f20fd939Christian Maeder# any <VirtualHost> containers you may define later in the file.
f56cdf11927c31495bae642a9eb383212c90ba61Christian Maeder#
7710f7c3425e45af11af124ff37bec27229d24f7Christian Maeder# All of these directives may appear inside <VirtualHost> containers,
2e2559f894aaa661b199e4fa00609f522bc5482aSimon Ulbricht# in which case these default settings will be overridden for the
df67ddf64192bfcae6ece65255ad796a17cbe532Christian Maeder# virtual host being defined.
be1ce1c2b2819ef32743136c13101f1927375311Christian Maeder#
6a6689ad6d4c70af2ce3389f39a50982f20fd939Christian Maeder
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder#
5896f38ba2934056542cb7cb3e6359e88a622547Christian Maeder# ServerAdmin: Your address, where problems with the server should be
526e7f36639cb58e3c99a54bea082499a6b04a25Christian Maeder# e-mailed. This address appears on some server-generated pages, such
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder# as error documents. e.g. admin@your-domain.com
526e7f36639cb58e3c99a54bea082499a6b04a25Christian Maeder#
3e87e1dc85fa76cc6eaeb8eafbc0bea77af939f4Christian MaederServerAdmin you@example.com
275698320a734a6fd647ea6a461d6ce38862da1dChristian Maeder
6a6689ad6d4c70af2ce3389f39a50982f20fd939Christian Maeder#
6a6689ad6d4c70af2ce3389f39a50982f20fd939Christian Maeder# ServerName gives the name and port that the server uses to identify itself.
6a6689ad6d4c70af2ce3389f39a50982f20fd939Christian Maeder# This can often be determined automatically, but we recommend you specify
5896f38ba2934056542cb7cb3e6359e88a622547Christian Maeder# it explicitly to prevent problems during startup.
18548c6cc2dff13bf9f5f08b3f6cde6ca914df1dChristian Maeder#
6a6689ad6d4c70af2ce3389f39a50982f20fd939Christian Maeder# If your host doesn't have a registered DNS name, enter its IP address here.
5896f38ba2934056542cb7cb3e6359e88a622547Christian Maeder#
5896f38ba2934056542cb7cb3e6359e88a622547Christian Maeder#ServerName www.example.com:@@Port@@
5896f38ba2934056542cb7cb3e6359e88a622547Christian Maeder
5fb6343a5a2b4bbc67bc83479c84a92d23d30edfChristian Maeder#
18548c6cc2dff13bf9f5f08b3f6cde6ca914df1dChristian Maeder# Deny access to the entirety of your server's filesystem. You must
18548c6cc2dff13bf9f5f08b3f6cde6ca914df1dChristian Maeder# explicitly permit access to web content directories in other
5fb6343a5a2b4bbc67bc83479c84a92d23d30edfChristian Maeder# <Directory> blocks below.
18548c6cc2dff13bf9f5f08b3f6cde6ca914df1dChristian Maeder#
5fb6343a5a2b4bbc67bc83479c84a92d23d30edfChristian Maeder<Directory />
6a6689ad6d4c70af2ce3389f39a50982f20fd939Christian Maeder Require all denied
d27b1887e61f1dc53d77c37f59dbf5019242a686Christian Maeder</Directory>
31a81edf1285dc338211bfe86ba50a1f4128d9d2Christian Maeder
31a81edf1285dc338211bfe86ba50a1f4128d9d2Christian Maeder#
31a81edf1285dc338211bfe86ba50a1f4128d9d2Christian Maeder# Note that from this point forward you must specifically allow
9d50556254571c0811e94b4d948463754812a5aaChristian Maeder# particular features to be enabled - so if something's not working as
31a81edf1285dc338211bfe86ba50a1f4128d9d2Christian Maeder# you might expect, make sure that you have specifically enabled it
31a81edf1285dc338211bfe86ba50a1f4128d9d2Christian Maeder# below.
9d50556254571c0811e94b4d948463754812a5aaChristian Maeder#
18548c6cc2dff13bf9f5f08b3f6cde6ca914df1dChristian Maeder
5dd895cd3d794ecd2f0035ee3a7b6d6bf2eac5efChristian Maeder#
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder# DocumentRoot: The directory out of which you will serve your
ef1c24c8229ade3ac872febebd18c181e32fb9c4Christian Maeder# documents. By default, all requests are taken from this directory, but
be2b58b496a13ec3380fc6c0da28d8660c4f39f0Christian Maeder# symbolic links and aliases may be used to point to other locations.
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder#
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian MaederDocumentRoot "@exp_htdocsdir@"
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder<Directory "@exp_htdocsdir@">
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder #
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder # Possible values for the Options directive are "None", "All",
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder # or any combination of:
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder #
232c13ff6847a6f2bac7163392f80ab692cd7774Christian Maeder # Note that "MultiViews" must be named *explicitly* --- "Options All"
232c13ff6847a6f2bac7163392f80ab692cd7774Christian Maeder # doesn't give it to you.
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder #
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder # The Options directive is both complicated and important. Please see
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder # http://httpd.apache.org/docs/trunk/mod/core.html#options
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder # for more information.
2f0ca8050a33fbc1a23c0bd2dec0d09c17e3c548Christian Maeder #
f50c9f317ed743022255535248028675a5716d2aSimon Ulbricht Options Indexes FollowSymLinks
232c13ff6847a6f2bac7163392f80ab692cd7774Christian Maeder
232c13ff6847a6f2bac7163392f80ab692cd7774Christian Maeder #
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder # AllowOverride controls what directives may be placed in .htaccess files.
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder # It can be "All", "None", or any combination of the keywords:
eae0d62755147d991cc3e903f74f98ac31a7cd42Christian Maeder # Options FileInfo AuthConfig Limit
99b26e2ab8ba89bc9a050c1524137eb6269e2753Christian Maeder #
63ec46a77d00127c46ec526df43da8d701c30c65Christian Maeder AllowOverride None
99b26e2ab8ba89bc9a050c1524137eb6269e2753Christian Maeder
99b26e2ab8ba89bc9a050c1524137eb6269e2753Christian Maeder #
99b26e2ab8ba89bc9a050c1524137eb6269e2753Christian Maeder # Controls who can get stuff from this server.
99b26e2ab8ba89bc9a050c1524137eb6269e2753Christian Maeder #
99b26e2ab8ba89bc9a050c1524137eb6269e2753Christian Maeder Require all granted
ef1c24c8229ade3ac872febebd18c181e32fb9c4Christian Maeder</Directory>
cc9f19b1fe81424205736fe0ae73620395b1bb74Simon Ulbricht
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht#
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# DirectoryIndex: sets the file that Apache will serve if a directory
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# is requested.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht#
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht<IfModule dir_module>
38bb7e3212e979b25e0280ea6bf8c4df157d4ef4Simon Ulbricht DirectoryIndex index.html
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht</IfModule>
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht#
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht# The following lines prevent .htaccess and .htpasswd files from being
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht# viewed by Web clients.
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht#
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht<Files ".ht*">
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht Require all denied
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht</Files>
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht#
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht# ErrorLog: The location of the error log file.
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht# If you do not specify an ErrorLog directive within a <VirtualHost>
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht# container, error messages relating to that virtual host will be
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# logged here. If you *do* define an error logfile for a <VirtualHost>
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# container, that host's errors will be logged there and not here.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht#
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon UlbrichtErrorLog "@rel_logfiledir@/error_log"
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht#
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# LogLevel: Control the number of messages logged to the error_log.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# Possible values include: debug, info, notice, warn, error, crit,
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# alert, emerg.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht#
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon UlbrichtLogLevel warn
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht<IfModule log_config_module>
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # The following directives define some format nicknames for use with
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # a CustomLog directive (see below).
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht LogFormat "%h %l %u %t \"%r\" %>s %b" common
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht <IfModule logio_module>
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht # You need to enable mod_logio.c to use %I and %O
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht </IfModule>
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # The location and format of the access logfile (Common Logfile Format).
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # If you do not define any access logfiles within a <VirtualHost>
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # container, they will be logged here. Contrariwise, if you *do*
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # define per-<VirtualHost> access logfiles, transactions will be
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # logged therein and *not* in this file.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht CustomLog "@rel_logfiledir@/access_log" common
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # If you prefer a logfile with access, agent, and referer information
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # (Combined Logfile Format) you can use the following directive.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
0a46a4d711eca869ad75b4df84dabd72783ebdd2Simon Ulbricht #CustomLog "@rel_logfiledir@/access_log" combined
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht</IfModule>
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht<IfModule alias_module>
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht #
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht # Redirect: Allows you to tell clients about documents that used to
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht # exist in your server's namespace, but do not anymore. The client
0a46a4d711eca869ad75b4df84dabd72783ebdd2Simon Ulbricht # will make a new request for the document at its new location.
0a46a4d711eca869ad75b4df84dabd72783ebdd2Simon Ulbricht # Example:
0a46a4d711eca869ad75b4df84dabd72783ebdd2Simon Ulbricht # Redirect permanent /foo http://www.example.com/bar
465c6b72e8e480969b5f08658e394992bcc08bfcSimon Ulbricht
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht #
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht # Alias: Maps web paths into filesystem paths and is used to
0a46a4d711eca869ad75b4df84dabd72783ebdd2Simon Ulbricht # access content that does not live under the DocumentRoot.
0a46a4d711eca869ad75b4df84dabd72783ebdd2Simon Ulbricht # Example:
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht # Alias /webpath /full/filesystem/path
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # If you include a trailing / on /webpath then the server will
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # require it to be present in the URL. You will also likely
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # need to provide a <Directory> section to allow access to
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # the filesystem path.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # ScriptAlias: This controls which directories contain server scripts.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # ScriptAliases are essentially the same as Aliases, except that
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # documents in the target directory are treated as applications and
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # run by the server when requested rather than as documents sent to the
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # client. The same rules about trailing "/" apply to ScriptAlias
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # directives as to Alias.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht ScriptAlias /cgi-bin/ "@exp_cgidir@/"
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht</IfModule>
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht<IfModule cgid_module>
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht # ScriptSock: On threaded servers, designate the path to the UNIX
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht # socket used to communicate with the CGI daemon of mod_cgid.
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #Scriptsock @rel_runtimedir@/cgisock
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht</IfModule>
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht#
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# "@exp_cgidir@" should be changed to whatever your ScriptAliased
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# CGI directory exists, if you have that configured.
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht#
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht<Directory "@exp_cgidir@">
562e30787355109feb0133ffea2ad86b6c143c26Simon Ulbricht AllowOverride None
562e30787355109feb0133ffea2ad86b6c143c26Simon Ulbricht Options None
562e30787355109feb0133ffea2ad86b6c143c26Simon Ulbricht Require all granted
562e30787355109feb0133ffea2ad86b6c143c26Simon Ulbricht</Directory>
562e30787355109feb0133ffea2ad86b6c143c26Simon Ulbricht
562e30787355109feb0133ffea2ad86b6c143c26Simon Ulbricht<IfModule mime_module>
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht # TypesConfig points to the file containing the list of mappings from
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # filename extension to MIME-type.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht TypesConfig @rel_sysconfdir@/mime.types
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht # AddType allows you to add to or override the MIME configuration
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # file specified in TypesConfig for specific file types.
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht #AddType application/x-gzip .tgz
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht #
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht # AddEncoding allows you to have certain browsers uncompress
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht # information on the fly. Note: Not all browsers support this.
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht #
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht #AddEncoding x-compress .Z
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht #AddEncoding x-gzip .gz .tgz
7463a1bf64cfa90917e2afb6a5017ec411d2b3dbSimon Ulbricht #
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht # If the AddEncoding directives above are commented-out, then you
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht # probably should define those extensions to indicate media types:
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht #
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht AddType application/x-compress .Z
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht AddType application/x-gzip .gz .tgz
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht # AddHandler allows you to map certain file extensions to "handlers":
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht # actions unrelated to filetype. These can be either built into the server
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht # or added with the Action directive (see below)
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht # To use CGI scripts outside of ScriptAliased directories:
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht # (You will also need to add "ExecCGI" to the "Options" directive.)
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #AddHandler cgi-script .cgi
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht # For type maps (negotiated resources):
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht #AddHandler type-map var
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht #
41a3368af0eaad78c660477e7ded53b2ba85a275Christian Maeder # Filters allow you to process content before it is sent to the client.
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht #
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht # To parse .shtml files for server-side includes (SSI):
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht # (You will also need to add "Includes" to the "Options" directive.)
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht #
2e2559f894aaa661b199e4fa00609f522bc5482aSimon Ulbricht #AddType text/html .shtml
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht #AddOutputFilter INCLUDES .shtml
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht</IfModule>
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht#
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht# The mod_mime_magic module allows the server to use various hints from the
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# contents of the file itself to determine its type. The MIMEMagicFile
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht# directive tells the module where the hint definitions are located.
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht#
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht#MIMEMagicFile @rel_sysconfdir@/magic
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht#
2e76bbbed1c936bb0aee1753837e1c50416847a2Simon Ulbricht# Customizable error responses come in three flavors:
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# 1) plain text 2) local redirects 3) external redirects
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht#
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# Some examples:
2e2559f894aaa661b199e4fa00609f522bc5482aSimon Ulbricht#ErrorDocument 500 "The server made a boo boo."
2e2559f894aaa661b199e4fa00609f522bc5482aSimon Ulbricht#ErrorDocument 404 /missing.html
05c714be15ce094d83f1b989cdf5236be78419bfSimon Ulbricht#ErrorDocument 404 "/cgi-bin/missing_handler.pl"
05c714be15ce094d83f1b989cdf5236be78419bfSimon Ulbricht#ErrorDocument 402 http://www.example.com/subscription_info.html
05c714be15ce094d83f1b989cdf5236be78419bfSimon Ulbricht#
05c714be15ce094d83f1b989cdf5236be78419bfSimon Ulbricht
05c714be15ce094d83f1b989cdf5236be78419bfSimon Ulbricht#
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# MaxRanges: Maximum number of Ranges in a request before
05c714be15ce094d83f1b989cdf5236be78419bfSimon Ulbricht# returning the entire resource, or one of the special
05c714be15ce094d83f1b989cdf5236be78419bfSimon Ulbricht# values 'default', 'none' or 'unlimited'.
05c714be15ce094d83f1b989cdf5236be78419bfSimon Ulbricht# Default setting is to accept 200 Ranges.
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht#MaxRanges unlimited
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht#
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht# EnableMMAP and EnableSendfile: On systems that support it,
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht# memory-mapping or the sendfile syscall may be used to deliver
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht# files. This usually improves server performance, but must
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht# be turned off when serving from networked-mounted
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht# filesystems or if support for these functions is otherwise
eed69480d024d858069901fefb82518a9119472fSimon Ulbricht# broken on your system.
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht# Defaults: EnableMMAP On, EnableSendfile Off
0b144823976d79a34bff62f7f9ec032e80b8ce85Simon Ulbricht#
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht#EnableMMAP off
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht#EnableSendfile on
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
86c1b41a968fde92972d40753dbbd13e0b25d85bChristian Maeder# Supplemental configuration
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht#
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# The configuration files in the @rel_sysconfdir@/extra/ directory can be
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# included to add extra features or to modify the default configuration of
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht# the server, or you may simply copy their contents here and change as
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# necessary.
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# Server-pool management (MPM specific)
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht#Include @rel_sysconfdir@/extra/httpd-mpm.conf
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
de8eee2014437ec4020be15cd363257f87e79943Christian Maeder# Multi-language error messages
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht#Include @rel_sysconfdir@/extra/httpd-multilang-errordoc.conf
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# Fancy directory listings
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht#Include @rel_sysconfdir@/extra/httpd-autoindex.conf
f6a562e28240e4f9107c199ba7a8e500ccfbfa55Simon Ulbricht
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht# Language settings
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht#Include @rel_sysconfdir@/extra/httpd-languages.conf
9a5e6e537c43a631facd9d87ce1a6c76f4b0af6dSimon Ulbricht
05c714be15ce094d83f1b989cdf5236be78419bfSimon Ulbricht# User home directories
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht#Include @rel_sysconfdir@/extra/httpd-userdir.conf
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# Real-time info on requests and configuration
526e7f36639cb58e3c99a54bea082499a6b04a25Christian Maeder#Include @rel_sysconfdir@/extra/httpd-info.conf
526e7f36639cb58e3c99a54bea082499a6b04a25Christian Maeder
1ab66a7e4234c760be9689b05ab4c34ce99dba23Simon Ulbricht# Virtual hosts
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder#Include @rel_sysconfdir@/extra/httpd-vhosts.conf
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder# Local access to the Apache HTTP Server Manual
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder#Include @rel_sysconfdir@/extra/httpd-manual.conf
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder# Distributed authoring and versioning (WebDAV)
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder#Include @rel_sysconfdir@/extra/httpd-dav.conf
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder# Various default settings
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder#Include @rel_sysconfdir@/extra/httpd-default.conf
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder# If mod_proxy_html is required
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder#Include @rel_sysconfdir@/extra/proxy-html.conf
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder# Secure (SSL/TLS) connections
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder#Include @rel_sysconfdir@/extra/httpd-ssl.conf
0bbc28585c7d42913167ff78a862ef25ea59e85eChristian Maeder#
4ed68712ee368cbebfeaa327968583cb022e3c72Christian Maeder# Note: The following must must be present to support
4ed68712ee368cbebfeaa327968583cb022e3c72Christian Maeder# starting without SSL on platforms with no /dev/random equivalent
4ed68712ee368cbebfeaa327968583cb022e3c72Christian Maeder# but a statically compiled-in mod_ssl.
4ed68712ee368cbebfeaa327968583cb022e3c72Christian Maeder#
4ed68712ee368cbebfeaa327968583cb022e3c72Christian Maeder<IfModule ssl_module>
4ed68712ee368cbebfeaa327968583cb022e3c72Christian MaederSSLRandomSeed startup builtin
4ed68712ee368cbebfeaa327968583cb022e3c72Christian MaederSSLRandomSeed connect builtin
993e01fc242fa58d3dcf1b3272cd411726817eeeSimon Ulbricht</IfModule>
4ed68712ee368cbebfeaa327968583cb022e3c72Christian Maeder