-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Plugin Config Daemon node selector #484
Fix Plugin Config Daemon node selector #484
Conversation
Thanks for your PR,
To skip the vendors CIs use one of:
|
/cc @SchSeba |
Pull Request Test Coverage Report for Build 5733255954
💛 - Coveralls |
When node selectors are added via "configDaemonNodeSelector" via the sriovoperatorconfigs CRD then completely removed, the previous node selectors would remain for the plugin config daemons (sriov-device-plugin). This was not cleaned up, because the function "syncPluginDaemonSet" bails out when "configDaemonNodeSelector" is empty. For example: Step 1) Create 3 labels in node selector: configDaemonNodeSelector = {"labelA": "", "labelB": "", "labelC": ""} device-plugin DS NodeSelector = {"labelA": "", "labelB": "", "labelC": ""} Step 2) Remove all labels in node selector: configDaemonNodeSelector = {} device-plugin DS NodeSelector = {"labelA": "", "labelB": "", "labelC": ""} The expectation is that the device plugin will revert to the default node selectors (e.g. {"node-role.kubernetes.io/worker": "", "kubernetes.io/os": "linux"}) This change will make the node selector field in the sriov-device-plugin to take in a variable. This default node selector value is then shared with the code that updates the node selector. Signed-off-by: William Zhao <[email protected]>
ad92936
to
48b2aeb
Compare
Thanks for your PR,
To skip the vendors CIs use one of:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@adrianchiris @e0ne Please take a look when you have a chance. Thanks! |
Hey, A question: What is the behaviour today when first deploying sriov-network-operator with sriovoperatorconfig having an empty ConfigDaemonNodeSelector? as far as i see from the codebase. it will not deploy daemonsets. is my understanding correct ? |
Hi @adrianchiris, |
@adrianchiris @SchSeba Yes by default the node selector is on Is this good on your end. Could we merge this changes? |
When node selectors are added via "configDaemonNodeSelector" via the sriovoperatorconfigs CRD then completely removed, the previous node selectors would remain for the plugin config daemons (sriov-device-plugin). This was not cleaned up, because the function "syncPluginDaemonSet" bails out when "configDaemonNodeSelector" is empty. For example:
The expectation is that the device plugin will revert to the default node selectors (e.g. {"node-role.kubernetes.io/worker": "", "kubernetes.io/os": "linux"})
This change will make the node selector field in the sriov-device-plugin to take in a variable. This default node selector value is then shared with the code that updates the node selector.