Commit Graph

52876 Commits (577fdf91c2f6b6699eb14fca258e62a620399e7a)

Author SHA1 Message Date
Kubernetes Submit Queue e0089bcf8f Merge pull request #49885 from dashpole/ignore_udp
Automatic merge from submit-queue (batch tested with PRs 49885, 49751, 49441, 49952, 49945)

Ignore UDP metrics in kubelet

Updating cadvisor godeps to 0.26.0 for the 1.7 release (#46658) added udp metrics.  However, they were not disabled in the kubelet.
This PR disables collection of UDP metrics in the kubelet.
This should be cherrypicked to the 1.7 branch.

cc @dchen1107
2017-08-07 12:56:05 -07:00
Robert Rati 926f070719 Make ClusterID required for AWS. #48954 2017-08-07 15:47:00 -04:00
Jun Xiang Tee 91f100b501 implement statefulset scale subresource 2017-08-07 12:17:46 -07:00
jianhuiz 746444e43a add fed job e2e test 2017-08-07 11:36:45 -07:00
jianhuiz 4dcdfd4aa8 add job controller 2017-08-07 11:36:45 -07:00
Kubernetes Submit Queue 02d04de81e Merge pull request #49914 from yguo0905/shared-pid-ns
Automatic merge from submit-queue (batch tested with PRs 50087, 39587, 50042, 50241, 49914)

Add node e2e test for Docker's shared PID namespace

Ref: https://github.com/kubernetes/kubernetes/issues/42926

This PR adds a simple test for the shared PID namespace that's enabled when Docker is 1.13.1+.

/sig node
/area node-e2e
/assign @yujuhong 

**Release note**:
```
None
```
2017-08-07 10:59:04 -07:00
Kubernetes Submit Queue 8c22b11ce7 Merge pull request #50241 from jamiehannaford/kubeadm-ha-flags
Automatic merge from submit-queue (batch tested with PRs 50087, 39587, 50042, 50241, 49914)

Enable selfHosted feature flag

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

Enables feature gating for self-hosting on kubeadm

**Which issue this PR fixes**

Continuation of https://github.com/kubernetes/kubeadm/issues/323

**Release note**:
```release-note
Feature gates now determine whether a cluster is self-hosted. For more information, see the FeatureGates configuration flag.
```

/cc @luxas
2017-08-07 10:59:01 -07:00
Kubernetes Submit Queue d6cb4827bf Merge pull request #50042 from jingxu97/Aug/cinderfix
Automatic merge from submit-queue (batch tested with PRs 50087, 39587, 50042, 50241, 49914)

AttachDisk should not call detach inside of Cinder volume provider
2017-08-07 10:58:59 -07:00
Kubernetes Submit Queue 59b8fa32f1 Merge pull request #39587 from zhouhaibing089/openstack-auth-provider
Automatic merge from submit-queue (batch tested with PRs 50087, 39587, 50042, 50241, 49914)

plugin/pkg/client/auth: add openstack auth provider

This is an implementation of auth provider for OpenStack world, just like python-openstackclient, we read the environment variables of a list `OS_*`, and client will cache a token to interact with each components, we can do the same here, the client side can cache a token locally at the first time, and rotate automatically when it expires.

This requires an implementation of token authenticator at server side, refer:

1.  [made by me] https://github.com/kubernetes/kubernetes/pull/25536, I can carry this on when it is fine to go.
2.  [made by @kfox1111] https://github.com/kubernetes/kubernetes/pull/25391

The reason why I want to add this is due to the `client-side` nature, it will be confusing to implement it downstream, we would like to add this support here, and customers can get `kubectl` like they usually do(`brew install kubernetes-cli`), and it will just work.

When this is done, we can deprecate the password keystone authenticator as the following reasons:

1.  as mentioned at some other places, the `domain` is another parameters which should be provided.
2.  in case the user supplies `apikey` and `secrets`, we might want to fill the `UserInfo` with the real name which is not implemented for now.

cc @erictune @liggitt 

```
add openstack auth provider
```
2017-08-07 10:58:57 -07:00
Kubernetes Submit Queue 47999c5803 Merge pull request #50087 from deads2k/server-39-convert
Automatic merge from submit-queue (batch tested with PRs 50087, 39587, 50042, 50241, 49914)

convert default predicates to use the default

Builds on https://github.com/kubernetes/kubernetes/pull/50019 (lgtm'd already)

This converts the already default field selectors to use the default value.  I'll let CI point out the unit test failures for me to chase.

@kubernetes/sig-api-machinery-misc
2017-08-07 10:58:55 -07:00
David Eads 47d426c441 provide the failing health as part of the controller error 2017-08-07 12:55:29 -04:00
Solly Ross 17eb58131a Handle missing OpenAPI specs on aggregated servers
Previously, the aggregator would fail to actually set up the aggregator
proxy for an API server that was missing an OpenAPI spec.  It would show
up in discovery, but the actual proxying would fail to occur.

Now, we simply log an error if we can't fetch an OpenAPI spec for a
particular aggregated server, and continue on.
2017-08-07 11:04:41 -04:00
Beata Skiba 2f747f3d3c Add a simple cloud provider for e2e tests on kubemark
This is needed for cluster autoscaler e2e test to
run on kubemark. We need the ability to add and
remove nodes and operate on nodegroups. Kubemark
does not provide this at the moment.
2017-08-07 16:31:02 +02:00
Kubernetes Submit Queue fddc7f3e50 Merge pull request #50243 from mborsz/node
Automatic merge from submit-queue (batch tested with PRs 50091, 50231, 50238, 50236, 50243)

Fix storage tests for multizone test configuration.

**What this PR does / why we need it**:
This PR modifies "[sig-storage] Volumes PD should be mountable with (ext3|ext4)" tests to schedule pods in zone, where PD is created.
This is to make the test work in multizone environment.

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

**Special notes for your reviewer**:

**Release note**:
```release-note
```
2017-08-07 07:15:00 -07:00
Kubernetes Submit Queue 2d5729e227 Merge pull request #50236 from crassirostris/sig-instrumentation-e2e-last-move
Automatic merge from submit-queue (batch tested with PRs 50091, 50231, 50238, 50236, 50243)

Move the sig-instrumentation test to a dedicated folder

Move the last remaining test to sig-instrumentation folder, also move "metrics" package to the "framework" folder

Related issue: https://github.com/kubernetes/kubernetes/issues/49161

/cc @xiangpengzhao @piosz
2017-08-07 07:14:58 -07:00
Kubernetes Submit Queue 969ae1ebee Merge pull request #50238 from mborsz/managed
Automatic merge from submit-queue (batch tested with PRs 50091, 50231, 50238, 50236, 50243)

Modify e2e.go to arbitrarily pick one of zones we have nodes in for multizone tests.

**What this PR does / why we need it**:
When e2e runs in multizone configuration, zone config property can be empty.
This PR, in that case, overrides an empty value with arbitrarily chosen zone that we have nodes in.

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

**Special notes for your reviewer**:

**Release note**:
```release-note
```
2017-08-07 07:14:56 -07:00
Kubernetes Submit Queue 5cbb73d616 Merge pull request #50231 from crassirostris/sd-logging-e2e-soak-fix
Automatic merge from submit-queue (batch tested with PRs 50091, 50231, 50238, 50236, 50243)

Fix Stackdriver Logging soak tests issues

It mostly addressed occasional panics and too verbose logs about ingestion

Fixes https://github.com/kubernetes/kubernetes/issues/50237

/cc @piosz @x13n
2017-08-07 07:14:54 -07:00
Kubernetes Submit Queue 0df3f0ef3e Merge pull request #50091 from dixudx/fieldSelector_podIP
Automatic merge from submit-queue (batch tested with PRs 50091, 50231, 50238, 50236, 50243)

add fieldSelector podIP

**What this PR does / why we need it**:
Currently the `fieldSelector` for `Pod` only support `metadata.name`, `metadata.namespace`, `spec.nodeName`, `spec.restartPolicy` and `status.phase`.

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

**Special notes for your reviewer**:
/cc @wojtek-t @caesarxuchao @justinsb @LiliC

**Release note**:

```release-note
add fieldSelector podIP
```
2017-08-07 07:14:52 -07:00
Jamie Hannaford 173bc31c25 Enable selfHosted feature flag 2017-08-07 15:20:34 +02:00
deads2k ec397c4374 convert default predicates to use the default 2017-08-07 09:05:17 -04:00
Kubernetes Submit Queue dbc81febc1 Merge pull request #50184 from jinzhejz/jinzhejz_typo
Automatic merge from submit-queue

fix typo in replenishment_controller.go

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

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #N/A

**Release note**:
```release-note
None
```
2017-08-07 05:52:19 -07:00
FengyunPan 53742560cd There is no need to split service key repeatedly 2017-08-07 20:18:20 +08:00
Klaus Ma 2ebd743be8 Added toleration for node condition taints. 2017-08-07 19:53:40 +08:00
Klaus Ma 18ae1ba813 Handled taints on node in batch. 2017-08-07 19:29:39 +08:00
Kubernetes Submit Queue 654de23cbf Merge pull request #50145 from gmarek/micro-equality
Automatic merge from submit-queue (batch tested with PRs 49868, 50143, 49377, 50141, 50145)

Add MicroTime to DeepEquals overrides
2017-08-07 04:05:02 -07:00
Kubernetes Submit Queue 7deb3b29cd Merge pull request #50141 from gmarek/verify
Automatic merge from submit-queue (batch tested with PRs 49868, 50143, 49377, 50141, 50145)

Don't expect internal clientset to be generated for groups without ne…

…w types
2017-08-07 04:04:59 -07:00
Kubernetes Submit Queue a0826e1d89 Merge pull request #49377 from CaoShuFeng/audit_id_http_response_header
Automatic merge from submit-queue (batch tested with PRs 49868, 50143, 49377, 50141, 50145)

Return Audit-Id http response header for trouble shooting

Users can use Audit-Id http response header to grep the audit events in log.
This provides a fast way to find the events in audit.
**Release note**:

```
Audit-Id HTTP header is included in the apiserver responses for audited requests, except some cases when it's not possible, e.g. pods/exec.
```
@sttts @tallclair
2017-08-07 04:04:57 -07:00
Kubernetes Submit Queue 293ab0f855 Merge pull request #50143 from gmarek/microtime
Automatic merge from submit-queue (batch tested with PRs 49868, 50143, 49377, 50141, 50145)

Add metav1.MicroTime to exceptions in tag tests
2017-08-07 04:04:55 -07:00
Kubernetes Submit Queue fb661268ff Merge pull request #49868 from shiywang/testlog
Automatic merge from submit-queue (batch tested with PRs 49868, 50143, 49377, 50141, 50145)

Status objects for 404 API errors will have the correct APIVersion

Fixes https://github.com/kubernetes/kubernetes/issues/48959
superseded https://github.com/kubernetes/kubernetes/pull/49183


```release-note 
Status objects for 404 API errors will have the correct APIVersion
```
2017-08-07 04:04:53 -07:00
Maciej Borsz 6d789ee640 Fix storage tests for multizone test configuration. 2017-08-07 12:15:14 +02:00
FengyunPan 48db05166a Ignore the available volume when calling DetachDisk
If use detachs the volume by nova in openstack env, volume becomes
available. If nova instance is been deleted, nova will detach it
automatically. So the "available" is fine since that means the
volume is detached from instance already.
2017-08-07 17:11:40 +08:00
Mik Vyatskov 0210c3dd77 Fix Stackdriver Logging soak tests issues 2017-08-07 10:47:27 +02:00
Kubernetes Submit Queue bc7ccfe93b Merge pull request #50106 from julia-stripe/improve-scheduler-error-handling
Automatic merge from submit-queue

Retry scheduling pods after errors more consistently in scheduler

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

This fixes 2 places in the scheduler where pods can get stuck in Pending forever.  In both these places, errors happen and `sched.config.Error` is not called afterwards. This is a problem because `sched.config.Error` is responsible for requeuing pods to retry scheduling when there are issues (see [here](2540b333b2/plugin/pkg/scheduler/factory/factory.go (L958))), so if we don't call `sched.config.Error` then the pod will never get scheduled (unless the scheduler is restarted).

One of these (where it returns when `ForgetPod` fails instead of continuing and reporting an error) is a regression from [this refactor](https://github.com/kubernetes/kubernetes/commit/ecb962e6585#diff-67f2b61521299ca8d8687b0933bbfb19L234), and with the [old behavior](80f26fa8a8/plugin/pkg/scheduler/scheduler.go (L233-L237)) the error was reported correctly. As far as I can tell changing the error handling in that refactor wasn't intentional.

When AssumePod fails there's never been an error reported but I think adding this will help the scheduler recover when something goes wrong instead of letting pods possibly never get scheduled.

This will help prevent issues like https://github.com/kubernetes/kubernetes/issues/49314 in the future.

**Release note**:

```release-note
Fix incorrect retry logic in scheduler
```
2017-08-07 01:35:17 -07:00
Mik Vyatskov e79a228a78 Move the sig-instrumentation test to a dedicated folder 2017-08-07 10:33:03 +02:00
Shiyang Wang 2eda19da7b Fix NotFound errors do not line up with API endpoint's group version 2017-08-07 16:30:40 +08:00
Maciej Borsz 7c506c6a14 Modify e2e.go to arbitrarily pick one of zones we have nodes in for
multizone tests.
2017-08-07 10:25:42 +02:00
Kubernetes Submit Queue c75d3028dd Merge pull request #50159 from liggitt/includeObject
Automatic merge from submit-queue

Fix includeObject parameter parsing

Fixes #50149
2017-08-06 22:49:09 -07:00
Kubernetes Submit Queue ae4fac416d Merge pull request #49481 from jianglingxia/jlx72417
Automatic merge from submit-queue (batch tested with PRs 49370, 49481)

continue Fix error format and info for get_test.go

**What this PR does / why we need it**:
continue fix the error info 
**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #49441 

**Special notes for your reviewer**:

**Release note**:

```release-note
    NONE
2017-08-06 08:52:56 -07:00
Kubernetes Submit Queue 979c86f3dd Merge pull request #49370 from sttts/sttts-no-clientset-embedding
Automatic merge from submit-queue (batch tested with PRs 49370, 49481)

client-gen: stop embedding of GroupVersion client intfs

It is undefined (or at least uncontrollable) which methods of the clientset apigroup
interfaces are actually inherited. Moreover, there might be nameconflicts between the
accessors and inherited methods. This PR removes the embedding to make it unambiguous.

```release-note
Enforce explicit references to API group client interfaces in clientsets to avoid ambiguity.
```
2017-08-06 08:52:54 -07:00
Kubernetes Submit Queue 702e506a69 Merge pull request #46687 from zjj2wry/delete_unuse_error
Automatic merge from submit-queue

Delete unuse err check

**What this PR does / why we need it**:
err has fatal, this err check  can't execute.

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

**Special notes for your reviewer**:
thank you ~

**Release note**:

```release-note
NONE
```
2017-08-06 07:32:11 -07:00
Dr. Stefan Schimanski 3b310d8989 Update generated code 2017-08-06 15:32:28 +02:00
Dr. Stefan Schimanski 83895daed1 Fix printer hack to get a versioned client 2017-08-06 15:30:13 +02:00
Dr. Stefan Schimanski 1910b5a1dd Fix code implicitly casting clientsets to getters 2017-08-06 15:30:13 +02:00
Dr. Stefan Schimanski 25f2b0a2c1 client-gen: stop embedding of GroupVersion client intfs 2017-08-06 15:30:13 +02:00
Mikhail Mazurskiy 32b78aebf2
Migrate to IsControlledBy from meta/v1 package 2017-08-06 22:43:46 +10:00
Mikhail Mazurskiy 042b5642b9
Migrate to NewControllerRef from meta/v1 package 2017-08-06 22:43:46 +10:00
Mikhail Mazurskiy b28a83a4cf
Migrate to GetControllerOf from meta/v1 package 2017-08-06 22:41:58 +10:00
Kubernetes Submit Queue 5490273951 Merge pull request #48553 from superbrothers/fix-kubectl-42
Automatic merge from submit-queue

Fix a bug that --flag=val causes completion error in zsh

**What this PR does / why we need it**:
This PR fixes a bug that flag of syntax like --flag=val causes completion error in zsh.

```
kubectl --namespace=foo g__handle_flag:25: bad math expression: operand expected at end of string
```

This problem is due to [dynamic scope](https://en.wikipedia.org/wiki/Scope_(computer_science)#Dynamic_scoping) of shell variables. If a variable is declared as local to a function, that scope remains until the function returns.

In kubectl completion zsh, `declare -A flaghash` in __start_kubectl() is replaced with `__kubectl_declare -A flaghash` by __kubectl_convert_bash_to_zsh(). As a result of it, flaghash is declared in __kubectl_declare(), and it can not access to flaghash declared in __kubectl_declare() from __handle_flag(). Therefore an error occurs in __handle_flag().

The following is the minimum reproduction code.

```sh
#!/usr/bin/env zsh

set -e

__kubectl_declare() {
    builtin declare "$@"
}

__handle_flag() {
    local flagname="--namespace="
    local flagval="kube-system"

    flaghash[${flagname}]=${flagval}

    echo "flaghash[${flagname}]=${flaghash[${flagname}]}"
}

__handle_word() {
    __handle_flag
}

__start_kubectl() {
    __kubectl_declare -A flaghash

    __handle_word
}

__start_kubectl

#
# $ zsh reproduction.zsh
# __handle_flag:4: bad math expression: operand expected at end of string
#

# __start_kubectl {
#
#     __kubectl_declare {
#
#         builtin declare -A flaghash
#
#     }
#
#     __handle_word {
#
#         __handle_flag {
#
#             # It is unable to access flaghash declared in __kubectl_declare from here
#             flaghash[${flagname}]=${flagval}
#
#         }
#
#     }
# }
```

The following is the fixed code.
```sh
#!/usr/bin/env zsh

set -e

__handle_flag() {
    local flagname="--namespace="
    local flagval="kube-system"

    flaghash[${flagname}]=${flagval}

    echo "flaghash[${flagname}]=${flaghash[${flagname}]}"
}

__handle_word() {
    __handle_flag
}

__start_kubectl() {
    builtin declare -A flaghash

    __handle_word
}

__start_kubectl

#
# $ zsh fixed.zsh
# flaghash[--namespace=]=kube-system
#

# __start_kubectl {
#
#     builtin declare -A flaghash
#
#     __handle_word {
#
#         __handle_flag {
#
#             # It is able to access flaghash declared in __start_kubectl from here :)
#             flaghash[${flagname}]=${flagval}
#
#         }
#
#     }
# }
```
https://gist.github.com/superbrothers/0ede4292f6d973f93e54368e227a4902

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*:
fixes kubernetes/kubectl#42

**Special notes for your reviewer**:
@mengqiy

**Release note**:

```release-note
NONE
```
2017-08-06 02:45:49 -07:00
FengyunPan 1ff8e12a24 [OpenStack] Add more detail error message
I get same simple error messages "Unable to initialize cinder client
for region: RegionOne" from controller-manager, but I can not find the
reason. We should add more detail message "err" into glog.Errorf.
2017-08-06 14:41:47 +08:00
zhouhaibing089 a0cebcb559 plugin/pkg/client/auth: add openstack auth provider 2017-08-05 21:24:14 -07:00