-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Enable PersistentVolumeLabel admission plugin #9822
Enable PersistentVolumeLabel admission plugin #9822
Conversation
@@ -318,6 +318,7 @@ var ( | |||
"SCCExecRestrictions", | |||
quotaadmission.PluginName, | |||
"ClusterResourceQuota", | |||
"PersistentVolumeLabel", |
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.
quota needs to go last
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.
Seems like a comment is in order for that so the next poor soul doesn't do this too
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.
Seems like a comment is in order for that so the next poor soul doesn't do this too
Probably test worthy. There's already some tests for consistency.
738dc33
to
d8df3e3
Compare
Seems like this is something that deserves a test. Is there one you can enable from upstream in our conformance suite? |
I think those rely on cloud providers. Until Steve turns on the "deploy to AWS" stuff we're probably blocked. Can we fake it in an integration test? |
Agreed that this is cloud provider specific. However there is an upstream unit test: https://github.com/kubernetes/kubernetes/blob/master/plugin/pkg/admission/persistentvolume/label/admission_test.go |
@@ -317,6 +317,9 @@ var ( | |||
"LimitPodHardAntiAffinityTopology", | |||
"SCCExecRestrictions", | |||
quotaadmission.PluginName, | |||
"PersistentVolumeLabel", |
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.
before both quota plugins.
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.
Ugh. Ok.
Ok, if it can't be tested automatically, is there somewhere we have to make a mark to be sure that test checks it during a regression suite? |
[test] |
Enable PersistentVolumeLabel admission plugin. This labels AWS and GCE volumes with their zone, so the scheduler can limit the nodes for a pod to only those in the same zone as the peristent volumes being used by the pod.
d8df3e3
to
b66d87f
Compare
Updated PTAL |
Evaluated for origin test up to b66d87f |
lgtm [merge] |
continuous-integration/openshift-jenkins/test FAILURE (https://ci.openshift.redhat.com/jenkins/job/test_pr_origin/6221/) |
continuous-integration/openshift-jenkins/merge SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pr_origin/6279/) (Image: devenv-rhel7_4589) |
[merge] |
Evaluated for origin merge up to b66d87f |
Ok, this merged but is disabled in the admission_sync_test.go. Why didn't it fail? |
It didn't fail because the plugin is now both registered & used. Previously it was registered but not used (and the test case marks it as not used). If you change from registered/not-used/marked-not-used to registered/used/marked-not-used, the test will pass. The test only tries to catch
I'll submit a PR to remove PersistentVolumeLabel from the list of not-used plugins. |
I'm doing it in the rebase - don't worry. On Sep 9, 2016, at 9:31 AM, Andy Goldstein [email protected] wrote: It didn't fail because the plugin is now both registered & used. Previously The test only tries to catch
I'll submit a PR to remove PersistentVolumeLabel from the list of not-used — |
Enable PersistentVolumeLabel admission plugin. This labels AWS and GCE volumes with their zone, so the scheduler can limit the nodes for a pod to only those in the same zone as the peristent volumes being used by the pod.
Fixes bug 1356010
@smarterclayton @deads2k @liggitt