Let IPAM pick any peer we know about to transfer ownership to, when shutting down
This commit is contained in:
1 parent
2bbe6a2ad8
commit
b3cda39b0b
4 files changed
+39
-4
No files matched your search
+2
-1
@@ -368,7 +368,8 @@ func createAllocator(router *weave.Router, ipRangeStr string, defaultSubnetStr s
|
||||
Log.Fatalf("IP address allocation default subnet %s does not overlap with allocation range %s", defaultSubnet, ipRange)
|
||||
}
|
||||
}
|
||||
allocator := ipam.NewAllocator(router.Ourself.Peer.Name, router.Ourself.Peer.UID, router.Ourself.Peer.NickName, ipRange.Range(), quorum)
|
||||
namesFunc := func() map[weave.PeerName]struct{} { return router.Peers.Names() }
|
||||
allocator := ipam.NewAllocator(router.Ourself.Peer.Name, router.Ourself.Peer.UID, router.Ourself.Peer.NickName, ipRange.Range(), quorum, namesFunc)
|
||||
|
||||
allocator.SetInterfaces(router.NewGossip("IPallocation", allocator))
|
||||
allocator.Start()
|
||||
|
||||
Reference in new issue
Block a user