GIDForums  

Go Back   GIDForums > Web Hosting Forums > Apache Web Server Forum
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 01-Nov-2009, 11:08
seaders seaders is offline
New Member
 
Join Date: Jun 2008
Posts: 8
seaders is on a distinguished road

Mixing sub-domain wildcard serving with userdir mod


Ok, to cut a long story short, I'm one of the admins on my old college computing society, which we've recently upgraded from 1 machine to 3, while we've also been adding in new features.

The way we've worked for a good few years now (on the 1 machine) was simply with Apache's userdir wherein anyone who requested a page which matched http://www.domainname.com/~username served files which were located at /home/members/username/public_html. now, the main server isn't hosting the user files, it's on a second server, called homes.domainname.com, which works in the way I described above, with Apache's userdir mod, while also having a rewrite rule in place that redirects any request on the www server with a "/~" url to go to the homes server.

That's all working fine, but I just started playing around with serving wildcard sub-domains, so that every one of our members are able to access their web folder through username.domainname.com. Now, I've set the bind server up to point http://www.domainname.com to our www server and all other *.domainname.com to the homes server.

Unfortunately, though, it doesn't work how I'd like it to, instead of serving the files directly from there, it rewrites the URL to the way userdir expects it, homes.domainname.com/~username. what I'd actually like to do is have the server directly serve the files from both URLs, username.domainname.com and homes.domainname.com/~username.

My problem is that I don't know how to expand the userdir mod so that it catches and attempts to serve all URLs that aren't that catch all subdomains that aren't "homes", as well as any URLs that match homes.domainname.com/~*.

Anybody with an idea how I can do this?
  #2  
Old 01-Nov-2009, 15:52
seaders seaders is offline
New Member
 
Join Date: Jun 2008
Posts: 8
seaders is on a distinguished road

Re: Mixing sub-domain wildcard serving with userdir mod


Realistically, what I'd mainly want to do is modify the userdir directive,
http://httpd.apache.org/docs/2.2/mod/mod_userdir.html

Rather than just catching the "domainname.com/~([^/]*)/" part of the URL, I'd like it to catch the "([^.]*).domain.com" part. I can do this with rewriting conditions, but that's not the way I want the server to work, I would like Apache to serve the files directly, without rewriting the URL, like it does with the userdir mod.
 
 

Recent GIDBlogInstall Adobe Flash - Without Administrator Rights by LocalTech

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Dynamic Parkinf Script+FREE DOMAIN FINDING SOFTWARE AND FREE .COM DOMAIN! DomainZaar Web Hosting Advertisements & Offers 0 14-May-2008 03:32
VPS at ArteryPlanet.Net - Virtuozzo/cPanel/ WHM/Fantastico Multiple Free domain names arteryplanet Web Hosting Advertisements & Offers 0 07-Apr-2006 13:23
VPS at ArteryPlanet.Net - Virtuozzo/cPanel/WHM/Fantastico+Multiple Free domain names! arteryplanet Web Hosting Advertisements & Offers 0 16-Mar-2006 16:01
Why you need domain names ashish Web Hosting Forum 1 17-Feb-2005 23:28
Win2k domain user dont appear in WinNT domain VoooDooo Computer Software Forum - Windows 5 18-Feb-2004 08:55

Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 13:29.


vBulletin, Copyright © 2000 - 2010, Jelsoft Enterprises Ltd.