-
Notifications
You must be signed in to change notification settings - Fork 31
cgroup v1 and v2 kernel config check according to isCgroupV2 #52
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
Conversation
/cc @neolit123 @KentaTada |
@pacoxu: GitHub didn't allow me to request PR reviews from the following users: KentaTada. Note that only kubernetes members and repo collaborators can review this PR, and authors cannot review their own PRs. In response to this:
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-sigs/prow repository. |
0444abf
to
ca845c3
Compare
a0481d6
to
c917173
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.
thanks for the PR @pacoxu
given we are adding new fields it means we cannot backport the fix to older SV releases...(according to the k8s backport rules at least...)
this solution can be backported but it's less ideal i guess
#51 (comment)
up to you to decide what is better here.
} | ||
|
||
// getUnifiedMountpoint is a no-op for non-Linux OSes. | ||
func getUnifiedMountpoint(path string) (string, bool, error) { |
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.
hm, how did this compile before?
weren't we supposed to get an error if this function was missing on non-Linux?
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.
getUnifiedMountpoint
is implemented in linux only and was only used in that linux go as well.
However, we want to use it in validators/kernel_validator.go
in this PR.
- Adding new
validators/kernel_validator_linux.go
andvalidators/kernel_validator_other.go
is too complex. So I added this here.
c917173
to
c01f039
Compare
c01f039
to
54f9a6c
Compare
54f9a6c
to
de2c2ab
Compare
de2c2ab
to
74c6be0
Compare
|
||
var _ Validator = &CgroupsValidator{} | ||
|
||
const mountsFilePath = "" |
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.
this is not needed? the definition of mountsFilePath is only required in the linux file, as far as i can tell.
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.
never mind, it's referenced in validators/kernel_validator.go
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
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: neolit123, pacoxu The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Fixes #51
cc @Priyankasaggu11929