Re: [Boa-devel] Name-based VirtualHost
Brought to you by:
jnelson
From: <all...@li...> - 2003-02-03 05:41:14
|
On 2003-01-23 09:32:00, dmahurin wrote: > Change VirtualHost from a logical switch to one that takes a parameter of= =20 > "ip", "name" or possibly "both". With no parameter, it defaults to "ip", = to=20 > be compatible with the current behavior. "hostname" might be more descriptive than "name", and I suggest adding "interface" to the mix. It would probably be cleaner to accept multiple VirtualHost options or just allow an ordered list as the argument that then map appropiately to the directory structure (interface,hostname=20 would be ideal for me, while others may simply want hostname). Let's not lose the feature we have now, which allows us to serve different content based on the interface the request came in on (if either ip or interface is given). It might be worth thinking about hashing to keep a small number of entries in directories i.e. hash(hostname) (and may hash(ip)). We probably do not want the flxibility of mod_vhost_alias.html, a simple user defined function might do although regex would be groovy :-) > Also relative paths in Alias and ScriptAlias should be made relative to t= he=20 > effective document root. >=20 > With "ScriptAlias /cgi-bin abc/cgi-bin", > and "VirtualHost name", Good idea, but I am not sure that I like the relative paths. What about using the same mapping as specified in the VirtualHost option so: VirtualHost ip,hostname ScriptAlias /usr/local/lib/cgi-bin /cgi-bin would mean that we check in /usr/local/lib/cgi-bin/ip/hostname, then /usr/local/lib/cgi-bin/ip and finally /usr/local/lib/cgi-bin (again, retain the seperation between ip/interfaces). Not sure if this would cause performance issues though. I would love to work on this at some point, but I pressed for time, so if anyone is interested please feel free. /Allan --=20 Allan Wind P.O. Box 2022 Woburn, MA 01888-0022 USA |