Commit Graph

7151 Commits (4034cad2693cfc3f8e72eba094419b27e9c0c6b2)

Author SHA1 Message Date
Sandor Szücs fd0cff9c77
fix #73264 cpuPeriod was not reset, but used as it is if alpha gate is disabled
Signed-off-by: Sandor Szücs <sandor.szuecs@zalando.de>
2019-02-01 16:45:43 +01:00
Kubernetes Prow Robot c0457488b6
Merge pull request #63901 from weipeng1213/branch-3
fix typo: writeable->writable
2019-02-01 07:44:26 -08:00
Kubernetes Prow Robot 91d2bd3951
Merge pull request #73306 from Pingan2017/args-type-statusmanager
correct the type in status_manager.go
2019-01-31 16:05:44 -08:00
Kubernetes Prow Robot 7b7f18c6c8
Merge pull request #70978 from Pingan2017/gracePeriod
correct log output when specifed delete gracePeriod < minimumGracePer…
2019-01-31 16:05:33 -08:00
Kubernetes Prow Robot a5ade16abd
Merge pull request #73603 from sjenning/fix-kubelet-test
TestCreatePodSandbox_RuntimeClass should not expect RunPodSandbox when runtime class is not found
2019-01-31 14:10:30 -08:00
Joe Julian e9f1700512
bug: fix segfault when EnableServiceLinks is nil
When upgrading to 1.13, pods that were created prior to the upgrade have
no pod.Spec.EnableServiceLinks set. This causes a segfault and prevents
the pod from ever starting.

Check and set to the default if nil.

Fixes #71749
2019-01-31 11:07:32 -08:00
Seth Jennings 6b51d48c4f TestCreatePodSandbox_RuntimeClass should not expect RunPodSandbox when runtime class is not found 2019-01-31 12:55:56 -06:00
danielqsj cf1fb8a1cd fix format issue 2019-01-31 22:01:13 +08:00
Daniel (Shijun) Qian e72b32558c
Merge branch 'master' into keymutex 2019-01-31 20:50:57 +08:00
changyaowei c70ee4272b delete prometheus in unit testing 2019-01-31 12:18:02 +08:00
changyaowei b52afc350f when pleg channel is full, discard events and record how many events discard 2019-01-30 20:43:54 +08:00
danielqsj 657a1a1a34 change import alias of utils/strings 2019-01-30 10:44:09 +08:00
danielqsj 093328e57f migrate to k8s.io/utils/strings 2019-01-30 10:24:00 +08:00
Andrew Kim 84191eb99b replace pkg/util/file with k8s.io/utils/path 2019-01-29 15:20:13 -05:00
Mike Danese bf99565fbb fallback to previously collected addresses if a sync loop fails 2019-01-29 11:05:27 -08:00
Mike Danese 33fc5b354b remove artificial sleeps that made tests passes 2019-01-29 10:34:25 -08:00
Mike Danese 9ece24c33f remove custom timeout in test that is never exercised
and misc cleanup
2019-01-29 10:34:25 -08:00
Kubernetes Prow Robot b2d2432291
Merge pull request #73234 from baltendo/master
Fix golint failures
2019-01-29 01:21:03 -08:00
Kubernetes Prow Robot cc1be28943
Merge pull request #72624 from danielqsj/clean_unmount
Cleanup callers of deprecated functions in volume/util
2019-01-28 23:06:20 -08:00
danielqsj c7a012f033 migrate the rest reference of pkg/util/exec to k8s.io/utils/exec 2019-01-29 10:55:10 +08:00
Elana Hashman 3539e89af2 Rename labels to match instrumentation guidelines
For the next release, we include both sets of labels for pods and
containers: "container_name" and "container", "pod_name" and "pod".
In future releases, the "*_name" metrics will be deprecated.
2019-01-28 12:36:20 -05:00
Tomas Smetana 45464f0349 Kubelet: Fix volumemanager test race 2019-01-28 15:05:26 +01:00
Kubernetes Prow Robot 697c2316fa
Merge pull request #70121 from feiskyer/win-net-stats3
Add network stats for Windows containers
2019-01-25 14:12:34 -08:00
Pingan2017 fddaf257af correct the type in status_manager.go 2019-01-25 14:34:11 +08:00
Andrew Kim 0bc5508aca replace client-go/util/integer with k8s.io/utils/integer 2019-01-24 15:34:21 -05:00
Tim Allclair 954f43a10d Migrate RuntimeClass E2E to typed client 2019-01-24 11:08:30 -08:00
Tim Allclair aab3523e0e Migrate RuntimeClass support to the generated typed client 2019-01-24 11:08:30 -08:00
Pengfei Ni 9cf38de44b Add network stats for Windows containers 2019-01-24 14:20:30 +08:00
Pengfei Ni f9fa1c6a38 Add network stats for windows node 2019-01-24 14:17:54 +08:00
Bernhard Altendorfer 736f35ec29 Fix golint failures 2019-01-24 00:14:25 +01:00
Kubernetes Prow Robot cb09d4d317
Merge pull request #72507 from dixudx/remove_stale_OutOfDisk
remove stale OutOfDisk condition from kubelet side
2019-01-18 19:14:04 -08:00
Kubernetes Prow Robot 76961c517e
Merge pull request #73048 from yujuhong/labels-ga
kubelet: promote OS & arch labels to GA
2019-01-18 05:17:24 -08:00
Kubernetes Prow Robot 54c4428eb4
Merge pull request #71276 from jingxu97/Oct/uncertain
Handle failed attach operation leave uncertain volume attach state
2019-01-17 22:52:57 -08:00
Kubernetes Prow Robot b1b6cb8cb4
Merge pull request #73034 from dashpole/fix_allocatable_e2e
[Text Fix] Fix panic in NodeAllocatable node e2e test
2019-01-17 17:11:59 -08:00
Yu-Ju Hong 00d93f0cc3 kubelet: promote OS & arch labels to GA
kubelet now applies both the beta and the GA labels to ensure backward
compatibility.
2019-01-17 14:57:43 -08:00
David Ashpole 2b8bc85f75 fix panic in NodeAllocatable node e2e test 2019-01-17 10:57:09 -08:00
Marek Counts 1739e343a8 autogen files
all the autogen files that got updated due to the changes to move logs.
2019-01-17 09:16:36 -05:00
Marek Counts ba81a5409a move logs into component-base
all the code changes to move move /apiserver/pkg/util/logs into /component-base/logs
2019-01-17 09:16:21 -05:00
Kubernetes Prow Robot 5d19fda5e8
Merge pull request #72844 from dashpole/fork_bomb_test
Fix PidPressure, and add fork-bomb e2e-node test
2019-01-16 15:59:01 -08:00
Kubernetes Prow Robot 5818be6205
Merge pull request #68619 from ailusazh/CleanContainersInReconcileStateOfCpuManager
clean containers in reconcileState of cpuManager
2019-01-16 11:34:04 -08:00
Kubernetes Prow Robot 56e88f5b47
Merge pull request #70805 from danwinship/cloud-node-ip
Fix a CloudProvider-vs-nodeIP edge case
2019-01-16 09:04:54 -08:00
Kubernetes Prow Robot ce19aad22b
Merge pull request #70527 from qingsenLi/git181101
remove repetitive word in annotation
2019-01-15 20:19:09 -08:00
Kubernetes Prow Robot 591ef236e0
Merge pull request #72705 from WanLinghao/cadvisor_test_improve
Improve pkg/kubelet/cadvisor package
2019-01-15 17:32:30 -08:00
danielqsj 1d73c7daed Add kubelet_node_name metrics 2019-01-15 18:01:04 +08:00
ailusazh 10995f661d clean containers in reconcileState of cpuManager 2019-01-15 16:09:28 +08:00
David Ashpole 8b440c6424 Fix PidPressure, make it evict by priority, and add fork-bomb node e2e test 2019-01-14 09:41:36 -08:00
WanLinghao ce7003262f Improve pkg/kubelet/cadvisor package:
1. Perfect unit test code
2. Clean unused function&&test file
2019-01-14 09:39:22 +08:00
Kubernetes Prow Robot dc6f3d645d
Merge pull request #72831 from yujuhong/bump-docker-version
Bump minimum docker version to 1.13.1
2019-01-11 15:54:11 -08:00
Zihong Zheng f2750dd043 Graduate CustomPodDNS feature to GA 2019-01-11 11:28:26 -08:00
Yu-Ju Hong f62cc81934 Bump minimum docker version to 1.13.1 2019-01-11 10:21:38 -08:00
Kubernetes Prow Robot d2d9a3aba4
Merge pull request #72659 from jsturtevant/fix-windows-kernal-version-output
Remove newline from kernel version on windows node
2019-01-11 08:10:26 -08:00
Kubernetes Prow Robot 0ab3972a08
Merge pull request #72791 from yujuhong/no-rkt
Remove the rkt deprecation warning
2019-01-10 17:09:04 -08:00
Kubernetes Prow Robot 68909b5683
Merge pull request #70784 from gaorong/typo-fix
fix some typos
2019-01-10 17:08:43 -08:00
Kubernetes Prow Robot b92756e85d
Merge pull request #72340 from makocchi-git/cadvisor_crisocket
kubelet: fixes cadvisor internal error
2019-01-10 14:42:30 -08:00
Yu-Ju Hong f8ab673b8f Remove the rkt deprecation warning
The feature was deprecated 1.10. Remove the warning.
2019-01-10 13:27:23 -08:00
Kubernetes Prow Robot a6d7527ac3
Merge pull request #72280 from verb/kubelet-no-containertype
Remove container type from kubelet runtime labels
2019-01-10 01:18:41 -08:00
Kubernetes Prow Robot 0dbc99719a
Merge pull request #72076 from derekwaynecarr/pid-limiting
SupportPodPidsLimit feature beta with tests
2019-01-10 01:18:30 -08:00
Kubernetes Prow Robot d88994cf9f
Merge pull request #71306 from ping035627/k8s-181121
fix some typos
2019-01-09 09:06:31 -08:00
Derek Carr bce9d5f204 SupportPodPidsLimit feature beta with tests 2019-01-09 10:50:59 -05:00
Jeff Grafton 11f248fd35 Remove deprecated automanaged tag from some go rules 2019-01-08 14:40:57 -08:00
Kubernetes Prow Robot a1e46a9d43
Merge pull request #71560 from appvia/hostname-change-noop
Don't log a warning to override hostname if there's no change.
2019-01-08 13:41:42 -08:00
danielqsj 8092904e3c Cleanup PathExists callers 2019-01-08 22:16:11 +08:00
danielqsj 7aef2efe5b Mark deprecated in related dockershim metrics 2019-01-08 15:24:44 +08:00
gaorong 545aca3d18 fix some typos 2019-01-08 12:46:05 +08:00
Kubernetes Prow Robot 998167767f
Merge pull request #71764 from linxiulei/fix_cri_pullimage
Pass PodSandboxConfig to PullImage method in CRI
2019-01-07 15:24:48 -08:00
James Sturtevant c6777f9009 Remove newline from kernal version on windows node 2019-01-07 21:20:26 +00:00
Di Xu e1a854b839 remove stale OutOfDisk condition from kubelet side 2019-01-06 21:37:52 +08:00
Kubernetes Prow Robot 89efdb4173
Merge pull request #71889 from WanLinghao/function_clean_kubelet
Clean unused function in pkg/kubelet/kubelet.go
2019-01-02 23:35:38 -08:00
Kubernetes Prow Robot d582682b7f
Merge pull request #72312 from Pingan2017/correct-ready-condition
correctly update pod ready condition
2019-01-02 16:51:50 -08:00
Kubernetes Prow Robot e76322eab4
Merge pull request #70826 from kolyshkin/shareable-ipc-sandbox
Use shareable IPC for sandbox container
2018-12-31 21:18:23 -08:00
Kubernetes Prow Robot 710b87617c
Merge pull request #71797 from SenXuDC/SenXuDC-patch-1
fix typo replacee -> replace
2018-12-31 07:19:12 -08:00
Kubernetes Prow Robot 68451f301b
Merge pull request #72291 from msau42/fix-subpath-orphan
Fix subpath issues with orphaned pod cleanup
2018-12-26 19:48:27 -08:00
Michelle Au 8724b46623 Check for volume-subpaths directory in orpahaned pod cleanup 2018-12-26 10:49:28 -08:00
makocchi-git 4fe1b6f33f
Add "unix://" prefix for CrioSocket 2018-12-26 23:08:41 +09:00
danielqsj 65aec219c8 Move docker metrics to histogram metrics 2018-12-26 16:00:38 +08:00
danielqsj 94d1050303 Change docker metrics to conform guideline 2018-12-26 15:58:04 +08:00
Pingan2017 1148ecfaf6 correctly update pod ready condition 2018-12-25 09:36:37 +08:00
Lee Verberne f6084f7eab Remove container type from kubelet runtime labels
We've changed the Ephemeral Containers API, and container type will no
longer be required. Since this is the only feature using it, remove it.

This reverts commit ba6f31a6c6.
2018-12-21 15:47:47 +01:00
wangqingcan b82a1d4600 Move predicate types from algorithm to predicates 2018-12-21 22:26:47 +08:00
Kubernetes Prow Robot ea6acb34d1
Merge pull request #65132 from stewart-yu/stewart-removeunusedtodo
remove unuse todo
2018-12-19 06:51:29 -08:00
Kubernetes Prow Robot cd02e752bf
Merge pull request #71509 from cofyc/fix71438
Fix device mountable volume names in DSW
2018-12-19 00:51:52 -08:00
Dan Williams 2e339188ed OWNERS: add label:sig/network to a bunch of places 2018-12-19 00:00:02 -06:00
Kubernetes Prow Robot 5554a446a9
Merge pull request #65632 from cofyc/vendor
Vendor github.com/prometheus/client_golang/prometheus/testutil package
2018-12-18 21:27:38 -08:00
Kubernetes Prow Robot f039076116
Merge pull request #72135 from tallclair/rc-logs
Surface selected pod RuntimeHandler in Kubelet logs
2018-12-18 19:10:25 -08:00
Kubernetes Prow Robot 4e8bea4bb7
Merge pull request #71194 from yanghaichao12/dev1119-1
Fix comment error of 'cpuManagerStateFileName'
2018-12-17 20:28:19 -08:00
Tim Allclair e27f7ef151 Surface selected pod RuntimeHandler in Kubelet logs 2018-12-17 16:36:47 -08:00
Kubernetes Prow Robot 2791fb7dc5
Merge pull request #72067 from dashpole/pod_start_time
Use Pod.Status.StartTime as pod's cgroup start time in summary API
2018-12-14 15:47:01 -08:00
David Ashpole 70a7fdda02 use Pod.Status.StartTime as pod's cgroup start time in summary API 2018-12-14 14:26:55 -08:00
Kubernetes Prow Robot 61ed586bb9
Merge pull request #71297 from Pingan2017/event-kill-container
correct the event msg of kill container
2018-12-13 18:18:58 -08:00
Kubernetes Prow Robot ed73acdc98
Merge pull request #71029 from yanghaichao12/dev1114
Fix comment error of the struct 'UserDefinedMetric'
2018-12-12 17:18:54 -08:00
Yecheng Fu 67552a8f6e Add unit test to verify generated volume names. 2018-12-12 13:03:21 +08:00
yuexiao-wang 7b6f60f085 modify BUILD
Signed-off-by: yuexiao-wang <wang.yuexiao@zte.com.cn>
2018-12-11 11:22:06 +08:00
yuexiao-wang f3353c358d [scheduler cleanup phase 2]: Rename to
Signed-off-by: yuexiao-wang <wang.yuexiao@zte.com.cn>
2018-12-11 11:21:12 +08:00
WanLinghao ea456bb365 Clean unused function in pkg/kubelet/kublet.go 2018-12-09 14:30:36 +08:00
Eric Lin 5e2ed11cf7 Pass PodSandboxConfig to PullImage method in CRI
Fix #71745
2018-12-07 10:10:22 +08:00
SenXuDC 48c715515e
Update fsstore.go 2018-12-06 23:01:52 +08:00
Kubernetes Prow Robot 1bafa3922f
Merge pull request #71687 from WanLinghao/cadvisor_comment_remove
Update a comment in cadvisor boot function
2018-12-05 20:31:41 -08:00
David Ashpole 54e581930c fix node and kubelet start times 2018-12-05 15:07:52 -08:00
Kubernetes Prow Robot 33a37702a6
Merge pull request #64280 from dashpole/eviction_pod_metrics
Use memory metrics from the pod cgroup for eviction ranking
2018-12-04 08:26:03 -08:00
Kubernetes Prow Robot 6cea9266dc
Merge pull request #71116 from xichengliudui/fix18111602
Fix typo: trus->true
2018-12-03 21:27:08 -08:00
WanLinghao 08a4ee006e Update a comment in cadvisor boot function 2018-12-04 11:29:58 +08:00
Kubernetes Prow Robot c7598e8844
Merge pull request #71617 from RobertKrawitz/branch-issue71614
Issue 71614: Protect log message maps
2018-12-03 14:03:38 -08:00
Kubernetes Prow Robot dc9261bc3b
Merge pull request #71174 from smarterclayton/debug_kubeadm
Restore bootstrap in the background with fix to preserve kubeadm behavior
2018-12-03 05:49:57 -08:00
houjun 5c6eb3a153 Fix an error in comment 2018-12-03 11:35:07 +08:00
Yecheng Fu ccb66066a9 vendor github.com/prometheus/client_golang/prometheus/testutil package 2018-12-02 10:25:50 +08:00
Yecheng Fu 5ada29ac16 Rename GetUniqueVolumeNameForNonAttachableVolume to GetUniqueVolumeNameFromSpecWithPod 2018-12-01 12:25:32 +08:00
Yecheng Fu f5642bbe88 Fix device mountable volume names in DSW 2018-12-01 12:25:14 +08:00
Robert Krawitz bc091be66a Issue 71614: Protect log message maps 2018-11-30 18:04:08 -05:00
k8s-ci-robot 96516bd961
Merge pull request #71263 from ZYecho/fix-spellings
fix typo: namspace -> namespace
2018-11-30 06:33:50 -08:00
k8s-ci-robot 79e5cb2cb7
Merge pull request #71302 from liggitt/verify-unit-test-feature-gates
Split mutable and read-only access to feature gates, limit tests to readonly access
2018-11-29 21:45:12 -08:00
k8s-ci-robot af6bf1e436
Merge pull request #70645 from changyaowei/node_ephemeral-storage
Fix bug: when kubelet restart, the ephemeral-storage in node status upgrade to 0
2018-11-29 21:44:53 -08:00
stewart-yu 5f11d089b7 remove unused todo in kubelet_pods.go 2018-11-30 12:51:46 +08:00
k8s-ci-robot 409bfc4337
Merge pull request #71047 from pivotal-k8s/bump-k8s-utils
Bump k8s.io/uitls to 8e7ff06
2018-11-29 11:17:08 -08:00
Kashif Saadat 8974b4f00b Don't log a warning to override hostname if there's no change. 2018-11-29 11:41:43 +00:00
k8s-ci-robot 7ae97bcd0b
Merge pull request #66308 from RobertKrawitz/bug-1581483
Reduce logspam for crash looping containers
2018-11-29 02:00:54 -08:00
k8s-ci-robot e5326f22ea
Merge pull request #70471 from xichengliudui/fix181031
Fix some typos
2018-11-29 00:48:16 -08:00
k8s-ci-robot d0ac922996
Merge pull request #70440 from nikhita/add-license-headers
Add license header to non-generated proto files
2018-11-29 00:48:05 -08:00
Kir Kolyshkin 1dca64fffd Use shareable IPC for sandbox container
Currently, Docker make IPC of every container shareable by default,
which means other containers can join it's IPC namespace. This is
implemented by creating a tmpfs mount on the host, and then
bind-mounting it to a container's /dev/shm. Other containers
that want to share the same IPC (and the same /dev/shm) can also
bind-mount the very same host's mount.

Now, since https://github.com/moby/moby/commit/7120976d7
(https://github.com/moby/moby/pull/34087) there is a possiblity
to have per-daemon default of having "private" IPC mode,
meaning all the containers created will have non-shareable
/dev/shm.

For shared IPC to work in the above scenario, we need to
explicitly make the "pause" container's IPC mode as "shareable",
which is what this commit does.

To test: add "default-ipc-mode: private" to /etc/docker/daemon.json,
try using kube as usual, there should be no errors.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2018-11-28 11:11:10 -08:00
Robert Krawitz 3373fcf0fc Reduce logspam for crash looping containers 2018-11-28 10:48:52 -05:00
Vladimir Vivien e86bdc7989 Forces fsnotify CREATE and REMOVE to occur serially 2018-11-26 22:11:47 -05:00
k8s-ci-robot 205eaee0e5
Merge pull request #71145 from gnufied/test-mounted-detach
Fix volume detach while mount in progress
2018-11-22 23:27:48 -08:00
k8s-ci-robot 12e5eb7dc9
Merge pull request #71011 from sigma/pr/fix-inotify
replace golang.org/x/exp/inotify with standalone library
2018-11-22 18:07:51 -08:00
saad-ali a7c5582bba Permit use of deprecated dir in device plugin. 2018-11-21 18:37:31 -08:00
saad-ali 8f666d9e41 Modify kubelet watcher to support old versions
Modify kubelet plugin watcher to support older CSI drivers that use an
the old plugins directory for socket registration.
Also modify CSI plugin registration to support multiple versions of CSI
registering with the same name.
2018-11-21 18:37:31 -08:00
PingWang 9d541911bb fix some typos
Signed-off-by: PingWang <wang.ping5@zte.com.cn>

fix typo

Signed-off-by: PingWang <wang.ping5@zte.com.cn>
2018-11-22 08:27:14 +08:00
Jordan Liggitt 2498ca7606 drop VerifyFeatureGatesUnchanged 2018-11-21 11:51:33 -05:00
Jordan Liggitt 70ad4dff48 Fix unit tests calling SetFeatureGateDuringTest incorrectly 2018-11-21 11:51:33 -05:00
Jordan Liggitt 4dca07ef7e Fixup incorrect use of DefaultFeatureGate.Set in tests 2018-11-21 11:51:33 -05:00
Pingan2017 75d9a7bebd correct the event msg of kill container 2018-11-21 10:59:21 +08:00
Hemant Kumar d2b6e30143 Fix bug with volume getting marked as not in-use with pending op
Add test for verifying volume detach
2018-11-20 11:58:47 -05:00
zhangyue 596a20ca8a fix typo: namspace -> namespace
Signed-off-by: zhangyue <zy675793960@yeah.net>
2018-11-20 21:47:27 +08:00
Jing Xu 562d0fea53 Handle failed attach operation leave uncertain volume attach state
This commit adds the unit tests for the PR. It also includes some files
that are affected by the function name changes.
2018-11-19 17:21:49 -08:00
yanghaichao12 982d1778f8 Fix comment error of 'cpuManagerStateFileName' 2018-11-19 08:07:04 -05:00
Clayton Coleman fde87329cb
bootstrap: Use kubeconfig contents as seed for cert dir if necessary
kubeadm uses certificate rotation to replace the initial high-power
cert provided in --kubeconfig with a less powerful certificate on
the masters. This requires that we pass the contents of the client
config certData and keyData down into the cert store to populate
the initial client.

Add better comments to describe why the flow is required. Add a test
that verifies initial cert contents are written to disk. Change
the cert manager to not use MustRegister for prometheus so that
it can be tested.
2018-11-17 19:52:12 -05:00
Clayton Coleman 486577df17 Restore "Make bootstrap client cert loading part of rotation""
This reverts the revert of commit 3464222267.
2018-11-17 13:44:58 -05:00
Clayton Coleman 3464222267
Revert "Make bootstrap client cert loading part of rotation"
This reverts commit 0af19875ad.

Revert "Ensure the bootstrap rotation code is tested by forcing rotation"

This reverts commit de293b2d7d.
2018-11-17 10:24:39 -05:00
k8s-ci-robot e3420cc46f
Merge pull request #70494 from RenaudWasTaken/pluginwatcher
Ignore non socket files in the kubelet plugin watcher
2018-11-16 22:46:42 -08:00
k8s-ci-robot 3be3510814
Merge pull request #69890 from smarterclayton/bootstrap_retry
Make bootstrap client cert loading part of rotation
2018-11-16 22:46:33 -08:00
k8s-ci-robot ec2e767e59
Merge pull request #71167 from msau42/block-beta
Promote raw block volume support to beta
2018-11-16 20:28:03 -08:00
k8s-ci-robot df8ad8eae1
Merge pull request #71166 from Random-Liu/fix-kubelet-panic
Fix kubelet panic.
2018-11-16 20:27:53 -08:00
Clayton Coleman de293b2d7d
Ensure the bootstrap rotation code is tested by forcing rotation
Expose both a Stop() method (for cleanup) and a method to force
cert rotation, but only expose Stop() on the interface.

Verify that we choose the correct client.
2018-11-16 21:50:52 -05:00
Clayton Coleman 0af19875ad
Make bootstrap client cert loading part of rotation
Ensure that bootstrap+clientcert-rotation in the Kubelet can:

1. happen in the background so that static pods aren't blocked by bootstrap
2. collapse down to a single call path for requesting a CSR
3. reorganize the code to allow future flexibility in retrieving bootstrap creds

Fetching the first certificate and later certificates when the kubelet
is using client rotation and bootstrapping should share the same code
path. We also want to start the Kubelet static pod loop before
bootstrapping completes. Finally, we want to take an incremental step
towards improving how the bootstrap credentials are loaded from disk
(potentially allowing for a CLI call to get credentials, or a remote
plugin that better integrates with cloud providers or KSMs).

Reorganize how the kubelet client config is determined. If rotation is
off, simplify the code path. If rotation is on, load the config
from disk, and then pass that into the cert manager. The cert manager
creates a client each time it tries to request a new cert.

Preserve existing behavior where:

1. bootstrap kubeconfig is used if the current kubeconfig is invalid/expired
2. we create the kubeconfig file based on the bootstrap kubeconfig, pointing to
   the location that new client certs will be placed
3. the newest client cert is used once it has been loaded
2018-11-16 21:50:26 -05:00
k8s-ci-robot f877b2257a
Merge pull request #71074 from jsafrane/volume-manager-races
Fix race between MountVolume and UnmountDevice
2018-11-16 18:22:14 -08:00
Renaud Gaubert 1a3fbf1f13 Update e2e tests to include CSI 2018-11-17 01:52:57 +01:00
Renaud Gaubert 229418f261 Update pluginwatcher to ignore CSI metadata dir and non socket files 2018-11-17 01:51:00 +01:00
Lantao Liu 59e80cdac3 Fix kubelet panic.
Signed-off-by: Lantao Liu <lantaol@google.com>
2018-11-16 16:21:57 -08:00
Matthew Wong dd517c9ff2 Update all tests to account for BlockVolume enabled by default 2018-11-16 13:38:59 -05:00
Jordan Liggitt 733dd9dfd7 Add tests to ensure feature gate changes don't escape kubelet/scheduler packages 2018-11-16 10:52:53 -05:00
Jordan Liggitt de8bf9b63d fix scheduler and kubelet unit tests leaking feature flag changes 2018-11-16 10:52:53 -05:00
Jordan Liggitt 248d661327 Add tests to ensure storage feature gate changes don't escape packages 2018-11-16 10:52:53 -05:00
Michelle Au fd64c08240 Fix storage feature gate test setting 2018-11-16 10:49:40 -05:00
k8s-ci-robot 92fe9d9491
Merge pull request #71081 from vladimirvivien/kubelet-plugin-watcher-ga-fix
Kubelet Plugin Registration GA migration fix
2018-11-16 05:13:18 -08:00
Jan Safranek 5283537401 Fixed clearing of devicePath after UnmountDevice
UnmountDevice must not clear devicepath, because such devicePath
may come from node.status (e.g. on AWS) and subsequent MountDevice
operation (that may be already enqueued) needs it.
2018-11-16 13:24:42 +01:00
chendt.fnst c76a34bd25 Fix typos.
**What type of PR is this?**
/kind cleanup

**What this PR does / why we need it**:
Fix typos for stats_provider_test.go

**Which issue(s) this PR fixes** *(optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged)*:

**Special notes for your reviewer**:

**Release note**:
```
NONE
```
2018-11-16 17:03:11 +08:00
k8s-ci-robot e4ee887121
Merge pull request #69303 from appian/host_aliases_on_same_line
Write HostAliases aliases on same line per host IP
2018-11-15 14:59:52 -08:00
Vladimir Vivien b195396154 Kubelet Plugin Registration v1 update fix 2018-11-15 17:40:35 -05:00
k8s-ci-robot 7b4d4bc8ac
Merge pull request #70508 from dashpole/pod_resources_socket
Add socket-based kubelet pod resources API.
2018-11-15 13:43:44 -08:00
k8s-ci-robot 504466c4e6
Merge pull request #68267 from liggitt/node-label-update
Limit kubelets from updating their own labels when NodeRestriction is enabled
2018-11-15 11:11:02 -08:00
David Ashpole 630cb53f82 add kubelet grpc server for pod-resources service 2018-11-15 09:43:20 -08:00
David Ashpole aa9ba976ac generate go client for kubelet podresources API 2018-11-15 09:38:59 -08:00
David Ashpole 3ece501f6b add kubelet pod-resources API definition 2018-11-15 09:38:59 -08:00
Hannes Hörl 0d4b5c98f8 Bump k8s.io/uitls to 8e7ff06
The reason for the bump is the new functionality of the
k8s.io/utils/exec package which allows
- to get a hold of the process' std{out,err} as `io.Reader`s
- to `Start` a process and `Wait` for it

This should help on addressing #70890 by allowing to wrap std{out,err}
of the process to be wrapped with a `io.limitedReader`.

It also updates
- k8s.io/kubernetes/pkg/probe/exec.FakeCmd
- k8s.io/kubernetes/pkg/kubelet/prober.execInContainer
- k8s.io/kubernetes/cmd/kubeadm/app/phases/kubelet.fakeCmd
to implement the changed interface.

The dependency on 'k8s.io/utils/pointer' to the new version has also
been bumped in some staging repos:
- apiserver
- kube-controller-manager
- kube-scheduler
2018-11-15 13:25:12 +00:00
xichengliudui 68f9dacabf Fix typo: trus->true 2018-11-15 01:36:15 -05:00
k8s-ci-robot 843a67b215
Merge pull request #70559 from vladimirvivien/kubelet-plugin-watcher-ga
Graduate Kubelet plugin registration/watcher to GA
2018-11-14 20:35:08 -08:00
k8s-ci-robot 68fb529ec1
Merge pull request #70969 from awly/node-csr-move
Move csr.RequestNodeCertificate into kubelet bootstrap package
2018-11-14 11:37:58 -08:00
yanghaichao12 529d5a5c50 Fix comment error of the struct 'UserDefinedMetric' 2018-11-14 11:05:06 -05:00
Vladimir Vivien f16d3c56f6 Kubelet plugin watcher update to v1 2018-11-14 05:46:27 -05:00
Vladimir Vivien 668c532dda Pluginregistration package updat to v1 2018-11-14 05:46:19 -05:00
Jordan Liggitt 9fb2dcad5e Limit kubelets from updating their own labels 2018-11-13 23:48:47 -05:00
k8s-ci-robot d3a21cf5a2
Merge pull request #70848 from cofyc/fix64590
Improve usability of CSI plugin metrics
2018-11-13 19:45:43 -08:00
Yann Hodique 4d9c01d747 replace golang.org/x/exp/inotify with standalone library
The inotify code was removed from golang.org/x/exp several years ago. Therefore
importing it from that path prevents downstream consumers from using any module
that makes use of more recent features of golang.org/x/exp.

This change is a followup to google/cadvisor#2060 which was merged with #70889

This fixes #68478
2018-11-13 14:51:40 -08:00
Andrew Lytvynov 5c073abfe1 Move csr.RequestNodeCertificate into kubelet bootstrap package
This func is only used by the kubelet and there's no need to pollute
client-go API with it.
2018-11-13 10:27:51 -08:00
Pingan2017 fae9bae1aa correct log output when specifed delete gracePeriod < minimumGracePeriodInSeconds 2018-11-13 15:20:24 +08:00
Frederic Branczyk 4724fca678
pkg/kubelet/stats: Add container log size metric 2018-11-12 22:04:50 +01:00
yanghaichao12 70c418035f correct some spelling wrong in DevicePlugin files 2018-11-12 04:44:51 -05:00
liucimin 5b78dc8b67 fix_the_checkpoint_no_hostip_bug 2018-11-12 14:41:04 +08:00
Bill Warshaw ab507dfc1f Write HostAliases aliases on same line per host IP
* change HostAliases to put all aliases for an IP
  on the same line in /etc/hosts rather than writing
  one line per IP-alias pair
* having multiple entries in /etc/hosts for the same IP
  causes issues with DNS resolution for some software
* https://unix.stackexchange.com/questions/102660/hosts-file-is-it-incorrect-to-have-the-same-ip-address-on-multiple-lines
2018-11-11 20:54:52 -05:00
Yecheng Fu dfe0a08f05 Improve usability of CSI plugin metrics
Use full qualified plugin name if volume spec is present.
2018-11-12 09:21:49 +08:00
Davanum Srinivas e558e291d1
s/glog/klog/ - keep up with master
Change-Id: I27ff0545bc456ed8c0900cfeb90555f9ab7ae235
2018-11-10 07:57:01 -05:00
Davanum Srinivas 954996e231
Move from glog to klog
- Move from the old github.com/golang/glog to k8s.io/klog
- klog as explicit InitFlags() so we add them as necessary
- we update the other repositories that we vendor that made a similar
change from glog to klog
  * github.com/kubernetes/repo-infra
  * k8s.io/gengo/
  * k8s.io/kube-openapi/
  * github.com/google/cadvisor
- Entirely remove all references to glog
- Fix some tests by explicit InitFlags in their init() methods

Change-Id: I92db545ff36fcec83afe98f550c9e630098b3135
2018-11-10 07:50:31 -05:00
k8s-ci-robot be71fbe511
Merge pull request #70034 from wangzhen127/cleanup-node-lease
Delete node lease if the corresponding node is deleted
2018-11-09 23:01:05 -08:00
k8s-ci-robot bb4fbc2770
Merge pull request #70821 from RenaudWasTaken/fix-pluginwatcher-panic
Pluginwatcher: Fix panic on failed startup
2018-11-09 20:25:41 -08:00
Michael Taufen 1089cb629f Don't compare interface values in dynamic config controller
This previously caused a panic when moving lastKnownGood between two
non-nil values, because we were comparing the interface wrapper instead
of comparing the NodeConfigSources. The case of moving from one non-nil
lastKnownGood config to another doesn't appear to be tested by the e2e
node tests. I added a unit test and an e2e node test to help catch bugs
with this case in the future.
2018-11-09 10:45:12 -08:00
Renaud Gaubert 11fef8ba3b Pluginwatcher should prevent kubelet from starting if we cannot watch the plugin root 2018-11-09 00:20:22 +00:00
Renaud Gaubert 3a467ff44b Pluginwatcher: log error when walking fs rather than fail 2018-11-08 23:22:07 +00:00
Renaud Gaubert 3f5039a2d1 Fix pluginwatcher panic on failed startup 2018-11-08 23:22:07 +00:00
Dan Winship 863c6ca241 Fix a CloudProvider-vs-nodeIP edge case 2018-11-08 10:34:00 -05:00
Zhen Wang b8b12796fc Delete node lease if the corresponding node is deleted 2018-11-07 20:31:47 -08:00
k8s-ci-robot 16d0992534
Merge pull request #69753 from wangzhen127/diff-node-status
Update kubelet node status report logic with node lease feature
2018-11-07 20:26:45 -08:00
Zhen Wang 98fc4a107a Update kubelet node status report logic with node lease feature
When node lease feature is enabled, kubelet reports node status to api server
only if there is some change or it didn't report over last report interval.
2018-11-07 11:59:42 -08:00
k8s-ci-robot f1bf9bef5c
Merge pull request #70678 from dashpole/fix_cgroup_manager
Fix slice sharing bug in cgroup manager
2018-11-07 11:36:41 -08:00
k8s-ci-robot 0aba557741
Merge pull request #70600 from liggitt/sig-auth-subprojects
Add owners/approvers aliases for sig-auth subprojects
2018-11-06 17:55:07 -08:00
Christian Haeusler 9e8df0f82a Be more persistent when removing images 2018-11-06 17:01:51 +01:00
Christian Haeusler 5f904044eb Use test table for TestRemoveImage 2018-11-06 14:37:52 +01:00
Christian Haeusler 8f266af060 Assert call details in docker remove image tests 2018-11-06 14:32:39 +01:00
k8s-ci-robot f40a5d1155
Merge pull request #67435 from feiskyer/dns-cap
Add dns capabilities for Windows CNI plugins
2018-11-06 02:54:22 -08:00
Jordan Liggitt 360a890c58 serviceaccount subproject approvers/reviewers 2018-11-06 00:57:39 -05:00
Jordan Liggitt 4ebe084376 certificates subproject approvers/reviewers 2018-11-06 00:57:38 -05:00
k8s-ci-robot 160ebd3af2
Merge pull request #70162 from MIBc/commenting-error
Replace resyncTicker with syncTicker in comment
2018-11-05 19:04:25 -08:00
David Ashpole d4f6ae3615 fix slice sharing bug in cgroup manager 2018-11-05 17:42:42 -08:00