Commit Graph

62075 Commits (a195a761515da1bb927a5b1f679309351d1324c9)

Author SHA1 Message Date
Kubernetes Submit Queue 01517e530f
Merge pull request #59887 from dims/process-cloud-nodes-in-ccm-before-creating-shared-informer-handler
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Process existing cloud nodes in CCM

**What this PR does / why we need it**:

This is a timing issue. If kubelet(s) get started before the CCM is
started, the shared informer event handler does not process them at
all. So we should loop through these before. We run this in a
go wait.Until loop to tolerate errors when listing the nodes and
giving an opportunity for any scripts that may need to setup RBAC
roles etc.


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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-02-15 12:17:26 -08:00
Khaled Henidak(Kal) 38a9fc33db code review: create err chan via helper 2018-02-15 20:11:40 +00:00
Mike Danese b973840481 gke-certificates-controller: rm -rf 2018-02-15 12:01:00 -08:00
Davanum Srinivas 84d171fe86 Avoid call to get cloud instances
if a node does not have the taint, we really don't need to make calls
to get the list of instances from the cloud provider
2018-02-15 14:50:25 -05:00
Brendan Burns 352722b1e7 Add some more tests for routes. 2018-02-15 11:37:39 -08:00
Chao Xu 9cfd20ef1c enable mutating and validating admission webhook by default on gce and centos
clusters setup by kube/cluster-up.sh
2018-02-15 11:19:53 -08:00
Kubernetes Submit Queue c03edcc58e
Merge pull request #53833 from mtaufen/kubeletconfig-to-beta
Automatic merge from submit-queue (batch tested with PRs 59353, 59905, 53833). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Graduate kubeletconfig API group to beta

Regarding https://github.com/kubernetes/features/issues/281, this PR moves the kubeletconfig API group to beta. 

After #53088, the KubeletConfiguration type should not contain any deprecated or experimental fields, and we should not have to remove any more fields from the type before graduating it to beta. 

We need the community to double check for two things, however:
1. Are there any fields currently in the KubeletConfiguration type that you were going to mark deprecated this quarter, but haven't yet?
2. Are there any fields currently in the KubeletConfiguration type that are experimental or alpha, but were not explicitly denoted as such?

Please comment on this PR if you can answer "yes" to either of those two questions. Please cc anyone with a stake in the kubeletconfig API, so we get as much coverage as possible.

/cc @thockin @dchen1107 @Random-Liu @yujuhong @dashpole @tallclair @vishh @abw @freehan @dnardo @bowei @MrHohn @luxas @liggitt @ncdc @derekwaynecarr @mikedanese 

@kubernetes/sig-network-pr-reviews, @kubernetes/sig-node-pr-reviews 

```release-note
action required: The `kubeletconfig` API group has graduated from alpha to beta, and the name has changed to `kubelet.config.k8s.io`. Please use `kubelet.config.k8s.io/v1beta1`, as `kubeletconfig/v1alpha1` is no longer available. 
```

**TODO:**
- [x] Move experimental/non-gated-alpha/soon-to-be-deprecated fields to `KubeletFlags`
  - [x] #53088
  - [x] #54154
  - [x] #54160
  - [x] #55562
  - [x] #55983
  - [x] #57851
- [x] Lift embedded structure out of strings
  - [x] #53025
  - [x] #54643
  - [x] #54823
  - [x] #55254
- [x] Resolve relative paths against the location config files are loaded from
  - [x] #55648 
- [x] Rename to `kubelet.config.k8s.io`
- [x] Comments
  - [x] Make sure existing comments at least read sensibly.
  - [x] Note default values in comments on the versioned struct.
  - [x] Remove any reference to default values in comments on the internal struct.
- [x] Most fields should be `+optional` and `omitempty`. Add where necessary. ~Where omitted, explicitly comment.~ Edit: We should not distinguish between nil and empty, see below items.
- [x] Ensure defaults are specified via `pkg/kubelet/apis/kubelet.config.k8s.io/v1beta1/defaults.go`, not `cmd/kubelet/app/options/options.go`.
  - [x] #57770
- [x] Ensure kubeadm does not persist v1alpha1 KubeletConfiguration objects (or feature-gates this functionality)
- [x] Don't make a distinction between empty and nil, because of #43203.
  - [x] #59515
  - [x] #59681
- [x] Take the opportunity to fix insecure Kubelet defaults @tallclair 
  - [x] #59666
- [x] Remove CAdvisorPort from KubeletConfiguration wrt #56523.
  - [x] #59580
- [x] Hide `ConfigTrialDuration` until we're more sure what to do with it.
   - [x] #59628
