Python django lighttpd как настроить для субдоменов
От: sy-it  
Дата: 04.02.13 19:20
Оценка:
Добрый вечер, подскажите, как это дело донастроить — чтобы у нас был единый cgi конфиг, для субдоменов если это возможно, если нет — как упростить себе жизнь и вообще донастроить сервер?

Текущий конфиг:
server.modules              = (
            "mod_access",
            "mod_alias",
            "mod_accesslog",
            "mod_compress",
            "mod_fastcgi",
            "mod_rewrite",
            "mod_auth",
            "mod_evhost",
            "mod_status",
)

server.document-root       = "/var/www/"
server.upload-dirs = ( "/var/cache/lighttpd/uploads" )
server.errorlog            = "/var/log/lighttpd/error.log"
index-file.names           = ( "index.php", "index.html",
                               "index.htm", "default.htm",
                               "index.lighttpd.html" )

accesslog.filename         = "/var/log/lighttpd/access.log"
url.access-deny            = ( "~", ".inc", ".hg", ".git" )
static-file.exclude-extensions = ( ".php", ".pl", ".fcgi", ".py", ".pyc" )
server.event-handler = "linux-sysepoll"

server.pid-file            = "/var/run/lighttpd.pid"

dir-listing.encoding        = "utf-8"
server.dir-listing          = "enable"
server.username            = "www-data"

server.groupname           = "www-data"

#### compress module
compress.cache-dir          = "/var/cache/lighttpd/compress/"
compress.filetype           = ("text/plain", "text/html", "application/x-javascript", "text/css")
include_shell "/usr/share/lighttpd/create-mime.assign.pl"

include_shell "/usr/share/lighttpd/include-conf-enabled.pl"

$HTTP["remoteip"] =~ "127.0.0.1" {
        alias.url += (
                "/doc/" => "/usr/share/doc/",
               "/images/" => "/usr/share/images/"
        )
        $HTTP["url"] =~ "^/doc/|^/images/" {
                dir-listing.activate = "enable"
        }
}


$HTTP["host"] =~ "test.ru" {
        server.document-root = "/var/home/test.ru/public_html/"
        evhost.path-pattern  = "/var/home/service/%3/main/"
}
 
Подождите ...
Wait...
Пока на собственное сообщение не было ответов, его можно удалить.