1
|
config {
|
2
|
var.PID = 5705
|
3
|
var.CWD = ""
|
4
|
var.home_dir = "/web"
|
5
|
var.conf_dir = "/web/etc/lighttpd"
|
6
|
var.log_root = "/web/var/log"
|
7
|
var.server_root = "/web/var/www/web"
|
8
|
var.state_dir = "/web/var/run"
|
9
|
server.modules = (
|
10
|
"mod_rewrite",
|
11
|
"mod_redirect",
|
12
|
"mod_openssl",
|
13
|
"mod_proxy",
|
14
|
"mod_wstunnel",
|
15
|
"mod_fastcgi",
|
16
|
"mod_compress",
|
17
|
"mod_accesslog",
|
18
|
# 8
|
19
|
)
|
20
|
server.upload-dirs = ("/web/var/tmp")
|
21
|
server.document-root = "/web/var/www/web"
|
22
|
index-file.names = ("app.php", "index.php", "index.htm", "default.htm")
|
23
|
server.errorlog = "/web/var/log/lighttpd-error.log"
|
24
|
accesslog.filename = "/web/var/log/lighttpd-access.log"
|
25
|
server.max-read-idle = 3
|
26
|
wstunnel.debug = 65535
|
27
|
fastcgi.debug = 1
|
28
|
fastcgi.server = (
|
29
|
".php" => (
|
30
|
(
|
31
|
"bin-path" => "/web/bin/php-cgi",
|
32
|
"socket" => "/web/var/tmp/php.socket",
|
33
|
"max-procs" => 1,
|
34
|
"bin-environment" => (
|
35
|
"PHP_FCGI_CHILDREN" => "5",
|
36
|
"PHP_FCGI_MAX_REQUESTS" => "1000",
|
37
|
# 2
|
38
|
),
|
39
|
"broken-scriptfilename" => "enable",
|
40
|
# 5
|
41
|
),
|
42
|
),
|
43
|
)
|
44
|
server.port = 80
|
45
|
server.use-ipv6 = "disable"
|
46
|
server.username = "root"
|
47
|
server.groupname = "root"
|
48
|
server.tag = "lighttpd"
|
49
|
server.pid-file = "/web/var/run/lighttpd.pid"
|
50
|
server.event-handler = "linux-sysepoll"
|
51
|
server.max-fds = 2048
|
52
|
server.stat-cache-engine = "simple"
|
53
|
server.max-connections = 1024
|
54
|
server.max-keep-alive-idle = 5
|
55
|
static-file.exclude-extensions = (".php", ".pl", ".fcgi", ".scgi")
|
56
|
mimetype.assign = (
|
57
|
".png" => "image/png",
|
58
|
".jpg" => "image/jpeg",
|
59
|
".jpeg" => "image/jpeg",
|
60
|
".gif" => "image/gif",
|
61
|
".js" => "text/javascript",
|
62
|
# 5
|
63
|
".css" => "text/css",
|
64
|
".html" => "text/html",
|
65
|
".htm" => "text/html",
|
66
|
".pdf" => "application/pdf",
|
67
|
".swf" => "application/x-shockwave-flash",
|
68
|
# 10
|
69
|
".spl" => "application/futuresplash",
|
70
|
".txt" => "text/plain",
|
71
|
".tar.gz" => "application/x-tgz",
|
72
|
".tgz" => "application/x-tgz",
|
73
|
".gz" => "application/x-gzip",
|
74
|
# 15
|
75
|
".c" => "text/plain",
|
76
|
".conf" => "text/plain",
|
77
|
# 17
|
78
|
)
|
79
|
server.follow-symlink = "enable"
|
80
|
|
81
|
|
82
|
$HTTP["url"] =~ "^/websockify" {
|
83
|
# block 1
|
84
|
wstunnel.ping-interval = 20
|
85
|
wstunnel.frame-type = "binary"
|
86
|
wstunnel.server = (
|
87
|
"" => (
|
88
|
(
|
89
|
"host" => "127.0.0.1",
|
90
|
"port" => "5900",
|
91
|
# 2
|
92
|
),
|
93
|
),
|
94
|
)
|
95
|
|
96
|
} # end of $HTTP["url"] =~ "^/websockify"
|
97
|
}
|