-
Notifications
You must be signed in to change notification settings - Fork 2k
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
acl: Add HostVolume ACLs #6014
acl: Add HostVolume ACLs #6014
Conversation
d5ce4d7
to
4888b4c
Compare
afb334d
to
bacd83c
Compare
5935e7a
to
4a1d99c
Compare
bacd83c
to
14c73e3
Compare
4a1d99c
to
d2ee5fc
Compare
bd34a58
to
22b16de
Compare
14c73e3
to
ce8951b
Compare
ce8951b
to
346a16e
Compare
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 except for the one question. There's a lot of logic repeated from the namespace ACLs, but I feel like it's the right move not to try and abstract it yet. 👍
@@ -238,19 +347,19 @@ func (a *ACL) findClosestMatchingGlob(ns string) (capabilitySet, bool) { | |||
return matchingGlobs[0].capabilitySet, true | |||
} | |||
|
|||
func (a *ACL) findAllMatchingWildcards(ns string) []matchingGlob { | |||
func findAllMatchingWildcards(radix *iradix.Tree, name string) []matchingGlob { |
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.
👍 for removing the unnecessary mutability here.
This adds an initial implementation of ACLs for HostVolumes. Because HostVolumes are a cluster-wide resource, they cannot be tied to a namespace, thus here we allow similar wildcard definitions based on their names, tied to a set of capabilities. Initially, the only available capabilities are deny, or mount. These may be extended in the future to allow read-fs, mount-readonly and similar capabilities.
346a16e
to
f84365e
Compare
f84365e
to
fac0813
Compare
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!
I'm going to lock this pull request because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active contributions. |
This adds an initial implementation of ACLs for HostVolumes.
Because HostVolumes are a cluster-wide resource, they cannot be tied to
a namespace, thus here we allow similar wildcard definitions based on
their names, tied to a set of capabilities.
Initially, the only available capabilities are deny, or mount. These
will be extended to allow read-fs, mount-readonly and
similar capabilities.