100559/connect-the-localhost-the-machine-from-the-docker-container
Hi Team,
I have launched one Docker container. I want to connect to the localhost of the machine from the Docker container. How can I do that?
Hi@akhtar,
You can use --network="host" in your docker run command. It will connect the localhost or 127.0.0.1 in your docker container, will point to your docker host.
$ docker run --rm -it --network=host ubuntu
You must have come across the /var/run/docker.sock file, ...READ MORE
I've found out that the container id ...READ MORE
What you can do is, allow access ...READ MORE
Adding to kalgi's answer, You can also ...READ MORE
Hey @nmentityvibes, you seem to be using ...READ MORE
It can work if you try to put ...READ MORE
When you use docker-compose down, all the ...READ MORE
To solve this problem, I followed advice ...READ MORE
Hi@akhtar, You can use the docker inspect command ...READ MORE
Hi@Abhishek, You can't connect the docker container from ...READ MORE
OR
At least 1 upper-case and 1 lower-case letter
Minimum 8 characters and Maximum 50 characters
Already have an account? Sign in.