-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Implement extra-config for kubeadm components #1985
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1985 +/- ##
==========================================
- Coverage 29.69% 28.59% -1.11%
==========================================
Files 77 80 +3
Lines 4842 5243 +401
==========================================
+ Hits 1438 1499 +61
- Misses 3218 3551 +333
- Partials 186 193 +7
Continue to review full report at Codecov.
|
func NewKubeletConfig(k8s bootstrapper.KubernetesConfig) (string, error) { | ||
flags := []string{} | ||
for _, opt := range k8s.ExtraOptions { | ||
if opt.Component == "kubelet" { |
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.
maybe make "kubelet" a constant if it's not already one?
} | ||
} | ||
// Strip leading 'v' prefix from version for semver parsing | ||
fmt.Println(k8s.KubernetesVersion) |
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.
drop the println?
} | ||
|
||
// versions >= 1.8.0-alpha.0 require the --fail-swap-on flag set to false | ||
if version.GTE(version18) { |
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.
yuck, is this because or ISO has swap on? Should we just turn it off?
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.
Going forward this might be more maintainable if we have a map of special cased flags to versions, but this should be OK for now. Maybe just leave a TODO about that.
fe194a6
to
312bec6
Compare
Updated with:
|
312bec6
to
a139ccd
Compare
LGTM |
These were all the changes needed to make
minikube start --kubernetes-version=v1.8.0-beta.0 --bootstrapper=kubeadm
work.The kubelet now will respect the extra config options set by minikube's
--extra-config
flags.