I've just started working with AOLserver (v3.4.2), and I'm trying to
tackle virtual hosting... so far without success.  And I must admit
to being a bit overwhelmed by the plethora of vhost modules,
especially since the documentation is often rather minimal.

If anyone can provide or add to a comparison of the various vhost
modules, or perhaps give a configuration example for their favorite
module I'd be very appreciative.

To start off, here are the modules I've tried and where I get stuck...

1. The C based vhost module (http://deadlock.ed.tudelft.nl/~daniel/vhost.html)

    The module builds with no warnings or errors.
    The server starts normally... I get the Notice: modload: that vhost.so
       loaded.
    My vhost directories are /web/servers/server1/pages/<FQDN>
    index.html has tried living in both .../<FQDN>/index.html and
       .../<FQDN>/pages/index.html

    In either case when I try to connect to the server it dies with a
    Seg Fault.

2. Vhost Abstract Template (vat) v0.3 (http://zmbh.com/vat/)

    With Debug on I see modload: initializing module 'vat', so I assume
       all is well to this point, yet connecting to web-test.example.com
       doesn't give me the web-test index page, it gives the
       www.example.com page from $pageroot

    Here's a chunk of my config.tcl:

ns_section "ns/servers/${servername}/module/vat"
ns_param PathVars        [list server version module name]
ns_param VhostRoot       {/web/servers/server1/vhost}
ns_param Precedence      [list tcl html adp htm]
ns_param pageroot        "/web/servers/server1/pages"

ns_section "ns/servers/${servername}/module/vat/servermap"
ns_param {www.example.com}    server1
ns_param {web-test.example.com}   server1a


ns_section "ns/servers/${servername}/module/vat/maps"
ns_param {*:server1}    {}
ns_param {*:server1a}    {/web/servers/server1/vhost/web-test/pages}


3. nssmartvh-2.0 ( )
    Building nssmartvh-2.0 gives a compiler warning from nssmartvh.c that
       'control reaches end of non-void function' in funct 'NsSmartVhCmd'.
       Not a big deal, just thougth I'd note it.

    The docs are a little non-existant about the syntax of the
       aolserver-vhosts file.  I think it should look like:

aolserver-vhosts:
<hostname> <vhost doc root>

of course without the "<" and ">" in the file.  So I have

www.local.example.com /web/servers/server1/vhost/web-main/pages
web-test.local.example.com /web/servers/server1/vhost/web-test/pages

    Now the funny thing is that nssmartvh says it's mapping

"local.example.com"->"/web/servers/server1/pages"  and
"web-test..."->"/web/servers/server1/pages"

    It's using the default $pageroot... even after I've commented out all
    the lines that include $pageroot in config.tcl .

    Hmmm.... I'm a bit baffled.

4. I guess the last vhost option is the nsunix/nsvhr combo, but I
haven't tried it yet.  It seems like a bit of a heavyweight solution
for my very modest needs.


Sorry for the long blurb.  If anyone prefers to reply to me directly,
I'll summarize to the list.

Thanks in advance,
-dean


--
Dean Baender                  ___                 Instructor, Science & Math
[EMAIL PROTECTED]              <*,->                St. Andrew's Academy
                              [`-']                http://standrews.place.cc/
                              -"-"-                [EMAIL PROTECTED]

Reply via email to