1 # lighttpd configuration file
3 # use a it as base for lighttpd 1.0.0 and above
7 ############ Options you really have to take care of ####################
10 # at least mod_access and mod_accesslog should be loaded
11 # all other module should only be loaded if really neccesary
30 ## a static document-root, for virtual-hosting take look at the
31 ## server.virtual-* options
32 server.document-root = "/home/services/lighttpd/html/"
34 ## where to send error-messages to
35 server.errorlog = "/var/log/lighttpd/lighttpd.log"
37 # files to check for if .../ is requested
38 server.indexfiles = ( "index.php", "index.html",
39 "index.htm", "default.htm" )
43 ".pdf" => "application/pdf",
44 ".sig" => "application/pgp-signature",
45 ".spl" => "application/futuresplash",
46 ".class" => "application/octet-stream",
47 ".ps" => "application/postscript",
48 ".torrent" => "application/x-bittorrent",
49 ".dvi" => "application/x-dvi",
50 ".gz" => "application/x-gzip",
51 ".pac" => "application/x-ns-proxy-autoconfig",
52 ".swf" => "application/x-shockwave-flash",
53 ".tar.gz" => "application/x-tgz",
54 ".tgz" => "application/x-tgz",
55 ".tar" => "application/x-tar",
56 ".zip" => "application/zip",
57 ".mp3" => "audio/mpeg",
58 ".m3u" => "audio/x-mpegurl",
59 ".wma" => "audio/x-ms-wma",
60 ".wax" => "audio/x-ms-wax",
61 ".ogg" => "audio/x-wav",
62 ".wav" => "audio/x-wav",
63 ".gif" => "image/gif",
64 ".jpg" => "image/jpeg",
65 ".jpeg" => "image/jpeg",
66 ".png" => "image/png",
67 ".xbm" => "image/x-xbitmap",
68 ".xpm" => "image/x-xpixmap",
69 ".xwd" => "image/x-xwindowdump",
71 ".html" => "text/html",
72 ".htm" => "text/html",
73 ".js" => "text/javascript",
74 ".asc" => "text/plain",
76 ".conf" => "text/plain",
77 ".text" => "text/plain",
78 ".txt" => "text/plain",
81 ".mpeg" => "video/mpeg",
82 ".mpg" => "video/mpeg",
83 ".mov" => "video/quicktime",
84 ".qt" => "video/quicktime",
85 ".avi" => "video/x-msvideo",
86 ".asf" => "video/x-ms-asf",
87 ".asx" => "video/x-ms-asf",
88 ".wmv" => "video/x-ms-wmv"
91 # Use the "Content-Type" extended attribute to obtain mime type if possible
92 # mimetype.use-xattr = "enable"
95 accesslog.filename = "/var/log/lighttpd/access.log"
97 ## deny access the file-extensions
99 # ~ is for backupfiles from vi, emacs, joe, ...
100 # .inc is often used for code includes which should in general not be part
101 # of the document-root
102 url.access-deny = ( "~", ".inc" )
106 ######### Options that are good to be but not neccesary to be changed #######
108 ## bind to port (default: 80)
111 ## bind to localhost (default: all interfaces)
112 #server.bind = "grisu.home.kneschke.de"
114 ## error-handler for status 404
115 #server.error-handler-404 = "/error-handler.html"
116 #server.error-handler-404 = "/error-handler.php"
118 ## to help the rc.scripts
119 # server.pid-file = "/var/run/lighttpd.pid"
123 ## If you want name-based virtual hosting add the next three settings and load
127 ## virtual-server-root + virtual-server-default-host + virtual-server-docroot or
128 ## virtual-server-root + http-host + virtual-server-docroot
130 #simple-vhost.server-root = "/home/weigon/wwwroot/servers/"
131 #simple-vhost.default-host = "grisu.home.kneschke.de"
132 #simple-vhost.document-root = "/pages/"
136 ## Format: <errorfile-prefix><status>.html
137 ## -> ..../status-404.html for 'File not found'
138 #server.errorfile-prefix = "/home/weigon/projects/lighttpd/doc/status-"
140 ## virtual directory listings
141 #server.dir-listing = "enable"
143 ## send unhandled HTTP-header headers to error-log
144 #debug.dump-unknown-headers = "enable"
146 ### only root can use these options
148 # chroot() to directory (default: no chroot() )
151 ## change uid to <uid> (default: don't care)
152 server.username = "lighttpd"
154 ## change uid to <uid> (default: don't care)
155 server.groupname = "lighttpd"
158 #compress.cache-dir = "/tmp/lighttpd/cache/compress/"
159 #compress.filetype = ("text/plain", "text/html")
162 ## read fastcgi.txt for more info
163 #fastcgi.server = ( ".php" =>
166 # "socket" => "/tmp/php-fastcgi.socket",
167 # "bin-path" => "/usr/local/bin/php"
173 #cgi.assign = ( ".pl" => "/usr/bin/perl",
174 # ".cgi" => "/usr/bin/perl" )
178 #ssl.engine = "enable"
179 #ssl.pemfile = "server.pem"
182 # status.status-url = "/server-status"
183 # status.config-url = "/server-config"
186 ## read authentification.txt for more info
187 # auth.backend = "plain"
188 # auth.backend.plain.userfile = "lighttpd.user"
189 # auth.backend.plain.groupfile = "lighttpd.group"
191 # auth.backend.ldap.hostname = "localhost"
192 # auth.backend.ldap.base-dn = "dc=my-domain,dc=com"
193 # auth.backend.ldap.filter = "(uid=$)"
195 # auth.require = ( "/server-status" =>
197 # "method" => "digest",
198 # "realm" => "download archiv",
199 # "require" => "group=www|user=jan|host=192.168.2.10"
203 # "method" => "digest",
204 # "realm" => "download archiv",
205 # "require" => "group=www|user=jan|host=192.168.2.10"
209 #### url handling modules (rewrite, redirect, access)
210 # url.rewrite = ( "^/$" => "/server-status" )
211 # url.redirect = ( "^/wishlist/(.+)" => "http://www.123.org/$1" )
213 # define a pattern for the host url finding
215 # %0 => domain name + tld
217 # %2 => domain name without tld
218 # %3 => subdomain 1 name
219 # %4 => subdomain 2 name
221 # evhost.path-pattern = "/home/storage/dev/www/%3/htdocs/"
224 # expire.url = ( "/buggy/" => "access 2 hours", "/asdhas/" => "access plus 1 seconds 2 minutes")
227 # ssi.extension = ( ".shtml" )
230 # rrdtool.binary = "/usr/bin/rrdtool"
231 # rrdtool.db-name = "/var/www/lighttpd.rrd"
234 # userdir.path = "public_html"
235 # userdir.exclude-user = ( "root", "postmaster" )
237 ## if set, only users from this list may use the feature
238 # userdir.include-user = ""
241 # alias.url = ( "/cgi-bin/" => "/var/www/servers/www.example.org/cgi-bin/" )