Re: [EMAIL PROTECTED] mod_rewrite mass virtual hosting and aliases

2005-12-06 Thread gregory duchesnes
Anyone's got an idea, i'm still stuck on this one... gregory duchesnes a écrit : Hi all, i'm trying to set up some kind of ISP style virtual hosting, the problem is some domains have a lot of aliases (which i need to redirect to the master domain with à code 301). I thought of using

Re: [EMAIL PROTECTED] mod_rewrite mass virtual hosting and aliases

2005-12-06 Thread gregory duchesnes
I turn RewriteLog 9 but it is such a nightmare, i don't see what's wrong... by the way i cleaned the garbage characters when i did my reply so there's nothing to decipher, might help, no? Greg Joshua Slive a écrit : On 12/6/05, gregory duchesnes [EMAIL PROTECTED] wrote: Anyone's got

Re: [EMAIL PROTECTED] mod_rewrite mass virtual hosting and aliases

2005-12-06 Thread Joshua Slive
On 12/6/05, gregory duchesnes [EMAIL PROTECTED] wrote: Anyone's got an idea, i'm still stuck on this one... # define the map file RewriteMap vhost txt:/www/conf/vhost.map # deal with aliases as above RewriteCond %{REQUEST_URI} ^/icons/ RewriteCond %{REQUEST_URI} ^/cgi-bin/ # if

Re: [EMAIL PROTECTED] mod_rewrite mass virtual hosting and aliases

2005-12-06 Thread gregory duchesnes
oups, i don't understand you logic either ;) ok i'll try to make things clearer What i'm trying to do is this : - check if the folder /var/www/hosts/${lowercase:%{SERVER_NAME}}/web exists - if yes rewrite the request to this folder - else if SERVER_NAME is found in the vhost.map (as first

Re: [EMAIL PROTECTED] mod_rewrite mass virtual hosting and aliases

2005-12-06 Thread gregory duchesnes
me again, sorry, i did one more mistake in the first RewriteCond, it should be like this : # if folder exists as a master domain RewriteCond /var/www/hosts/${lowercase:%{SERVER_NAME}}/web -d # do the magic RewriteRule ^/(.*)$ /var/www/hosts/${lowercase:%{SERVER_NAME}}/web/$1 [L] # else redirect

Re: [EMAIL PROTECTED] mod_rewrite mass virtual hosting and aliases

2005-12-06 Thread gregory duchesnes
Beware, mail crossing ;) I'm beginning to understand your logic, though i don't see why it should be faster since you do a lookup in vhost.map for each request. In the case aliases are used only once in a while it could even be slower. But, if i follow your idea, and since mapping are cached,

Re: [EMAIL PROTECTED] mod_rewrite mass virtual hosting and aliases

2005-12-06 Thread Joshua Slive
On 12/6/05, gregory duchesnes [EMAIL PROTECTED] wrote: Beware, mail crossing ;) I'm beginning to understand your logic, though i don't see why it should be faster since you do a lookup in vhost.map for each request. In the case aliases are used only once in a while it could even be slower.

[EMAIL PROTECTED] mod_rewrite mass virtual hosting and aliases

2005-12-05 Thread gregory duchesnes
Hi all, i'm trying to set up some kind of ISP style virtual hosting, the problem is some domains have a lot of aliases (which i need to redirect to the master domain with à code 301). I thought of using mod_vhost_alias this way: - create a folder for the master domain - create a symlink to

Re: [EMAIL PROTECTED] mod_rewrite mass virtual hosting and aliases

2005-12-05 Thread gregory duchesnes
Please ignore the pipes | that were automatically inserted in my code, i don't know where it comes from... gregory duchesnes a écrit : Hi all, i'm trying to set up some kind of ISP style virtual hosting, the problem is some domains have a lot of aliases (which i need to redirect to the