make centos VPS using 2 ip

General support questions
Post Reply
LP89
Posts: 1
Joined: 2014/08/07 07:51:30

make centos VPS using 2 ip

Post by LP89 » 2014/08/07 07:56:28

Hi i have a VPS with 2 ip assigned that i will call now ip1 and ip2 for example
they are both working but i want to do a thing:
i need that if i connect to the ip1 a my file should make an external file_get_contents using the ip1
and if i connect to the ip2 the same file should make an external file_get_contents using the ip2
example:
ip1/file.php => send request to an external resource (using ip1 and if the external resource will check the $_SERVER['REMOTE_ADDR'] it will show ip1)
ip2/file.php => send request to the same external resource (using ip2 and if the external resource will check the $_SERVER['REMOTE_ADDR'] it will show ip2)
i wish you understand my problem.
Thanks
Leonardo

Post Reply