You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Zoe Ballz <zo...@zoeballz.tv> on 2004/07/26 12:21:02 UTC

[users@httpd] Sub-sub domains

Hi

I am setting up personal web pages on a domain so that if someone chooses
XXX123 then their URL would be XXX123.pwp.zoeballz.net. The DNS A record
would be wildcarded as *.pwp.zoeballz.net.

My question is - In the virtualhost section of httpd.conf, would a wildcard
AND name specific be valid?

E.g. would this work?

virtualhost 1 - xxx123.pwp.zoeballz.net >>>>>> dir1
virtualhost 2 - yyy345.pwp.zoeballz.net >>>>>> dir2
virtualhost 3 - *.pwp.zoeballz.net >>>>>> not-found-dir (so this catches any
unknowns)

Reason is I do NOT want requests for unknown pwp subdomains to get the same
error page as the page for other subdomains. I run Apache 1.3.31 on this
particular server

Thanks,
Zoe

http://zoeballz.net - Website Hosting for the Transgendered Community


---------------------------------------------------------------------
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@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


[users@httpd] SPAM:(L1-25%)SPAM:(L1-25%)Re: SPAM:(L1-25%)[users@httpd] Sub-sub domains

Posted by Eimantas Vaiciunas <ei...@sc.vu.lt>.
On Monday 26 July 2004 12:21, Zoe Ballz wrote:
> Hi
>
> I am setting up personal web pages on a domain so that if someone chooses
> XXX123 then their URL would be XXX123.pwp.zoeballz.net. The DNS A record
> would be wildcarded as *.pwp.zoeballz.net.
Try reading Mass Virtual Hosting in apache manual.


---------------------------------------------------------------------
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@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Sub-sub domains

Posted by Joshua Slive <js...@gmail.com>.
On Mon, 26 Jul 2004 11:21:02 +0100, Zoe Ballz <zo...@zoeballz.tv> wrote:
> Hi
> 
> I am setting up personal web pages on a domain so that if someone chooses
> XXX123 then their URL would be XXX123.pwp.zoeballz.net. The DNS A record
> would be wildcarded as *.pwp.zoeballz.net.
> 
> My question is - In the virtualhost section of httpd.conf, would a wildcard
> AND name specific be valid?
> 
> E.g. would this work?
> 
> virtualhost 1 - xxx123.pwp.zoeballz.net >>>>>> dir1
> virtualhost 2 - yyy345.pwp.zoeballz.net >>>>>> dir2
> virtualhost 3 - *.pwp.zoeballz.net >>>>>> not-found-dir (so this catches any
> unknowns)
> 
> Reason is I do NOT want requests for unknown pwp subdomains to get the same
> error page as the page for other subdomains. I run Apache 1.3.31 on this
> particular server

See the docs on name-based virtual hosting.  You'll see that the first
listed <VirtualHost> block that matches the NameVirtualHost directive
is the "default" virtual host that catches all unknown requests.  So
you can do

NameVirtualHost *:80

<VirtualHost *:80>
ServerName unknown.pwp.zoeballz.net
ServerAlias *.pwp.zoeballz.net
DocumentRoot ...
ErrorDocument ...
</VirtualHost>

<VirtualHost *:80>
ServerName xxx123.pwp.zoeballz.net
DocumentRoot ...
...
</VirtualHost>
...

Joshua.

---------------------------------------------------------------------
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@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org