- [x] Fix `// default: x` comments after rebasing on recent changes.
2018-02-15 11:06:40 -08:00
Kubernetes Submit Queue b099e91920
Merge pull request #59905 from mtaufen/dkcfg-config-ok-kubelet-config-ok
Automatic merge from submit-queue (batch tested with PRs 59353, 59905, 53833). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Rename ConfigOK to KubeletConfigOk

This is a more accurate name for the condition, as it describes the
status of the Kubelet's configuration.

Also cleans up capitalization of internal names.

```release-note
The ConfigOK node condition has been renamed to KubeletConfigOk.
```
2018-02-15 11:06:36 -08:00
Zihong Zheng d8f5eafd86 Add a reviewer to addon-manager 2018-02-15 10:40:02 -08:00
Kubernetes Submit Queue bb500a73b6
Merge pull request #59353 from juanvallejo/jvallejo/update-name-printer-output
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

update name printer output to kind.group/name

**Release note**:
```release-note
NONE
```

Followup to https://github.com/kubernetes/kubernetes/pull/59227

Updates output via `-o name` to be pipeable.

cc @deads2k
2018-02-15 10:37:19 -08:00
Kubernetes Submit Queue 27daaab224
Merge pull request #59323 from zetaab/nodetaint
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

add node shutdown taint

**What this PR does / why we need it**: we need node stopped taint in order to detach volumes immediately without waiting timeout. More info in issue ticket #58635 

**Which issue(s) this PR fixes** 
Fixes #58635

**Special notes for your reviewer**:

**Release note**:
```release-note
NONE
```
2018-02-15 09:52:10 -08:00
Jan Safranek 746d1dd99d Enable mount propagation tests by default
MountPropagation is enabled by default now, so should be the test.
2018-02-15 18:12:54 +01:00
Kubernetes Submit Queue 9a8b675d2c
Merge pull request #59630 from k82cn/k8s_59194_0
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Task 0: Added Alpha flag for NoDaemonSetScheduler feature.

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

**Release note**:
```release-note
None
```
2018-02-15 09:10:58 -08:00
Steve Sloka dc03cc0035 Update build deps for Bazel and zz_generated 2018-02-15 12:05:29 -05:00
Steve Sloka 2fd29a0406 Add configuration item to allow kubeadm join to use a dns name pointing to control plane 2018-02-15 12:03:32 -05:00
Kubernetes Submit Queue 8a67b71ac6
Merge pull request #59921 from x13n/fluentd-version-bump
Automatic merge from submit-queue (batch tested with PRs 56394, 59921). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

fix fluentd-gcp-scaler to look at correct fluentd-gcp version

**What this PR does / why we need it**:

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/assign @crassirostris
2018-02-15 08:54:31 -08:00
Khaled Henidak(Kal) 53036bf755 Code review + resync VMSS changes 2018-02-15 16:49:47 +00:00
Kubernetes Submit Queue 7e8de5422c
Merge pull request #56394 from porridge/fetch-token-retry-longer
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Try longer to fetch initial token.

**What this PR does / why we need it**:
Step towards fixing #56293

**Special notes for your reviewer**:
/kind bug
/priority critial-urgent
@kubernetes/sig-scalability-bugs
/cc @shyamjvs please add to v1.9

**Release note**:
```release-note
NONE
```
2018-02-15 08:31:03 -08:00
Jan Safranek e260096392 Rework volume manager log levels
- all normal logs to go to level 4
- too frequent / duplicate logs go to level 5 (e.g. when something else logged similar message not too far away).
2018-02-15 16:33:17 +01:00
juanvallejo 765f9ec68b
update -o name format to kind.group/name 2018-02-15 10:33:06 -05:00
Kubernetes Submit Queue d336607679
Merge pull request #59871 from wojtek-t/cache_fields_and_labels
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Store labels and fields with object

We are already computing labels and fields before putting objects in watchcache.
And my tests show this is `PodToSelectableFields` is responsible for ~10% of memory allocations.
This PR is supposed to fix that - let's double check by running kubemark-big on it.
2018-02-15 07:20:51 -08:00
Daniel Kłobuszewski 6db742fc10 fix fluentd-gcp-scaler to look at correct fluentd-gcp version 2018-02-15 16:15:41 +01:00
Konstantinos Tsakalozos e2399de900 Clean-up not needed method. 2018-02-15 17:01:52 +02:00
Beata Skiba 329feee0e9 Fix cluster autoscaler test to support regional clusters. 2018-02-15 15:57:49 +01:00
Wojciech Tyczynski 87a65b6c93 Store labels and fields with object 2018-02-15 14:56:33 +01:00
Kubernetes Submit Queue d3dc4584f9
Merge pull request #59899 from mikedanese/authz
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

apiserver: fix some typos from refactor

introduced in #59582

```release-note
NONE
```
2018-02-15 04:36:39 -08:00
Kubernetes Submit Queue d3bacb914c
Merge pull request #59657 from x13n/manual-fluentd-gcp-scaler
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Enable scaling fluentd-gcp resources using ScalingPolicy.

