-
Notifications
You must be signed in to change notification settings - Fork 40k
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
Add storageClass.mountOptions and use it in all applicable plugins #51228
Conversation
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.
Mostly looks good to me. left some minor comments.
if !plugin.SupportsMountOption() && len(options.MountOptions) > 0 { | ||
strerr := fmt.Sprintf("Cannot provision volume because the provisioner doesn't support mount options but the StorageClass has mount options %v", options.MountOptions) | ||
glog.V(2).Infof("cannot provision volume for claim %q with StorageClass %q because the provisioner doesn't support mount options but the StorageClass has mount options %v", claimToClaimKey(claim), storageClass.Name, options.MountOptions) | ||
ctrl.eventRecorder.Event(claim, v1.EventTypeWarning, events.ProvisioningFailed, strerr) |
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.
should we not just return from here? Because if PV has mount options and volume plugin doesn't support it, it will be rejected by API server anyways.
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.
Lets add a test for this perhaps?
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.
yeah, return statement is missing.
will add a test
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.
done
e81a92b
to
4eb8c32
Compare
ac945b7
to
abc7160
Compare
@wongma7: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
/test pull-kubernetes-bazel |
/approve This is not a code review |
lgtm in general, will wait for final PR |
abc7160
to
19e06a4
Compare
@jsafrane final pr is ready, (rebased and the first 2 commits disappeared : )) ) |
/lgtm |
19e06a4
to
ca98b8e
Compare
rebased, please re-add lgtm @jsafrane tytyty |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: jsafrane, thockin, wongma7 Associated issue: 168 The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these OWNERS Files:
You can indicate your approval by writing |
/test all [submit-queue is verifying that this PR is safe to merge] |
Automatic merge from submit-queue |
Automatic merge from submit-queue Add storageClass.mountOptions and use it in all applicable plugins split off from kubernetes#50919 and still dependent on it. cc @gnufied issue: kubernetes/enhancements#168 ```release-note Add mount options field to StorageClass. The options listed there are automatically added to PVs provisioned using the class. ```
split off from #50919 and still dependent on it. cc @gnufied
issue: kubernetes/enhancements#168