]>
Commit | Line | Data |
---|---|---|
695964e9 | 1 | # lighttpd configuration file. |
40f84542 | 2 | |
97785bcf | 3 | include_shell "for f in conf.d/*.conf ; do [ -f \"$f\" ] && echo \"include \\"$f\\"\" ; done" |
7d62972e ER |
4 | |
5 | ## a static document-root, for virtual-hosting take look at the | |
40f84542 | 6 | ## server.virtual-* options |
7d62972e | 7 | server.document-root = "/home/services/lighttpd/html/" |
40f84542 AM |
8 | |
9 | ## where to send error-messages to | |
9c5fe8f8 | 10 | server.errorlog = "/var/log/lighttpd/error.log" |
d3ecfcb2 ER |
11 | #server.errorlog-use-syslog = "enable" |
12 | ||
54a99178 ER |
13 | ## http://redmine.lighttpd.net/projects/lighttpd/repository/revisions/2550 |
14 | ## NOTE: It is not reopened in log_error_cycle, so don't setup logrotate to this. | |
15 | server.breakagelog = "/var/log/lighttpd/breakage.log" | |
16 | ||
e2b4170d | 17 | server.pid-file = "/var/run/lighttpd.pid" |
40f84542 | 18 | |
695964e9 | 19 | # mimetype mapping |
695964e9 | 20 | include "mime.types.conf" |
0657595d ER |
21 | # default mime type |
22 | mimetype.assign += ( | |
23 | "" => "application/octet-stream", | |
24 | ) | |
40f84542 | 25 | |
b3b8d2ec ER |
26 | ## set the event-handler (read the performance section in the manual) |
27 | # Linux 2.4+ rt-signals linux-rtsig | |
28 | # Linux 2.6+ epoll linux-sysepoll | |
29 | #server.event-handler = "linux-sysepoll" | |
30 | ||
20f769ed ER |
31 | ## The basic network interface for all platforms at the syscalls read() |
32 | ## and write(). Every modern OS provides its own syscall to help network | |
33 | ## servers transfer files as fast as possible | |
34 | ## | |
35 | ## linux-sendfile - is recommended for small files. | |
36 | ## writev - is recommended for sending many large files | |
37 | ## | |
38 | #server.network-backend = "linux-sendfile" | |
39 | ||
92a79f62 ER |
40 | # default cames from ulimit -n |
41 | #server.max-fds = 8192 | |
42 | ||
20f769ed ER |
43 | ## |
44 | ## Stat() call caching. | |
45 | ## | |
46 | ## lighttpd can utilize FAM/Gamin to cache stat call. | |
47 | ## | |
48 | ## possible values are: | |
49 | ## disable, simple or fam. | |
50 | ## | |
51 | #server.stat-cache-engine = "simple" | |
52 | ||
53 | ## | |
54 | ## Fine tuning for the request handling | |
55 | ## | |
56 | ## max-connections == max-fds/2 (maybe /3) | |
57 | ## means the other file handles are used for fastcgi/files | |
58 | ## | |
59 | #server.max-connections = 1024 | |
60 | ||
92a79f62 ER |
61 | # maximum number of request within a keep-alive session before the server terminates the connection |
62 | # default 16 | |
63 | #server.max-keep-alive-requests = 16 | |
64 | ||
65 | # Maximum number of seconds until an idling keep-alive connection is dropped. | |
66 | # default 30 | |
67 | #server.max-keep-alive-idle = 30 | |
68 | ||
69 | # maximum number of seconds until a waiting, non keep-alive read times out and closes the connection | |
70 | # default 60 | |
71 | #server.max-read-idle = 60 | |
72 | ||
7fd78350 ER |
73 | # maximum number of seconds until a waiting write call times out and closes the connection |
74 | # default 360 | |
75 | #server.max-write-idle = 360 | |
76 | ||
20f769ed ER |
77 | ## |
78 | ## Maximum size of a request in kilobytes. | |
79 | ## By default it is unlimited (0). | |
80 | ## | |
81 | ## Uploads to your server can't be larger than this value. | |
82 | ## | |
83 | #server.max-request-size = 0 | |
84 | ||
dda0c1c2 | 85 | # Use the "Content-Type" extended attribute to obtain mime type if possible |
7d62972e | 86 | #mimetype.use-xattr = "enable" |
2f595477 | 87 | |
20f769ed ER |
88 | ## |
89 | ## Should lighttpd follow symlinks? | |
90 | ## | |
91 | #server.follow-symlink = "enable" | |
92 | ||
93 | ## | |
94 | ## force all filenames to be lowercase? | |
95 | ## | |
96 | #server.force-lowercase-filenames = "disable" | |
97 | ||
98 | ## | |
99 | ## defaults to /var/tmp as we assume it is a local harddisk | |
100 | ## | |
101 | server.upload-dirs = ( "/var/tmp" ) | |
102 | ||
103 | ## | |
104 | ## The value for the "Server:" response field. | |
105 | ## | |
106 | ## It would be nice to keep it at "lighttpd". | |
107 | ## | |
0a50e972 ER |
108 | #server.tag = "lighttpd" |
109 | ||
b3b8d2ec ER |
110 | $HTTP["url"] =~ "\.pdf$" { |
111 | server.range-requests = "disable" | |
112 | } | |
113 | ||
1cfa39cd ER |
114 | ## Skip responding with 417 for unhandled Expect header for some broken applications |
115 | #server.reject-expect-100-with-417 = "disable" | |
116 | ||
40f84542 AM |
117 | ######### Options that are good to be but not neccesary to be changed ####### |
118 | ||
119 | ## bind to port (default: 80) | |
695964e9 | 120 | server.port = 80 |
40f84542 | 121 | |
20f769ed ER |
122 | ## Use IPv6? |
123 | #server.use-ipv6 = "enable" | |
124 | ||
cb3c4066 ER |
125 | ## bind to specific host (default: all interfaces) |
126 | ## the name is resolved to ip at startup only. | |
a56072fe | 127 | #server.bind = "www.example.org" |
40f84542 | 128 | |
cb3c4066 ER |
129 | ## additionally just bind to localhost:80 |
130 | #$SERVER["socket"] == "127.0.0.1:80" {} | |
131 | ||
dda0c1c2 | 132 | ## error-handler for status 404 |
7d62972e ER |
133 | #server.error-handler-404 = "/error-handler.html" |
134 | #server.error-handler-404 = "/error-handler.php" | |
dda0c1c2 | 135 | |
7d62972e | 136 | ## |
ef2634ff | 137 | ## Format: <errorfile-prefix><status-code>.html |
40f84542 | 138 | ## -> ..../status-404.html for 'File not found' |
7d62972e | 139 | #server.errorfile-prefix = "/home/weigon/projects/lighttpd/doc/status-" |
695964e9 | 140 | # |
ae08eb54 | 141 | ## enable debugging |
e91e6bd0 | 142 | # http://redmine.lighttpd.net/projects/lighttpd/wiki/DebugVariables |
ae08eb54 | 143 | #debug.log-request-header = "enable" |
e91e6bd0 | 144 | #debug.log-request-header-on-error = "enable" |
ae08eb54 ER |
145 | #debug.log-response-header = "enable" |
146 | #debug.log-request-handling = "enable" | |
147 | #debug.log-file-not-found = "enable" | |
695964e9 | 148 | #debug.log-condition-handling = "enable" |
e91e6bd0 | 149 | #debug.log-condition-cache-handling = "enable" |
103de0f5 | 150 | #debug.log-timeouts = "enable" |
e91e6bd0 | 151 | #debug.log-ssl-noise = "enable" |
ae08eb54 | 152 | |
40f84542 AM |
153 | ### only root can use these options |
154 | # | |
155 | # chroot() to directory (default: no chroot() ) | |
156 | #server.chroot = "/" | |
157 | ||
158 | ## change uid to <uid> (default: don't care) | |
20f769ed | 159 | server.username = "lighttpd" |
40f84542 AM |
160 | |
161 | ## change uid to <uid> (default: don't care) | |
20f769ed | 162 | server.groupname = "lighttpd" |
40f84542 | 163 | |
20f769ed ER |
164 | ## |
165 | ## Traffic Shaping | |
166 | ## ----------------- | |
167 | ## | |
168 | ## Values are in kilobyte per second. | |
169 | ## | |
170 | ## Keep in mind that a limit below 32kB/s might actually limit the | |
171 | ## traffic to 32kB/s. This is caused by the size of the TCP send | |
172 | ## buffer. | |
173 | ## | |
174 | ## per server: | |
175 | ## | |
a1367ea7 SP |
176 | #server.kbytes-per-second = 128 |
177 | ||
20f769ed ER |
178 | ## |
179 | ## per connection: | |
180 | ## | |
181 | #connection.kbytes-per-second = 32 | |
182 | ||
695964e9 | 183 | # webapps configs |
97785bcf | 184 | include_shell "for f in webapps.d/*.conf ; do [ -f \"$f\" ] && echo \"include \\"$f\\"\" ; done" |
59e91e4a ER |
185 | |
186 | # vhosts config | |
97785bcf | 187 | include_shell "for f in vhosts.d/*.conf ; do [ -f \"$f\" ] && echo \"include \\"$f\\"\" ; done" |