See https://github.com/justinsb/scaler for more details about ScalingPolicy resource.

**What this PR does / why we need it**:
This is adding a way to override fluentd-gcp resources in a running cluster. The resources syncing for fluentd-gcp is decoupled from addon manager.

**Special notes for your reviewer**:

**Release note**:
```release-note
fluentd-gcp resources can be modified via a ScalingPolicy
```

cc @kawych @justinsb
2018-02-15 03:42:14 -08:00
Ilias Tsitsimpis 6590c3fe35 csi: Remove stale volume path
The CSI mounter creates the following paths during SetUp():

   * .../pods/<podID>/volumes/kubernetes.io~csi/<specVolId>/mount/
   * .../pods/<podID>/volumes/kubernetes.io~csi/<specVolId>/volume_data.json

During TearDown(), it does not remove the `.../kubernetes.io~csi/<specVolId>/`
directory, leaving behind orphan volumes: method cleanupOrphanedPodDirs()
complains with 'Orphaned pod found, but volume paths are still present
on disk'.

Fix that by removing the above directory in removeMountDir().

Signed-off-by: Ilias Tsitsimpis <iliastsi@arrikto.com>
2018-02-15 13:30:36 +02:00
Davanum Srinivas c423be11d5 Process existing cloud nodes in CCM
Existing nodes are sent via update and not via the add function,
so let's add an UpdateCloudNode and just forward it to the
AddCloudNode. This works fine as all we do is look for the cloud
taint and bail out if it is not present.
2018-02-15 06:29:48 -05:00
Marcin Owsiany 3a5d48700c Try longer to fetch initial token. 2018-02-15 10:57:35 +01:00
Kubernetes Submit Queue 7377c5911a
Merge pull request #59892 from JulienBalestra/revert-host-ip
Automatic merge from submit-queue (batch tested with PRs 59877, 59886, 59892). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

kubelet: revert the status HostIP behavior

**What this PR does / why we need it**:

This PR partially revert #57106 to fix #59889.

The PR #57106 changed the behavior of `generateAPIPodStatus` when a **kubeClient** is nil.

**Release note**:
```release-note
NONE
```
2018-02-15 00:01:35 -08:00
Kubernetes Submit Queue be5a9d34a2
Merge pull request #59886 from cblecker/fix-codegen
Automatic merge from submit-queue (batch tested with PRs 59877, 59886, 59892). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Partial revert of #59797

**What this PR does / why we need it**:
Need to do a partial revert of #59797. This PR introduced two problems:
- `INTERNAL_DIRS` has an unbound variable error
- The script introduces the use of mapfile which doesn't exist in bash versions prior to bash 4.x. Darwin (OS X) uses bash 3.x by default.

**Release note**:
```release-note
NONE
```
2018-02-15 00:01:33 -08:00
Kubernetes Submit Queue 4efa72da60
Merge pull request #59877 from dims/standardize-on-kube-proxy-mode-param
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Standardize on KUBE_PROXY_MODE (not KUBEPROXY_MODE)

**What this PR does / why we need it**:

There's a disconnect between 12d4eac038
and the earlier a6af827898. One says
KUBEPROXY_MODE and another says KUBE_PROXY_MODE. Let's just pick one.
Currently we fail with the following error:

hack/local-up-cluster.sh: line 808: KUBEPROXY_MODE: unbound variable

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-02-14 23:31:23 -08:00
Kubernetes Submit Queue 4b147e0361
Merge pull request #59588 from jiayingz/v1beta1
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Create pkg/kubelet/apis/deviceplugin/v1beta1 directory.

The proto stays the same as v1alpha. Only changes Version in
constants.go to "v1beta1" and the BUILD file to pick up the new dir.

```release-note
Adding pkg/kubelet/apis/deviceplugin/v1beta1 API.
```
2018-02-14 22:51:32 -08:00
Kubernetes Submit Queue a8060ab0a1
Merge pull request #59646 from mlmhl/fix_volume_metrics_e2e
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Add bound/unbound pv/pvc volume metrics

**What this PR does / why we need it**:

Fix two bugs in bound/unbound pv/pvc volumes metric e2e test:

1. Check `HasRegisteredMaster` in `BeforeEach` instead of each tests because we will grab the metrics in `BeforeEach`

2. Fix `calculateRelativeValues` bug, if there are other PV/PVC exist in the cluster, `calculateRelativeValues` will return a map like `map[string]int64{"some-storage-class-name": 0}`, this will lead to test failure. We should skip these unchanged numbers.

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

**Release note**:

```release-note
NONE
```

