New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow use of network name for network interface #23742

bergtwvd opened this Issue Jun 19, 2016 · 3 comments


None yet
4 participants

bergtwvd commented Jun 19, 2016

Containers can be connected to several networks simultanously. The network interfaces are typically named eth0, eth1, eth2, etc. In some instances containers need to be directed to use, say, interface ethX for traffic on Docker network A, and ethY for traffic on Docker network B. Currently there is no relationship between network interface name and Docker network name.

The current (clumsy) work round (via Docker Compose) is to define an ip range per Docker network, and tell the container to use the network interface that falls in that ip range.

A better solution is the ability to name network interfaces after the Docker network name. If the container needs to use a certain network, it can be instructed to use the interface name that matches the Docker network name.

Feature request against:
Docker version 1.11.2, build b9f10c9



This comment has been minimized.

p-thurner commented Nov 11, 2016

I also have this issue, we would like to do accouting via iptables and need to know the names of the network interfaces.


This comment has been minimized.

michaelkwan commented Nov 18, 2016

+1 vote as well


This comment has been minimized.


thaJeztah commented Oct 31, 2017

@bergtwvd there's another issue that is slightly newer, but duplicates this one, and has some more discussion around this; #25181. I'll close this one to keep the discussion central, but feel free to participate in the discussion on that issue 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment