Welcome Guest, Not a member yet? Register   Sign In
Configuration for application with two (2) IPs
#1

[eluser]CARP[/eluser]
Hi guys
I'm working in a govt. area with lots of PCs which are behind a proxy

I have one server with a local IP: 10.64.x.x
This server also has assigned a public IP: 200.41.x.x

1) How can I config my codeIgniter app so it can be accessed from both: local & public IP?
I guess I should change in some way this line, right?
Code:
$config['base_url'] = "http://10.64.x.x/app";

2) Does anyone know how can I make Apache to listen in local IP and public IP at the same time?

Also, is there any other setting I should have into account for making this work?

PS: accessing directly to public IP from this LAN is not possible because LAN's configuration, rules, proxy

Thanks a lot
#2

[eluser]jáquer[/eluser]
For #1, I follow the advice on this thread. My config.php looks like this:

Code:
$config['base_url']     = "http://" . $_SERVER['HTTP_HOST'] . "/shopping/";

For #2, in the Apache config you have to look for the "Listen" entry. If it has just a port number, like so:

Code:
Listen 80

then Apache will listen on all available interfaces/IPs.




Theme © iAndrew 2016 - Forum software by © MyBB