beautify code

This commit is contained in:
git-marijus 2013-06-14 20:17:15 +02:00
parent 2a9611467b
commit ed939ed21c

View file

@ -1,11 +1,12 @@
# See http://redmine.lighttpd.net/projects/lighttpd/wiki/Docs:ConfigurationOptions # See http://redmine.lighttpd.net/projects/lighttpd/wiki/Docs:ConfigurationOptions
### LOAD MODULES ### LOAD MODULES
server.modules = ( "mod_access", server.modules = (
"mod_accesslog", "mod_access",
"mod_fastcgi", "mod_accesslog",
"mod_redirect", "mod_fastcgi",
"mod_rewrite" "mod_redirect",
"mod_rewrite"
) )
### BASIC STUFF ### BASIC STUFF
@ -29,19 +30,21 @@ dir-listing.activate = "disable"
server.reject-expect-100-with-417 = "disable" server.reject-expect-100-with-417 = "disable"
### DEFINE SUPPORTED INDEX FILENAMES ### DEFINE SUPPORTED INDEX FILENAMES
index-file.names = ( "index.html", index-file.names = (
"index.htm", "index.html",
"index.php" "index.htm",
"index.php"
) )
### DEFINE SUPPORTED MIME TYPES ### DEFINE SUPPORTED MIME TYPES
mimetype.assign = ( ".html" => "text/html", mimetype.assign = (
".htm" => "text/html", ".html" => "text/html",
".css" => "text/css", ".htm" => "text/html",
".txt" => "text/plain", ".css" => "text/css",
".svg" => "image/svg+xml", ".txt" => "text/plain",
".jpg" => "image/jpeg", ".svg" => "image/svg+xml",
".png" => "image/png" ".jpg" => "image/jpeg",
".png" => "image/png"
) )
### DONT EVER SERVE FILES WITH EXTENSION ### DONT EVER SERVE FILES WITH EXTENSION
@ -49,34 +52,34 @@ static-file.exclude-extensions = ( ".php" )
### PHP WITH PHP-FPM ### PHP WITH PHP-FPM
### (needs php-fpm installed and running) ### (needs php-fpm installed and running)
fastcgi.server = ( fastcgi.server = (
".php" => ( ".php" => (
"localhost" => ( "localhost" => (
"socket" => "/run/php-fpm/php-fpm.sock", "socket" => "/run/php-fpm/php-fpm.sock",
"broken-scriptfilename" => "enable", "broken-scriptfilename" => "enable",
"allow-x-sendfile" => "enable" "allow-x-sendfile" => "enable"
) )
) )
) )
### ENABLE SSL ### ENABLE SSL
$SERVER["socket"] == ":443" { $SERVER["socket"] == ":443" {
ssl.engine = "enable" ssl.engine = "enable"
ssl.ca-file = "/etc/lighttpd/certs/ca-certs.crt" ssl.ca-file = "/etc/lighttpd/certs/ca-certs.crt" #adjust to your needs
ssl.pemfile = "/etc/lighttpd/certs/red-ssl.crt" ssl.pemfile = "/etc/lighttpd/certs/red-ssl.crt" #adjust to your needs
} }
### RISTRICT ACCESS TO DIRECTORYS AND FILES ### RISTRICT ACCESS TO DIRECTORYS AND FILES
$HTTP["url"] =~ "\.(out|log|htaccess)$" { $HTTP["url"] =~ "\.(out|log|htaccess)$" {
url.access-deny = ("") url.access-deny = ("")
} }
$HTTP["url"] =~ "(^|/)\.git" { $HTTP["url"] =~ "(^|/)\.git" {
url.access-deny = ("") url.access-deny = ("")
} }
### URL REWRITE RULES ### URL REWRITE RULES
url.rewrite-if-not-file = ( url.rewrite-if-not-file = (
"^\/([^\?]*)\?(.*)$" => "/index.php?q=$1&$2", "^\/([^\?]*)\?(.*)$" => "/index.php?q=$1&$2",
"^\/(.*)$" => "/index.php?q=$1" "^\/(.*)$" => "/index.php?q=$1"
) )