#1  
Old 9th November 2009, 00:43
laqup laqup is offline
Junior Member
 
Join Date: Nov 2009
Posts: 4
Thanks: 2
Thanked 1 Time in 1 Post
Default internal domain forwards

Hi everybody,

first of all: I'm new to ispconfig and this might be a pretty dumb question:
I have a big problem configuring domains / domain-forwards.

For example:
I created a client and assigned a website to him.
I used "web1" as hostnome and "mymanagementdomain.xxx" as domainname.
=> I can access the users default page located in /web/ with web1.mymanagementdomain.xxx.

The client owns some real domains, thus I add these domains in the website under "co-domains" and specify a forward folder, e.g.: lolomg
=> When I type www.myclientdomain.xxx in my browser I'd like to be directed to this folder.
Instead I am forwarded to web1.mymanagementdomain.xxx/lolomg/. This behaviour dirves me crazy. I really don't want to see the "managementdomain" or the forward-folder when opening the client-domain.
Isn't there any way to do the routing internally?

Thanks in advance,

Best regards,
Daniel
Reply With Quote
Sponsored Links
  #2  
Old 9th November 2009, 14:23
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,743 Times in 2,577 Posts
Default

Quote:
Originally Posted by laqup View Post
Instead I am forwarded to web1.mymanagementdomain.xxx/lolomg/. This behaviour dirves me crazy. I really don't want to see the "managementdomain" or the forward-folder when opening the client-domain.
Isn't there any way to do the routing internally?
That's the way ISPConfig handles forwards. If you don't want this, you can specify your own rewrite rules in the Apache Directives field of that web site in ISPConfig.
This link might help you: http://httpd.apache.org/docs/2.2/rew...ite_guide.html
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
The Following User Says Thank You to falko For This Useful Post:
laqup (9th November 2009)
  #3  
Old 9th November 2009, 20:15
laqup laqup is offline
Junior Member
 
Join Date: Nov 2009
Posts: 4
Thanks: 2
Thanked 1 Time in 1 Post
 
Default

I can't believe this. Let's start again, maybe my first post was confusing, or I miss an important piece or chose a complete wrong approach.

Let's imagine: We have a client who owns two domains, let's say google.com and amazon.com. This client wants only one user account (credentials). What I would do is the following:
- Create a Client
- Asign a website
- Use www as hostname and google.com as domain

First problem:
- Now I can't specify a forward rule for www.google.com, I have to put my index-file in the DocumentRoot (web/)

Next steps:
- Create a new co-domain: amazon.com and www.amazon.com with a forward to the folder (web/)"amazon"

Second problem:
- If I type www.amazon.com in the browser I am externally redirected to www.google.com/amazon (absolute no-go)

Okay, now I'll try to find a better solution:
- I'll use the Apache Directives
- I change the apache documentroot to /amazon

Third problem:
- Oh wait, this will change documentroot for google.com too because they use both the same virtualhost - not a good idea

Next Apache Directives Approach:
- Change the Rewrite condition
- RewriteCond %{HTTP_HOST} ^amazon\.com [NC] RewriteRule ^/(.*)$ /amazon/$1
- This works! BUT: The Apache directives are written ABOVE all other entries in the vhosts_ispconfig.conf
- I have to delete the automated entries in the vhosts_ispconfig

Fourth problem:
- If I make a change in ISPConfig or manually restart the config server, the old Rewrite conditions will be added BELOW my custom apache directive, hence my own code gets overruled and won't work anymore

So please tell me that I am stupid and have chosen a complete wrong approach to solve this problem, this would make me very happy.
The other solution is: ISPConfig won't work for me, that would make me sad.

Thanks in advance,
Best regards,
Daniel

Update:
Okay, I used the [L] flag in the rewrite conditions to prevent further rule execution. This solves the fourth problem.
The first problem could be solved too, with a similar rewrite rule:
RewriteCond %{HTTP_HOST} ^www\.google\.com [NC]
RewriteRule ^/(.*)$ /google/$1 [L]

Nevertheless I'd be glad if you could tell me if this is the right (or only) approach, or if I'm thinking to complex.

Last edited by laqup; 9th November 2009 at 20:31.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

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

BB 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
Need help get mail to work (can't recieve and apperently can't send) omega13a Installation/Configuration 19 20th August 2009 21:06
2.2.24 Internal Forwards not working. example: jsmith@1.com to jsmith@2.com friday General 3 27th December 2008 06:42
CentoS doesn't send the emails vaio1 Installation/Configuration 18 5th November 2008 17:51
Postfix + DKIM - Error in log donb01 Server Operation 2 24th July 2008 17:59
internal domain error with mail matehortua Installation/Configuration 5 16th October 2005 18:31


All times are GMT +2. The time now is 14:29.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.