refactor: supply /proc path to CreateAndAttachVeth()
Move the assumptions about where we're running up towards the caller.
This commit is contained in:
1 parent
2f235daa1c
commit
0f3864968e
3 files changed
+20
-18
No files matched your search
@@ -134,7 +134,7 @@ func (driver *driver) CreateEndpoint(create *api.CreateEndpointRequest) (*api.Cr
|
||||
|
||||
// create veths. note we assume endpoint IDs are unique in the first 9 chars
|
||||
name, peerName := vethPair(create.EndpointID)
|
||||
if _, err := weavenet.CreateAndAttachVeth(name, peerName, weavenet.WeaveBridgeName, 0, false, true, nil); err != nil {
|
||||
if _, err := weavenet.CreateAndAttachVeth("/proc", name, peerName, weavenet.WeaveBridgeName, 0, false, true, nil); err != nil {
|
||||
return nil, driver.error("JoinEndpoint", "%s", err)
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user