Re: How to access private IPs from a container [message #37232 is a reply to message #37197] |
Thu, 27 August 2009 18:52   |
Paparaciz
Messages: 302 Registered: August 2009
|
Senior Member |
|
|
in HW node add iptables rule smth like:
iptables -A POSTROUTING -s 1.2.3.5 -d 10.1.1.0/255.255.255.0 -j SNAT --to-source 10.1.1.1
where 1.2.3.5 is vps ip
10.1.1.0 your private network (change subnet mask as needed)
10.1.1.1 is ip of HN interface to the 10.1.1.0 network
or if some how you don't need such interface (going through gateway?) you can put ip 1.2.3.4
|
|
|