You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Jorge Schrauwen <jo...@gmail.com> on 2009/08/12 18:12:58 UTC
[users@httpd] Re: A single IP address and Domain name serving many servers
You can do this with mod proxy.
# Proxy Forwarding
<IfModule !mod_proxy.c>
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so
</IfModule>
ProxyRequests Off
<Proxy *>
Order allow,deny
Allow from all
</Proxy>
#forward /siteX to backend server
ProxyPass /site1/ http://10.0.0.2/
ProxyPassReverse /site1/ http://10.0.0.2/
ProxyPass /site2/ http://10.0.0.3/
ProxyPassReverse /site2/ http://10.0.0.3/
Alternatively you can use sub-domains too if you have control over
both dns and apache.
site1.example.org ---> WAN IP --> LAN IP where apache does namevirtualhosting
site2.example.org ---> ...
Also support questions should go to users@httpd.apache.org and not
dev@, this mailing list is for development related discussion.
Jorge Schrauwen
On Wed, Aug 12, 2009 at 6:01 PM, Branquim<al...@hotmail.com> wrote:
>
> I want to know if its possible and how to do it...
>
> I have one valid ip address and one internet domain.
>
> What I want to do is:
> - when a client access my domain with: www.mydomain.com on his web browser
> he access my apache server apache1.localnetwork 10.0.0.1 (I already do this
> through nat in iptables).
> - when he types www.mydomain.com/site1 I serve him with another apache
> server inside my local network (apache2.localnetwork 10.0.0.2).
> - when he types www.mydomain.com/site2 he access another server
> apache3.localnetwork 10.0.0.3.
>
> How can I do this redirection with the client passing me just another uri
> and I serving him with different apache servers, having only an external ip
> and domain name?
>
> Thanks.
> --
> View this message in context: http://www.nabble.com/A-single-IP-address-and-Domain-name-serving-many-servers-tp24939564p24939564.html
> Sent from the Apache HTTP Server - Dev mailing list archive at Nabble.com.
>
>
---------------------------------------------------------------------
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: A single IP address and Domain name serving many servers
Posted by Branquim <al...@hotmail.com>.
It worked...
Thank you man, and sorry for the mistake.
[]'s
Jorge Schrauwen-3 wrote:
>
> You can do this with mod proxy.
>
> # Proxy Forwarding
> <IfModule !mod_proxy.c>
> LoadModule proxy_module modules/mod_proxy.so
> LoadModule proxy_http_module modules/mod_proxy_http.so
> </IfModule>
>
> ProxyRequests Off
> <Proxy *>
> Order allow,deny
> Allow from all
> </Proxy>
>
> #forward /siteX to backend server
> ProxyPass /site1/ http://10.0.0.2/
> ProxyPassReverse /site1/ http://10.0.0.2/
>
> ProxyPass /site2/ http://10.0.0.3/
> ProxyPassReverse /site2/ http://10.0.0.3/
>
>
> Alternatively you can use sub-domains too if you have control over
> both dns and apache.
> site1.example.org ---> WAN IP --> LAN IP where apache does
> namevirtualhosting
> site2.example.org ---> ...
>
> Also support questions should go to users@httpd.apache.org and not
> dev@, this mailing list is for development related discussion.
>
> Jorge Schrauwen
>
>
>
> On Wed, Aug 12, 2009 at 6:01 PM, Branquim<al...@hotmail.com> wrote:
>>
>> I want to know if its possible and how to do it...
>>
>> I have one valid ip address and one internet domain.
>>
>> What I want to do is:
>> - when a client access my domain with: www.mydomain.com on his web
>> browser
>> he access my apache server apache1.localnetwork 10.0.0.1 (I already do
>> this
>> through nat in iptables).
>> - when he types www.mydomain.com/site1 I serve him with another apache
>> server inside my local network (apache2.localnetwork 10.0.0.2).
>> - when he types www.mydomain.com/site2 he access another server
>> apache3.localnetwork 10.0.0.3.
>>
>> How can I do this redirection with the client passing me just another uri
>> and I serving him with different apache servers, having only an external
>> ip
>> and domain name?
>>
>> Thanks.
>> --
>> View this message in context:
>> http://www.nabble.com/A-single-IP-address-and-Domain-name-serving-many-servers-tp24939564p24939564.html
>> Sent from the Apache HTTP Server - Dev mailing list archive at
>> Nabble.com.
>>
>>
>
>
--
View this message in context: http://www.nabble.com/A-single-IP-address-and-Domain-name-serving-many-servers-tp24939564p24956476.html
Sent from the Apache HTTP Server - Dev mailing list archive at Nabble.com.