8000 fail plugin operation on bridge attachment error by rade · Pull Request #2098 · weaveworks/weave · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Jun 20, 2024. It is now read-only.

fail plugin operation on bridge attachment error #2098

Merged
merged 1 commit into from
Mar 24, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions plugin/net/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -135,11 +135,15 @@ func (driver *driver) JoinEndpoint(j *api.JoinRequest) (*api.JoinResponse, error
Log.Errorf("device %s is %+v", WeaveBridge, maybeBridge)
return nil, errorf(`device "%s" is of type "%s"`, WeaveBridge, maybeBridge.Type())
}
odp.AddDatapathInterface(WeaveBridge, local.Name)
if err := odp.AddDatapathInterface(WeaveBridge, local.Name); err != nil {
return nil, errorf(`failed to attach "%s" to device "%s": %s`, local.Name, WeaveBridge, err)
}
case *netlink.Device:
Log.Warnf("kernel does not report what kind of device %s is, just %+v", WeaveBridge, maybeBridge)
// Assume it's our openvswitch device, and the kernel has not been updated to report the kind.
odp.AddDatapathInterface(WeaveBridge, local.Name)
if err := odp.AddDatapathInterface(WeaveBridge, local.Name); err != nil {
return nil, errorf(`failed to attach "%s" to device "%s": %s`, local.Name, WeaveBridge, err)
}
default:
Log.Errorf("device %s is %+v", WeaveBridge, maybeBridge)
return nil, errorf(`device "%s" not a bridge`, WeaveBridge)
Expand Down
0