I"ve built a single CentOS 7 and have one container running on it with a mapped port to 8080. I can connect to it via the Azure Public IP. I then built a Azure LB and wanted to use a NAT rule to map 80 on the outside to 8080 on the inside, but the LB seems to want to redirect the client to 8080 on the outside instead of mapping the traffic. I spent 3 hours on the phone with the Azure support and they couldn’t get it to work. Should I be doing something different on the docker networking? It is because it’s a NAT of a NAT basically going through the docker bridge network?
Goal:
I’m trying to use either LB Rules or NAT Rules to map the external IP of the LB to a port of a container running on a VM in Azure (not ACS).
- I have the container running on a VM in Azure and can verify the port is up as I can curl to it from the same VNet and connect to it externally using the Public IP and it responds on port PUBLICIP:8080.
- I have built a LB Rule that maps it’s Front IP Address Port 80 to the Backend Port of 8080 and the VM mentioned above is in the Backend Pool.
- I’ve built a probe TCP Port 8080 used by the rule.
When I try to connect to the Public IP of the LB I see one GET in the web server log of the Container, but then after that a connection is never established. When the Web browser times out the web browser shows the IPADDRESS: 8080. It’s like it redirects the broweser and thus the reason why the connection fails? It should be NATing that traffic? Thoughts?