lighttpd and allow all subdomains (all_what_i_will_write.domain.com)

Status
Not open for further replies.

jessepure

Active Member
132
2009
2
0
hi,

i would like to know how to set up lighttpd config for all subdomains... i would like to allow all ..for example sub1.domain.com and rrr.domain.com and also ft7sjrgvs.domain.com
icon_smile.gif
any recommendation? Very thank you.
 
6 comments
Setup vHost like this

Code:
$HTTP["host"] =~ "(^|\.)knownsrv\.com$" {
server.document-root = "/home/knownsrv/public_html"
server.errorlog = "/var/log/lighttpd/knownsrv/error.log"
accesslog.filename = "/var/log/lighttpd/knownsrv/access.log"
}
Every knownsrv.com subdomain that has A record to this server would point to /home/knownsrv/public_html unless you create a new vHost for a subdomain.
 
thanks for answer, but still doesn not working..

my configuration:

$HTTP["host"] =~ "(^|/.)mywebsite/.com$" {
server.document-root = "/home/mywebsite.com/public_html"
server.errorlog = "/var/log/lighttpd/error.log"
accesslog.filename = "/var/log/lighttpd/access.log"
magnet.attract-physical-path-to = ( server.document-root + "/rewrite.lua" )

what have i do? <_< thats the same like your solution.. X-(

Very thanks.
 
Status
Not open for further replies.
Back
Top