Tag: networking

Docker on mac with VirtualBox VM in Bridged mode

I tried changing adapter 2 of the ‘default’ VM used by docker from ‘host-only’ to ‘bridged’ in order to being able to access the docker containers from other machines in the local network of the host. What I get after running the terminal command is this message: What I need to do so that docker […]

Docker set ipaddress and start services

I have setup docker and create container but problem is i want to bring up on my LAN IP subnet, I have configured docker0 has bridged and start docker -d -b docker0, Now i want to start container with static IP and start httpd and mysqld services. Dockerfile: FROM centos/centos6-latest RUN /sbin/ifconfig eth0 192.168.1.150 RUN […]

Hot to enable swarm containers to connect to the host machine?

I need to use docker in swarm mode to use some shared secrets through my services. One of these services needs to use a local MS SQL database on my computer. This is my docker-compose file: version: ‘3.2’ services: auth_service: build: ./Services/AuthService image: sandhaka/auth_service command: dotnet run –rm ports: – “5000:5000” environment: ASPNETCORE_URLS: http://*:5000 DB_CONNECTION_STRING: […]

Is it possible to isolate docker container in user-defined overlay network from outside internet?

With new network feature in docker 1.10 it is possible to create isolated overlay networks – which works very well. Containers in 2 separate networks can not talk to each other. Is it possible, however, to deny container in overlay network to reach public internet? Eg to make ping 8.8.8.8 fail, while having docker host […]

Port mapping in Docker on Mac OSX installed with Docker Toolbox

I installed Docker on a Mac using the Docker Toolbox. I opened Docker Quickstart Terminal and ran docker run hello-world That works fine. Then I tried: docker run -d -p 8080:80 nginx I can see that the container is added. docker log with the container id returns nothing but I think that’s normal? When I […]

Create a network for two machines in docker that is not reachable from the host system

Is there a way to create a network with two docker containers in it which is not accessible from the host system? I search some way to do what is called internal networking in virtualbox. If it is possible, how? And if it is not, why? Thanks 😀

Multicast with Docker Swarm and overlay network

I am testing an application using multicast for the discovery. I created a Swarm cluster and a network create -d overlay swarm-net so the containers share the same LAN across the several Swarm agents hosts. The discovery seemed to not be working, so I installed tshark. tshark shows the IP address node within which tshark […]

Sending Multicast Packets from Docker Container (to multicast group)

I have an application that sends messages over UDP multicast that I’ve been attempting to put under docker. I’ve been running into much headwind trying to send multicast packets from a docker container. I have been able to send messages through the –net=host option on running the docker container. I would, however, like to stick […]

Access a docker container in docker multi-host network

I have created a Docker multi-host network using Docker Overlay network with 4 nodes: node0, node1, node2, and node3. Node0 act as key-value store which shares the information of nodes while node1, node2, and node3 are bound to the key-value store. Here are node1 networks: user@node1$ docker network ls NETWORK ID NAME DRIVER 04adb1ab4833 RED […]

Prevent Docker Compose from creating separate network

I discovered that Docker Compose places containers in a separate network when using version 2 of their YAML syntax. This makes linking with existing containers difficult. Is there a way to prevent this, and revert to the behavior of version 1, without actually reverting?

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