Using mod_vhost_alias and mod_userdir in separate VirtualServers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

I have been at this a while and can't figure it out.  I know the
documentation states that mod_userdir overrides mod_vhost, but it
seems like I should be able to use them both as long as they are in
separate virtual hosts, right?

I am trying to do mass virtual hosting by using dynamic virtual hosts,
but at the same time allow server users to access their own per-user
web directory.

This is what I have configured:
Single public IP 173.203.123.226
Primary Domain Name (cloud.andrewjroth.com)
Other Domain Names (www.domain.com, etc.)

-----httpd.conf-----
<VirtualHost *:80>
    DocumentRoot /var/www/html/
    ServerName cloud.andrewjroth.com
    <IfModule mod_userdir.c>
        UserDir html
    </IfModule>
</VirtualHost>
NameVirtualHost 173.203.123.226:80
<VirtualHost 173.203.123.226:80>
    ServerName DynamicHosts
    VirtualDocumentRoot /var/www/vhosts/%-2.0.%-1.0/%-3+/html
    VirtualScriptAlias /var/www/vhosts/%-2.0.%-1.0/%-3+/cgi-bin
</VirtualHost>
-----EOF-----

What I expect to happen is this:
Request for www.example.com directed to /var/www/html/
Request for www.example.com/~user directed to ~user/html/
Request for www.domain.com directed to /var/www/vhosts/domain.com/www/html/

What happens instead is:
Request for www.example.com is dircted to /var/www/vhosts/example.com/www/html/
Request for www.example.com/~user is directed to
/var/www/vhosts/example.com/www/html/~user

Any ideas would be appreciated.  Thanks for reading!

--

~Andrew Roth

"Our greatest glory is not in never falling, but in getting up every
time we do." -Confucius

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux