aboutsummaryrefslogtreecommitdiffhomepage
path: root/data/sisu/v4/conf/lighttpd/lighttpd.cfg.sisu_www
blob: 0dd16c9479afe75db1f42fe8f67f6ea58e7c1b59 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
# lighttpd configuration file
#
# use a it as base for lighttpd 1.0.0 and above
#
#%%  Options you really have to take care of
#%
# modules to load
# at least mod_access and mod_accesslog should be loaded
# all other module should only be loaded if really neccesary
# - saves some time
# - saves memory
server.dir-listing = "disable"
server.modules = ( "mod_rewrite",
                   "mod_access",
                   "mod_fastcgi",
                   "mod_compress",
                   "mod_accesslog")
#%% a static document-root, for virtual-hosting take look at the
#% server.virtual-* options
server.document-root  = "/home/[user home]/sisu_www/"
#server.document-root        = "/home/*username*/web/public/"
## 'Parent' domain on any server except davie.
#server.document-root = "/home/*username*/public_html/"
##'Parent' domain for those of you currently on davie.textdrive.com, and all future servers.
#server.document-root = "/home/*username*/web/public/"
#% where to send error-messages to
server.errorlog       = "/home/[*username*]/var/lighttpd/log/lighttpd.error.log"
#% files to check for if .../ is requested
server.indexfiles  = ( "index.php", "index.html",
                       "index.htm", "index.rb")
##% mimetype mapping
##include "mime.types.conf"
##include_shell "/usr/local/bin/confmimetype /etc/mime.types"
#% mimetype mapping
mimetype.assign    = (
  ".pdf"           =>      "application/pdf",
  ".gz"            =>      "application/x-gzip",
  ".tar.gz"        =>      "application/x-tgz",
  ".tgz"           =>      "application/x-tgz",
  ".zip"           =>      "application/zip",
  ".gif"           =>      "image/gif",
  ".jpg"           =>      "image/jpeg",
  ".jpeg"          =>      "image/jpeg",
  ".png"           =>      "image/png",
  ".css"           =>      "text/css",
  ".html"          =>      "text/html",
  ".htm"           =>      "text/html",
  ".js"            =>      "text/javascript",
  ".text"          =>      "text/plain",
  ".txt"           =>      "text/plain",
  ".s1"            =>      "text/plain",
  ".s2"            =>      "text/plain",
  ".s3"            =>      "text/plain",
  ".dtd"           =>      "text/xml",
  ".xml"           =>      "text/xml",
  ".odt"           =>      "application/vnd.oasis.opendocument.text",
  ".bz2"           =>      "application/x-bzip",
  ".tbz"           =>      "application/x-bzip-compressed-tar",
  ".tar.bz2"       =>      "application/x-bzip-compressed-tar"
 )
# text/x-server-parsed-html
#%Server ID Header
server.tag         = "lighttpd | TextDriven"
#%### accesslog module
accesslog.filename = "/home/[*username*]/var/lighttpd/log/access_log"
#% deny access the file-extensions
#
# ~    is for backupfiles from vi, emacs, joe, ...
# .inc is often used for code includes which should in general not be part
#      of the document-root
url.access-deny    = ( "~", ".inc" )

#%% Options that are good to be but not neccesary to be changed
##% bind to port (default: 80)
server.port                = 8111
#server.port                = 8111
#server.port        =  8965
##% bind to localhost (default: all interfaces)
server.bind                = "localhost"
#server.bind                = "corundum"
##server.bind                = "grisu.home.kneschke.de"
##% to help the rc.scripts
server.pid-file    = "/home/[*username*]/var/lighttpd/run/lighttpd.pid"
#$HTTP["host"] =~ "\.corundum\.(name|com|net|org)" {
$HTTP["host"] == "localhost" {
  server.document-root = "/home/[*username*]/sisu_www/"
  server.errorlog = "/home/[*username*]/var/lighttpd/log/lighttpd-error.log"
  accesslog.filename = "/home/[*username*]/var/lighttpd/log/access_log"
  url.rewrite-repeat = (
    "^.*/$"                       => "index.html",
    "^(.*/(landscape|portrait))$" => "$1.pdf",
    "^(.*/(opendocument))$"       => "$1.odt",
    "^(.*/(sax|dom))$"            => "$1.xml",
    "^([^.]+)$"                   => "$1.html"
  )
  server.error-handler-404 = "/dispatch.fcgi"
#  fastcgi.server = ( ".fcgi" =>
#    ( "localhost" =>
#       (
#         "socket"   => "/home/[*username*]/var/lighttpd/cgi/lighttpd-fcgi.socket",
#         "bin-path" => "/home/[*username*]/var/lighttpd/public/dispatch.fcgi",
#         "min-procs" => 1,
#         "max-procs" => 2,
#         "idle-timeout" => 60
#       )
#    )
#  )
}
#% change uid to <uid> (default: don't care)
server.username            = "[*username*]"
#% change uid to <uid> (default: don't care)
server.groupname           = "[*username*]"
#%## compress module
compress.cache-dir         = "/home/[*username*]/var/lighttpd/cache/compress/"
compress.filetype          = ("text/plain", "text/html")