Mercurial > hg > rlgallery-misc
comparison lighttpd/rlgallery.conf @ 74:900da50ee11c
Merge lighttpd configuration into one include file.
The lighttpd configuration was previously spread across several files
which were intended to overwrite the defaults. They often became
outdated.
Now all customization is in lighttpd/rlgallery.conf, which should be
included at the end of whatever main lighttpd configuration file is in
use. It should require minimal updates for new lighttpd versions or
distribution changes.
author | John "Elwin" Edwards |
---|---|
date | Wed, 28 Dec 2016 13:12:04 -0500 |
parents | |
children | 716f8305d412 |
comparison
equal
deleted
inserted
replaced
73:ac8258c1b505 | 74:900da50ee11c |
---|---|
1 # lighttpd configuration file for rlgallery.org | |
2 # Include this file in your lighttpd.conf | |
3 | |
4 # Ensure index.cgi is in the list | |
5 index-file.names += ( | |
6 "index.xhtml", "index.html", "index.htm", "index.cgi" | |
7 ) | |
8 | |
9 server.modules += ( "mod_cgi", "mod_redirect", "mod_setenv" ) | |
10 | |
11 cgi.assign = ( ".cgi" => "" ) | |
12 | |
13 # The old static high score page now redirects to the CGI script | |
14 $HTTP["host"] =~ "^(.*)$" { | |
15 url.redirect = ( | |
16 "^/scoring/highscores.html" => "http://%1/scoring/high.cgi?l=40" | |
17 ) | |
18 } | |
19 | |
20 # Don't send CGI scripts or python scripts as static files | |
21 static-file.exclude-extensions += ( ".cgi", ".py" ) | |
22 | |
23 # Use the custom 404 error page | |
24 server.error-handler-404 = "404.html" | |
25 | |
26 # Set a UTF-8 environment, or Python 3 won't work | |
27 setenv.add-environment = ( | |
28 "LC_CTYPE" => "en_US.utf8" | |
29 ) | |
30 | |
31 # Turn on directory listing where it is needed | |
32 $HTTP["url"] =~ "^/files/" { | |
33 dir-listing.activate = "enable" | |
34 } | |
35 $HTTP["url"] =~ "^/ttyrecs/" { | |
36 dir-listing.activate = "enable" | |
37 } |