Private network issues with docker

I’m having trouble connecting to MongoDB on the docker host. I’m not sure what the problem is but my current docker container should be able to connect with a non-docker MongoDB instance.

My host has 2 network interfaces which are eth0 with an outbound IP and eth1 with a private lan ip 192.168.100.200. Is there any way to connect to the host without doing –net=host?

  • ARG or ENV, which one to use in this case?
  • Can Docker 1.12 in “swarm mode” provide “a single, virtual Docker host”?
  • Docker-compose volumes doesn't copy any files
  • Docker yum install issue - Cannot retrieve metalink for repository: epel/x86_64
  • Docker unable to start, new network adapter created on every restart
  • error during connect: … http: server gave HTTP response to HTTPS client on any docker command with remote host
  • How to configure dns entries for Docker Compose
  • What server URL should one provide for TeamCity agent in Docker?
  • How do you stop a deployed docker stack
  • Run webpack build during docker-compose build process
  • Removing a file from a docker container
  • Multiple Python Scripts in Docker
  • One Solution collect form web for “Private network issues with docker”

    Can you enter in your MongoDB using nsenter or docker exec, and issue some commands such as

    ip all
    

    using

    nsenter
    

    from https://github.com/jpetazzo/nsenter
    or

    docker exec
    

    if you have a recent version of docker

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.