![]() But the Docker host machine’s main IP is accessible from outside.įor a webserver application, you’d obviously need to enable user access to it from the external network. So, the solution we use is to bind the internal port 80 of the Docker container to a port on the host machine, say 9000. Suppose you want to run an NginX web server application in your Docker container. You can install the nginx image and start a container but you cannot directly access it from outside network.ĭocker containers have an internal network and each container is associated with an IP address that can be accessed from the Docker host machine.īeing internal IP, this IP cannot be used to access the containers from external network. To allow external access to Docker containers, you would have to expose their ports by mapping a container’s port to an external port in the host. Today we’ll see how to expose docker ports to make them accessible from the internet. ![]() ![]() GET IN TOUCH WITH THE DOCKER EXPERTS NOW!
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |