Commit Graph

7 Commits (70e340b045dacb1102561f923d11a7fc72755e22)

Author SHA1 Message Date
deads2k c2ae6d5b40 remove api to util dependency hiding types 2017-01-25 08:28:28 -05:00
Dr. Stefan Schimanski 82826ec273 pkg/util/flag: move to k8s.io/apiserver 2017-01-24 20:56:03 +01:00
Dr. Stefan Schimanski 56d60cfae6 pkg/util: move flags from pkg/util/config to pkg/util/flags 2017-01-24 20:56:03 +01:00
Michael Taufen f277205f4f Kubelet Refactoring
This refactor removes the legacy KubeletConfig object and adds a new
KubeletDeps object, which contains injected runtime objects and
separates them from static config. It also reduces NewMainKubelet to two
arguments: a KubeletConfiguration and a KubeletDeps.

Some mesos and kubemark code was affected by this change, and has been
modified accordingly.

And a few final notes:

KubeletDeps:
KubeletDeps will be a temporary bin for things we might consider
"injected dependencies", until we have a better dependency injection
story for the Kubelet. We will have to discuss this eventually.

RunOnce:
We will likely not pull new KubeletConfiguration from the API server
when in runonce mode, so it doesn't make sense to make this something
that can be configured centrally. We will leave it as a flag-only option
for now. Additionally, it is increasingly looking like nobody actually uses the
Kubelet's runonce mode anymore, so it may be a candidate for deprecation
and removal.
2016-08-25 10:57:31 -07:00
David McMahon ef0c9f0c5b Remove "All rights reserved" from all the headers. 2016-06-29 17:47:36 -07:00
Derek Parker f307e97f87 kubelet: Add --exit-on-lock-contention flag
This patch adds the --exit-on-lock-contention flag, which must be used
in conjunction with the --lock-file flag. When provided, it causes the
kubelet to wait for inotify events for that lock file. When an 'open'
event is received, the kubelet will exit.
2016-05-18 16:21:47 -07:00
Jan Chaloupka 106c5f0b08 Introduce unit test for checking resource quantities for kubelet's allocatable resources.
Covered values:
- negative quantity value: error expected
- invalid quantity unit: error expected
- valid quantity: error not expected

Running go test with -v, returned error are logged as well for more information:

=== RUN   TestValueOfAllocatableResources
--- PASS: TestValueOfAllocatableResources (0.00s)
	server_test.go:47: negative quantity value: resource quantity for \"memory\" cannot be negative: -150G
	server_test.go:47: invalid quantity unit: unable to parse quantity's suffix
PASS
ok  	k8s.io/kubernetes/cmd/kubelet/app	0.020s
2016-03-30 19:58:21 +02:00