/sig storage
2018-02-14 22:10:45 -08:00
Kubernetes Submit Queue 00070b5490
Merge pull request #59872 from vmware/remove-production-code-usage-in-e2e-tests
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Fixing diskIsAttached function

**What this PR does / why we need it**:
This PR fixes the `diskIsAttached` function. 
When disk is detached from the Node, this function was returning true, which results into time out for some vsphere e2e test cases.

**Which issue(s) this PR fixes**
Fixes #

**Special notes for your reviewer**:
Executed E2E test to verify failures are resolved with this change.

**Release note**:

```release-note
NONE
```
2018-02-14 21:34:22 -08:00
Kubernetes Submit Queue 4949b63e0a
Merge pull request #59335 from resouer/equiv-vol
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Fixes volume predicate handler for equiv class

**What this PR does / why we need it**:

Per discussion in #58797 , we are missing some predicate handler in factory.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)*:
Fixes #58797

Ref #58222

**Special notes for your reviewer**:

Kindly ping @msau42

**Release note**:

```release-note
Fixes volume predicate handler for equiv class
```
2018-02-14 20:57:08 -08:00
Kubernetes Submit Queue 571158e869
Merge pull request #59852 from cblecker/etcd-fix
Automatic merge from submit-queue (batch tested with PRs 59878, 59852). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Check if netstat or iproute2 is available

**What this PR does / why we need it**:
In https://github.com/kubernetes/kubernetes/pull/59655, I incorrectly assumed that the kubetest image would have net-tools. It doesn't. This checks and uses `ss` from iproute2, *or* `netstat` from net-tools. The kubetest image does appear to have iproute2.

**Release note**:
```release-note
NONE
```
2018-02-14 20:14:29 -08:00
Michael Taufen d8cc440dd6 Rename ConfigOK to KubeletConfigOk
This is a more accurate name for the condition, as it describes the
status of the Kubelet's configuration.

Also cleans up capitalization of internal names.
2018-02-14 19:36:52 -08:00
Kubernetes Submit Queue d38e2234b7
Merge pull request #59878 from humblec/error-string
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Correct error strings and variable name.
2018-02-14 19:30:06 -08:00
Davanum Srinivas 692f2ec305 Standardize on KUBE_PROXY_MODE (not KUBEPROXY_MODE)
There's a disconnect between 12d4eac038
and the earlier a6af827898. One says
KUBEPROXY_MODE and another says KUBE_PROXY_MODE. Let's just pick one.
Currently we fail with the following error:

hack/local-up-cluster.sh: line 808: KUBEPROXY_MODE: unbound variable
2018-02-14 21:26:54 -05:00
Mike Danese 83c1334e51 apiserver: fix some typos from refactor
introduced in #59582
2018-02-14 17:47:45 -08:00
Michael Taufen 9ebaf5e7d2 Move the kubeletconfig v1alpha1 API to beta, rename to kubelet.config.k8s.io 2018-02-14 17:30:22 -08:00
JulienBalestra 2130f5bc55 kubelet: revert the status HostIP behavior 2018-02-14 23:38:09 +01:00
Kubernetes Submit Queue 6535c955bf
Merge pull request #59440 from vmware/rohitj-upstream
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Use SetInformers method to register for Node events. (#449)

Till 1.9.2 Kubernetes release vSphere Cloud Provider needs a separate service account which is not needed.

**What this PR does / why we need it**: 
In this fix, vSphere CLoud Provider is now implementing SetInformer API to get the required NodeInformer. With this change vSphere Cloud Provider no more requires separate service account for listening NodeEvents.

**Which issue(s) this PR fixes** 
Fixes #58747

**Special notes for your reviewer**:
VMware vSphere Cloud Provide internal change

**Release note**:
```release-note
With this fix, separate service account is not needed for vSphere Cloud Provider for listening node events.
```
2018-02-14 13:46:48 -08:00
caleb miles c007efcceb Kubernetes version v1.11.0-alpha.0 openapi-spec file updates 2018-02-14 16:07:30 -05:00
Divyen Patel 7699a76914 trivial change to fix test issue 2018-02-14 12:41:49 -08:00
Kai Chen 9ca0d32fbb Improve comments for kubelet 2018-02-14 12:03:46 -08:00
Christoph Blecker 57ca909d60
Partial revert of fb5caac2da 2018-02-14 11:31:51 -08:00
Kubernetes Submit Queue f33e0b33f4
Merge pull request #56717 from roycaihw/dynamic_subresource
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Dynamic client supports subresources

**What this PR does / why we need it**:
Allows `resource.name` to be a subresource which contains `"/"` in db2977fb11/staging/src/k8s.io/client-go/dynamic/client.go (L143)

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

**Special notes for your reviewer**:
The change is backward compatible. 

**Release note**:

```release-note
NONE
```

/sig api-machinery
2018-02-14 11:14:43 -08:00