Using a new install of Proxmox 4.2-11/2c626aa1. Setting up a port forward using IPtables of external port 80 to internal port 80 on an Nginx container running as a reverse proxy. I've had this working before, there shouldn't be anything to it. I know the Nginx container is running as I can see the webpage by forwarding through an ssh tunnel like this :
However I get no response on port 80 on the external IP. Any help much appreciated, there's some detail I've overlooked.
Proxmox Host /etc/network/interfaces :
Nginx Guest /etc/network/interfaces :
Code:
ssh -R 47000:10.3.0.2:80 root@artemis
However I get no response on port 80 on the external IP. Any help much appreciated, there's some detail I've overlooked.
Proxmox Host /etc/network/interfaces :
Code:
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address 1.2.3.10
netmask 255.255.255.192
gateway 1.2.3.4
dns-nameservers 217.112.87.147 217.112.88.10 217.112.88.90
post-up echo 1 > /proc/sys/net/ipv4/conf/eth0/proxy_arp
auto vmbr0
iface vmbr0 inet static
address 10.3.0.1
netmask 255.255.255.128
dns-nameservers 217.112.87.147 217.112.88.10 217.112.88.90
bridge_ports none
bridge_stp off
bridge_fd 0
post-up echo 1 > /proc/sys/net/ipv4/ip_forward
post-up iptables -t nat -A POSTROUTING -s '10.3.0.0/25' -o eth0 -j MASQUERADE
post-down iptables -t nat -D POSTROUTING -s '10.3.0.0/25' -o eth0 -j MASQUERADE
post-up iptables -t nat -A PREROUTING -i any -p tcp --dport 80 -j DNAT --to 10.3.0.2:80
post-down iptables -t nat -D PREROUTING -i any -p tcp --dport 80 -j DNAT --to 10.3.0.2:80
Nginx Guest /etc/network/interfaces :
Code:
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address 10.3.0.2
netmask 255.255.255.128
# --- BEGIN PVE ---
post-up ip route add 1.2.3.10 dev eth0
post-up ip route add default via 1.2.3.10 dev eth0
pre-down ip route del default via 1.2.3.10 dev eth0
pre-down ip route del 1.2.3.10 dev eth0
# --- END PVE ---