Jun 26, 2014

How to setup media wiki one lighttpd.

Assume the lighttpd already installed.

Add the configuration below for settings.

#fastcgi.server = (".php" =>("localhost" =>("host"=>"127.0.0.1","port"=>"1026","bin-path"=>"/usr/bin/php-cgi")))
url.rewrite-once = (
         "^/wiki/upload/(.+)" => "/wiki/upload/$1",
#        "^/wiki/config/(.+)" => "/wiki/config/$1",
         "^/wiki/skins/(.+)" => "$0",
#        "^/$" => "/wiki/index.php",
         "^/wiki/([^?]*)(?:\?(.*))?" => "/wiki/index.php?title=$1&$2"
)
#url.rewrite-if-not-file = (
#   "^/wiki/(mw-)?config/?" => "$0",
#    "^/wiki/([^?]*)(?:\?(.*))?" => "/w/index.php?title=$1&$2",
#    "^/wiki/([^?]*)" => "/w/index.php?title=$1",
#    "^/wiki$" => "/w/index.php", # to avoid 404 when the user types /wiki instead of /wiki/
#)
#url.redirect = ( "^/(?!w|wiki|robots\.txt|favicon\.ico)(.*)" => "/wiki/$1" )
#$HTTP["remoteip"] !~ "192.168.101.156" {
#    $HTTP["url"] =~ "^/wiki" {
#      url.access-deny = ( "" )
#    }
# }

No comments: