Commit Graph

54 Commits

Author SHA1 Message Date
Dan Winship
75242fce7a kubelet: allow specifying dual-stack node IPs on bare metal
Discussion is ongoing about how to best handle dual-stack with clouds
and autodetected IPs, but there is at least agreement that people on
bare metal ought to be able to specify two explicit IPs on dual-stack
hosts, so allow that.
2020-10-07 17:25:54 -04:00
Dan Winship
2680095414 kubelet: Remove unnecessary sorting in NodeAddress tests
Several of the tests in TestNodeAddress() were no-ops because the test
code was only testing that NodeAddresses() returned all of the
expected addresses, but not testing that it was returning them in the
correct order.

The order that NodeAddresses() returns addresses in is very important,
so fix the tests to actually test it.

One existing test ("NodeIP is external") had its expectedAddresses in
the wrong order, but it seems clear from the name of the test that
this isn't actually what it expected.

Also, previously testKubeletHostname was "127.0.0.1" which ended up
interacting weirdly with the IPv4-vs-IPv6 sorting code in a way that
made some of the test results confusing if you didn't realize that
testKubeletHostname was an IPv4 address. Fix that by making it an
actual hostname instead, which then preserves the expected sorting.
2020-10-07 17:25:25 -04:00
Kubernetes Prow Robot
cdbd07f64e Merge pull request #90282 from gaurav1086/kubelet_nodestatus_remove_check
[kubelet] nodestatus: remove map nil check
2020-05-21 22:42:38 -07:00
Davanum Srinivas
07d88617e5 Run hack/update-vendor.sh
Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2020-05-16 07:54:33 -04:00
Davanum Srinivas
442a69c3bd switch over k/k to use klog v2
Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2020-05-16 07:54:27 -04:00
Gaurav Singh
5ed70c66e8 [kubelet] nodestatus: remove slice nil check 2020-04-19 11:16:21 -04:00
Andrew Sy Kim
e2bc3a755f move well-known kubelet cloud provider annotations to k8s.io/cloud-provider (#88631)
* move well-known kubelet cloud provider annotations to k8s.io/cloud-provider

Signed-off-by: andrewsykim <kim.andrewsy@gmail.com>

* cloud provider: rename AnnotationProvidedIPAddr to AnnotationAlphaProvidedIPAddr to indicate alpha status

Signed-off-by: Andrew Sy Kim <kim.andrewsy@gmail.com>
2020-03-31 23:01:27 -07:00
Haowei Cai
462b75388f let image cache do sort on write instead of on read to avoid data
race and improve efficienty
2020-03-10 15:33:34 -07:00
Dan Winship
ce68edf700 Allow "kubelet --node-ip ::" to mean prefer IPv6 2020-01-07 07:53:21 -05:00
Kubernetes Prow Robot
0599ca2bcf Merge pull request #81594 from jfbai/remove-duplicated-log
Remove duplicated log.
2019-10-11 19:38:38 -07:00
Han Kang
866ea74326 remove pkg/version and some of redundant copies of it
Change-Id: Ia58367c1b1274bfb49c8a4784051463abaf795de
2019-09-16 16:24:35 -07:00
David Zhu
f15cc60957 Update golang scientific notation using hack/update-gofmt.sh 2019-09-12 18:05:49 -07:00
Jianfei Bai
aa173c834f Remove duplicated log. 2019-08-23 10:09:24 +08:00
Kubernetes Prow Robot
a3488b4cee Merge pull request #81206 from tallclair/staticcheck-kubelet-push
Cleanup Kubelet static analysis issues
2019-08-22 15:09:43 -07:00
Kubernetes Prow Robot
6b47754740 Merge pull request #81627 from tallclair/copy
Delete duplicate resource.Quantity.Copy()
2019-08-22 11:13:13 -07:00
Kubernetes Prow Robot
ebf15029da Merge pull request #80003 from wongma7/cloudprovider-authoritative-hostname
Fix cloud reported hostname being overridden if nodeIP set
2019-08-21 20:50:32 -07:00
Matthew Wong
fc28045220 Fix cloud reported hostname being overridden if nodeIP set 2019-08-21 19:07:12 -07:00
Tim Allclair
8a495cb5e4 Clean up error messages (ST1005) 2019-08-21 10:40:21 -07:00
Tim Allclair
49f50484b8 Delete duplicate resource.Quantity.Copy() 2019-08-19 17:23:14 -07:00
Kubernetes Prow Robot
e8559f7565 Merge pull request #75229 from andrewsykim/kubelet-node-address-external
kubelet: lookup node address for external provider if none is set
2019-08-01 08:16:16 -07:00
Pingan2017
e94d7b3802 clean up redundant conditiontype OutOfDisk 2019-07-03 14:34:52 +08:00
Andrew Sy Kim
0d8861114d kubelet: lookup node address for external provider if none is set
Signed-off-by: Andrew Sy Kim <kiman@vmware.com>
2019-05-17 11:06:38 -04:00
Mike Crute
7d62316f8f Migrate fake cloud provider to staging 2019-05-14 13:32:18 -07:00
David Zhu
34d9ee5b9b Add CSINode initialization for CSIMigration on node startup before pod ready 2019-03-07 14:47:38 -08: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
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
68909b5683 Merge pull request #70784 from gaorong/typo-fix
fix some typos
2019-01-10 17:08:43 -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
gaorong
545aca3d18 fix some typos 2019-01-08 12:46:05 +08:00
Di Xu
e1a854b839 remove stale OutOfDisk condition from kubelet side 2019-01-06 21:37:52 +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
Kashif Saadat
8974b4f00b Don't log a warning to override hostname if there's no change. 2018-11-29 11:41:43 +00: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
Dan Winship
863c6ca241 Fix a CloudProvider-vs-nodeIP edge case 2018-11-08 10:34:00 -05:00
changyaowei
3f422d9784 if ephemeral-storage not exist in initialCapacity, don't upgrade ephemeral-storage in node status 2018-11-05 17:32:34 +08:00
Pingan2017
36997bae77 remove OutOfDisk condition in kubelet 2018-10-23 11:01:26 +08:00
k8s-ci-robot
0f17e9ade6 Merge pull request #69386 from cblecker/go-1.11
Update to go1.11.1
2018-10-05 17:35:51 -07:00
Christoph Blecker
97b2992dc1 Update gofmt for go1.11 2018-10-05 12:59:38 -07:00
Walter Fender
f3f46d5f5a Moving the cloudprovider interface to staging.
Individual implementations are not yet being moved.
Fixed all dependencies which call the interface.
Fixed golint exceptions to reflect the move.
Added project info as per @dims and
https://github.com/kubernetes/kubernetes-template-project.
Added dims to the security contacts.
Fixed minor issues.
Added missing template files.
Copied ControllerClientBuilder interface to cp.
This allows us to break the only dependency on K8s/K8s.
Added TODO to ControllerClientBuilder.
Fixed GoDeps.
Factored in feedback from JustinSB.
2018-10-04 14:41:20 -07:00
Jordan Liggitt
2857de73ce Honor --hostname-override, report compatible hostname addresses with cloud provider 2018-08-28 11:21:01 -04:00
Michael Taufen
0170826542 port setVolumeLimits to Setter abstraction, add test 2018-07-16 09:09:48 -07:00
Michael Taufen
c5a5e21639 port setNodeStatusGoRuntime to Setter abstraction 2018-07-16 09:09:48 -07:00
Michael Taufen
8e217f7102 port setNodeStatusImages to Setter abstraction, add test 2018-07-16 09:09:47 -07:00
Michael Taufen
b7ec333f01 port setNodeStatusDaemonEndpoints to Setter abstraction 2018-07-16 09:09:47 -07:00
Michael Taufen
59bb21051e port setNodeStatusVersionInfo to Setter abstraction, add test 2018-07-16 09:09:47 -07:00
Michael Taufen
596fa89af0 port setNodeStatusMachineInfo to Setter abstraction, add test 2018-07-16 09:09:47 -07:00
Michael Taufen
2df7e1ad5c port setNodeVolumesInUseStatus to Setter abstraction, add test 2018-07-16 09:09:47 -07:00
Michael Taufen
3e03e0611e port setNodeReadyCondition to Setter abstraction, add test 2018-07-16 09:09:47 -07:00
Michael Taufen
e0b6ae219f port setNodePIDPressureCondition to Setter abstraction, add test 2018-07-16 09:09:47 -07:00
Michael Taufen
b26e4dfa7f port setNodeDiskPressureCondition to Setter abstraction, add test 2018-07-16 09:09:47 -07:00