0
votes

When creating an Azure App Service with a Docker image. Is it possible to listen on other ports than 80 and 443 from the Docker image?

My requirement is that TCP port 25 from the Docker image is externally reachable.

1
I would think TCP port 25 of your machine (server) is externally reachable? Or is your docker container deployed on the host network? If it's just deployed in the default bridge network of docker itself, you can just map your port of the docker container on the port of your server (25) with -p 25:80 (port of container 80 will be mapped on port 25 of your server)lvthillo

1 Answers

1
votes

As Azure Web App sandbox states about Networking Restrictions/Considerations:

Network endpoint listening

The only way an application can be accessed via the internet is through the already-exposed HTTP (80) and HTTPS (443) TCP ports; applications may not listen on other ports for packets arriving from the internet. However, applications may create a socket which can listen for connections from within the sandbox. For example, two processes within the same app may communicate with one another via TCP sockets; connection attempts incoming from outside the sandbox, albeit they be on the same machine, will fail. See the next topic for additional detail.