logo       

Re: virtual hosts specify fastcgi daemon?: msg#00021

web.lighttpd

Subject: Re: virtual hosts specify fastcgi daemon?

On Fri, Sep 10, 2004 at 05:09:06PM -0500, jeremy@xxxxxxxx wrote:
> Hi!
>
> I've been messing around with lighttpd the last couple of days and I
> love it so far!!
>
> The one thing I need to do for my environment that I'm just missing is
> that I can't figure out how to assign virtual hosts to use a
> particular fastcgi connection.
>
> I want to do this for the following reason:
>
> * domain blah.com cgi should be exec'd as the system user "blah"
> * domain blip.com cgi should be exec'd as the system user "blip"
>
> Is this currently possible? I need to use name based virtual hosts,
> and if I can get over this hurdle, I can start using lighttpd full
> time.
>
> I thought about writing up a patch to do this (not sure how I'll do it
> yet...) but figured before I spent the time coding I should make sure
> I wasn't reinventing the wheel.

Use

$HTTP["host"] == "blah.com" {
server.document-root = "/var/www/servers/blah.com/pages/"
fastcgi.server = ( ".php" =>
( "example" =>
( "host" => "localhost",
"port" => 1026
)
)
)
}
$HTTP["host"] == "blip.com" {
server.document-root = "/var/www/servers/blip.com/pages/"
fastcgi.server = ( ".php" =>
( "example" =>
( "host" => "localhost",
"port" => 1027
)
)
)
}

and create 2 spawn-php.sh script with different user-accounts.

> thanks,
> jeremy

Jan

--
Jan Kneschke http://jan.kneschke.de/
Perhaps you want to say 'thank you, jan': http://jk.123.org/wishlist/




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise