Skip to content
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

Switch to using kubelet config file for all supported flags #10433

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

brandond
Copy link
Contributor

@brandond brandond commented Jun 29, 2024

Proposed Changes

Switch to using kubelet config file for all supported flags

Types of Changes

enhancement / tech debt

Verification

See linked issue

Testing

Linked Issues

User-Facing Change

Further Comments

Currently using a hacky string replace when marshaling the config file to work around an upstream issue:

@brandond brandond requested a review from a team as a code owner June 29, 2024 07:52
@brandond brandond force-pushed the kubelet-config-dir branch 3 times, most recently from c6f443b to 5b85991 Compare June 30, 2024 08:00
Copy link

codecov bot commented Jun 30, 2024

Codecov Report

Attention: Patch coverage is 60.73620% with 64 lines in your changes missing coverage. Please review.

Project coverage is 41.74%. Comparing base (3ced503) to head (ce0e400).
Report is 385 commits behind head on master.

Files Patch % Lines
pkg/daemons/agent/agent.go 67.46% 30 Missing and 11 partials ⚠️
pkg/daemons/agent/agent_linux.go 45.83% 11 Missing and 2 partials ⚠️
pkg/agent/util/file.go 0.00% 8 Missing ⚠️
pkg/agent/config/config.go 50.00% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master   #10433      +/-   ##
==========================================
- Coverage   43.03%   41.74%   -1.29%     
==========================================
  Files         163      177      +14     
  Lines       16534    14931    -1603     
==========================================
- Hits         7115     6233     -882     
+ Misses       8158     7510     -648     
+ Partials     1261     1188      -73     
Flag Coverage Δ
e2etests 36.66% <60.73%> (-9.59%) ⬇️
inttests 19.79% <1.84%> (?)
unittests 11.26% <0.00%> (-4.55%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

manuelbuil
manuelbuil previously approved these changes Jul 1, 2024
Makes logged output more consistent when k3s fails during initialization

Signed-off-by: Brad Davidson <[email protected]>
Expose actual error, so that we can tell if the deployment is not found or not ready/available

Signed-off-by: Brad Davidson <[email protected]>
// and a structured configuration file that upstream does not provide a convienent way to initailize with default values.
// The defaults and our desired config also vary by OS.
func kubeletArgsAndConfig(cfg *config.Agent) (map[string]string, *kubeletconfig.KubeletConfiguration, error) {
defaultConfig, err := defaultKubeletConfig(cfg)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this going to work on Windows? Won't stuff like the cgroup driver fail/be unnecessary on this OS?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah I'm honestly not sure what the windows kubelet does if you try to set the cgroup stuff. I'll try this out in RKE2 before merging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants