]> git.pld-linux.org Git - packages/apache.git/blame - apache-httpd.conf
- pl for -mod_http2
[packages/apache.git] / apache-httpd.conf
CommitLineData
e157932f
ER
1# This is the main Apache HTTP server configuration file.
2# It contains the configuration directives that give the server its instructions.
9d781f9b 3#
e157932f
ER
4# This config aims to be clean and readable.
5# See <URL:http://httpd.apache.org/docs/2.2> for detailed information.
987d196f 6# In particular, see
e157932f
ER
7# <URL:http://httpd.apache.org/docs/2.2/mod/directives.html>
8# for a discussion of each configuration directive.
4af76ed4 9
58d2eaf1
AM
10ServerRoot "/etc/httpd"
11
8ae11478 12LoadModule unixd_module modules/mod_unixd.so
c7fbb6d9 13
4af76ed4 14
e157932f
ER
15# User/Group: The name (or #number) of the user/group to run httpd as.
16# It is usually good practice to create a dedicated user and group for
17# running httpd, as with most system services.
18User http
19Group http
99ce08d7 20
9d781f9b 21# Listen: Allows you to bind Apache to specific IP addresses and/or
e157932f 22# ports, instead of the default. See also the <VirtualHost>
9d781f9b
MM
23# directive.
24#
53fc5f22 25# Change this to Listen on specific IP addresses as shown below to
e157932f
ER
26# prevent Apache from glomming onto all bound IP addresses.
27#Listen 192.168.1.1:80
9d781f9b 28Listen 80
4af76ed4 29
4af76ed4 30# ServerAdmin: Your address, where problems with the server should be
8ae11478
ER
31# e-mailed. This address appears on some server-generated pages, such
32# as error documents. e.g. admin@example.com
4af76ed4 33#
65cd19d5 34ServerAdmin root@example.com
4af76ed4 35
9d781f9b
MM
36# ServerName gives the name and port that the server uses to identify itself.
37# This can often be determined automatically, but we recommend you specify
38# it explicitly to prevent problems during startup.
39#
4af76ed4 40# If your host doesn't have a registered DNS name, enter its IP address here.
4af76ed4 41#
53fc5f22 42ServerName localhost
4af76ed4 43
9d781f9b
MM
44# ErrorLog: The location of the error log file.
45# If you do not specify an ErrorLog directive within a <VirtualHost>
46# container, error messages relating to that virtual host will be
8ae11478 47# logged here. If you *do* define an error logfile for a <VirtualHost>
9d781f9b 48# container, that host's errors will be logged there and not here.
e157932f 49ErrorLog logs/error_log
e13a60ac 50ErrorLogFormat "%v [%t] [%l] [pid %P] [client %a] %M %m"
9d781f9b 51
9d781f9b
MM
52# LogLevel: Control the number of messages logged to the error_log.
53# Possible values include: debug, info, notice, warn, error, crit,
54# alert, emerg.
9d781f9b
MM
55LogLevel warn
56
061ad5b2 57Timeout 60
50707f42
ER
58KeepAlive On
59MaxKeepAliveRequests 100
60KeepAliveTimeout 5
b06b509a 61UseCanonicalName Off
50707f42 62AccessFileName .htaccess
0490814b 63ServerTokens Prod
50707f42
ER
64ServerSignature On
65HostnameLookups Off
2d070148 66#AddDefaultCharset UTF-8
50707f42 67
786e71ff
PG
68TraceEnable Off
69
1a1cb04d 70#
8ae11478
ER
71# EnableMMAP and EnableSendfile: On systems that support it, memory-mapping or
72# the sendfile syscall may be used to deliver files.
73# This usually improves server performance, but must be turned off when serving
74# from networked-mounted filesystems or if support for these functions is
75# otherwise broken on your system.
1a1cb04d
AM
76# Defaults if commented: EnableMMAP On, EnableSendfile Off
77#
78#EnableMMAP off
79EnableSendfile on
80
e157932f 81# Include other modules and packages config.
61ffca13 82IncludeOptional conf.d/*.conf
ac2899f4 83
e157932f 84# Include webapps config
61ffca13 85IncludeOptional webapps.d/*.conf
775a4f24 86
061ad5b2
AM
87#
88# Set a timeout for how long the client may take to send the request header
89# and body.
90# The default for the headers is header=20-40,MinRate=500, which means wait
91# for the first byte of headers for 20 seconds. If some data arrives,
92# increase the timeout corresponding to a data rate of 500 bytes/s, but not
93# above 40 seconds.
94# The default for the request body is body=20,MinRate=500, which is the same
95# but has no upper limit for the timeout.
96# To disable, set to header=0 body=0
97#
98<IfModule reqtimeout_module>
8ae11478 99 RequestReadTimeout header=20-40,MinRate=500 body=20,MinRate=500
061ad5b2
AM
100</IfModule>
101
775a4f24
ER
102<IfModule alias_module>
103 # ScriptAlias: This controls which directories contain server scripts.
104 # ScriptAliases are essentially the same as Aliases, except that
105 # documents in the target directory are treated as applications and
106 # run by the server when requested rather than as documents sent to the
8ae11478 107 # client. The same rules about trailing "/" apply to ScriptAlias
775a4f24
ER
108 # directives as to Alias.
109 #
110 ScriptAlias /cgi-bin/ "/home/services/httpd/cgi-bin/"
111
112 <Directory "/home/services/httpd/cgi-bin">
113 AllowOverride None
114 Options None
115 <IfModule mod_authz_host.c>
40ca719a 116 Require all granted
775a4f24 117 </IfModule>
e92e5081
JR
118 <IfModule mod_access_compat.c>
119 Order allow,deny
120 Allow from all
121 </IfModule>
775a4f24
ER
122 </Directory>
123</IfModule>
a6f9c2c2
ER
124
125# VirtualHost: Allows the daemon to respond to requests for more than one
126# server address, if your server machine is configured to accept IP packets
127# for multiple addresses. This can be accomplished with the ifconfig
128# alias flag, or through kernel patches like VIF.
129
130# Any apache.conf conf directive may go into a VirtualHost command.
131# See also the BindAddress entry.
132
860c70b0 133# Setup default vhost (first one defined in config) and include vhosts configuration
85805405 134<VirtualHost *:80>
8ae11478 135 ServerName localhost
860c70b0 136# ServerAdmin webmaster@host.example.com
784c115f 137# DocumentRoot /www/docs/host.example.com
860c70b0
ER
138# ErrorLog logs/host.example.com-error_log
139# TransferLog logs/host.example.com-access_log
140</VirtualHost>
141
61ffca13 142IncludeOptional vhosts.d/*.conf
This page took 0.078468 seconds and 4 git commands to generate.