1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Overlay driver should assign interface mac based on the IP

Signed-off-by: Santhosh Manohar <santhosh@docker.com>
This commit is contained in:
Santhosh Manohar 2015-08-14 23:59:02 -07:00
parent 7f15aee70e
commit e4853a4ada

View file

@ -73,7 +73,7 @@ func (d *driver) CreateEndpoint(nid, eid types.UUID, epInfo driverapi.EndpointIn
binary.BigEndian.PutUint32(ep.addr.IP, bridgeSubnetInt+ipID)
ep.mac = netutils.GenerateRandomMAC()
ep.mac = netutils.GenerateMACFromIP(ep.addr.IP)
err = epInfo.AddInterface(1, ep.mac, *ep.addr, net.IPNet{})
if err != nil {