-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dp: Expose link based resources by default (#11)
* Fix formatting Signed-off-by: Jaime Caamaño Ruiz <[email protected]> * DP: fix and improve documentation of OnLinkEvent Wrong break statement was preventing the subsciption to be properly terminated. Improved function doc to better explain behavior on error. Signed-off-by: Jaime Caamaño Ruiz <[email protected]> * DP: make structs private for cleanliness Signed-off-by: Jaime Caamaño Ruiz <[email protected]> * DP: work on main process namespace Allocate, ListAndWatch and the netlink subsciption callbacks are executed on their own goroutines. As documented here [1], go thread model may relocate goroutines among different OS threads that might be running on different namespaces. This patch makes sure that network operations always run on initial main thread namespace. Otherwise the device plugin may end up operating in different namespaces than the one intended. [1] https://github.com/containernetworking/plugins/blob/master/pkg/ns/README.md Signed-off-by: Jaime Caamaño Ruiz <[email protected]> * DP: added explicit config tests Signed-off-by: Jaime Caamaño Ruiz <[email protected]> * DP: expose link based resources by default When no explicit configuration is provided, the device plugin will expose default resources corresponding to links present on the node. So, for every link considered suitable as a macvtap parent, a resource to consume macvtap interfaces would be setup as macvtap.network.kubevirt.io/<link> Right now only physical and bond interfaces are considered suitable macvtap parents. These resources will be operating in bridge mode and capacity of 100. Signed-off-by: Jaime Caamaño Ruiz <[email protected]> * DP: exit on Discover initial error Signed-off-by: Jaime Caamaño Ruiz <[email protected]>
- Loading branch information
Showing
11 changed files
with
438 additions
and
115 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
kind: ConfigMap | ||
apiVersion: v1 | ||
metadata: | ||
name: macvtap-deviceplugin-config | ||
data: | ||
DP_MACVTAP_CONF: "[]" |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.