Reputation: 4519
How can I give IP DHCP for each container, when I docker run images based on Ubuntu?
Upvotes: 1
Views: 1362
Reputation: 1329092
The way to specify an IP address when creating a container using docker run
is in the works (possibly for docker 1.10, February 2016) in issue 6743.
In order for user to specify a preferred address for the container, plan is to add an explicit
--ip
(--ip6
) option todocker run
to be used in conjunction with--subnet
.
Your ipam (IP address management) driver will ultimately receive the user chosen address as parameter of theRequestAddress()
call.
That means the built-in IPAM driver will honor the preferred IP option specified by the user.
Upvotes: 1