Commit Graph

41505 Commits (5fc2b3522cb70ced06322f93321ef77715ac4e28)

Author SHA1 Message Date
Kubernetes Submit Queue 5fc2b3522c Merge pull request #39132 from madhusudancs/fed-newtest-refactor-develop-sh
Automatic merge from submit-queue

[Federation] Recompute registry name and version tag in the federation up script.sh and a bunch of other fixes.
2017-01-06 09:26:08 -08:00
Kubernetes Submit Queue 9ce93ed50a Merge pull request #39496 from stevekuznetsov/skuznets/fix-e2e-container-context
Automatic merge from submit-queue (batch tested with PRs 39493, 39496)

Use privileged containers for host path e2e tests

Test containers need to run as spc_t in order to interact with the host
filesystem under /tmp, as the tests for HostPath are doing. Docker will
transition the container into this domain when running the container as
privileged.

Signed-off-by: Steve Kuznetsov <skuznets@redhat.com>

Currently, this test fails with AVC denials like:
```
time->Thu Jan  5 10:17:51 2017
type=SYSCALL msg=audit(1483629471.846:6623): arch=c000003e syscall=257 success=no exit=-13 a0=ffffffffffffff9c a1=c820010120 a2=80241 a3=1a4 items=0 ppid=4112 pid=4130 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="mt" exe="/mt" subj=system_u:system_r:svirt_lxc_net_t:s0:c123,c328 key=(null)
type=AVC msg=audit(1483629471.846:6623): avc:  denied  { write } for  pid=4130 comm="mt" name="sub-path" dev="xvda2" ino=118491348 scontext=system_u:system_r:svirt_lxc_net_t:s0:c123,c328 tcontext=system_u:object_r:container_runtime_tmp_t:s0 tclass=dir
```

```release-note
NONE
```

/cc @ncdc @pmorie
2017-01-06 08:44:20 -08:00
Kubernetes Submit Queue 402abd23ef Merge pull request #39493 from sjenning/fix-null-deref
Automatic merge from submit-queue (batch tested with PRs 39493, 39496)

kubelet: fix nil deref in volume type check

An attempt to address memory exhaustion through a build up of terminated pods with memory backed volumes on the node in PR https://github.com/kubernetes/kubernetes/pull/36779 introduced this.

For the `VolumeSpec`, either the `Volume` or `PersistentVolume` field is set, not both.  This results in a situation where there is a nil deref on PVs.  Since PVs are inherently not memory-backend, only local/temporal volumes should be considered.

This needs to go into 1.5 as well.

Fixes #39480

@saad-ali @derekwaynecarr @grosskur @gnufied

```release-note
fixes nil dereference when doing a volume type check on persistent volumes
```
2017-01-06 08:44:18 -08:00
Madhusudan.C.S ebde7fe8e4 Remove from federation API server manifest, it is not available anymore and is not required. 2017-01-06 19:17:48 +05:30
Madhusudan.C.S 48f79cf600 Quote a bash variable, fix a typo and add some additional logging. 2017-01-06 19:17:48 +05:30
Madhusudan.C.S 0c81f60ba0 Recompute registry name and version tag in the federation up script. 2017-01-06 19:17:47 +05:30
Kubernetes Submit Queue 41d7acc0f5 Merge pull request #39464 from apprenda/kubeadm_93-more_discovery
Automatic merge from submit-queue

Implemented file and HTTPS based discovery for kubeadm

**What this PR does / why we need it**:
This PR implements both file and HTTPS based discovery for `kubeadm`.

**Which issue this PR fixes**:
fixes https://github.com/kubernetes/kubeadm/issues/93
fixes https://github.com/kubernetes/kubeadm/issues/94

**Special notes for your reviewer**:
I'd like to add some tests but 'm sure `kubeconfig` loading is already covered by other tests in `clientcmd` package.

/cc @luxas @pipejakob
2017-01-06 05:42:02 -08:00
Paulo Pires c272bc56b1
kubeadm: flag token discovery pieces to be refactored. 2017-01-06 12:09:50 +00:00
Paulo Pires a519335303
kubeadm: added HTTPS discovery.
Fixes kubernetes/kubeadm#94
2017-01-06 12:08:34 +00:00
Paulo Pires 18370ba0c1
kubeadm: added file discovery.
Fixes kubernetes/kubeadm#93
2017-01-06 12:07:25 +00:00
Kubernetes Submit Queue 7171f6fd5f Merge pull request #38579 from humblec/gluster-volume-type
Automatic merge from submit-queue

Let admin configure the volume type and parameters for gluster DP volumes
2017-01-06 01:35:37 -08:00
Kubernetes Submit Queue af1a5ce426 Merge pull request #39492 from mikedanese/xtables
Automatic merge from submit-queue

add netlink and libxtables to kube-proxy image

kube-proxy won't start
2017-01-06 00:23:38 -08:00
Humble Chirammal 90266eb7ce Let admin configure the volume type and parameters for gluster DP volumes
Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
2017-01-06 12:33:25 +05:30
Kubernetes Submit Queue 3414ec3e13 Merge pull request #39472 from DjangoPeng/docker-fix
Automatic merge from submit-queue

Fix unpack docker.tar.gz failure bug

In centOS, there is a conflict bug of docker. We save docker as [docker.tar.gz](https://github.com/kubernetes/kubernetes/blob/master/cluster/centos/build.sh#L57) in function `download-releases()`, but uncompress [docker.tgz](https://github.com/kubernetes/kubernetes/blob/master/cluster/centos/build.sh#L98) in function `unpack-releases()`.
2017-01-05 22:22:07 -08:00
Kubernetes Submit Queue 7841d57ba9 Merge pull request #39416 from NickrenREN/master-externalAddresses
Automatic merge from submit-queue

optimize externalAddresses() return
2017-01-05 21:25:16 -08:00
Kubernetes Submit Queue 4398e1edb0 Merge pull request #39393 from ixdy/gazel-srcs
Automatic merge from submit-queue

bazel: update to gazel v13 and create sources rules throughout tree

**What this PR does / why we need it**: creates filegroup rules using https://github.com/mikedanese/gazel/pull/20, which we can then use in creating release tarballs

**Special notes for your reviewer**: this obviously should not be merged before https://github.com/mikedanese/gazel/pull/20 is merged and tagged; this is more to give you an idea of what the output looks like. The verification tests should fail this PR in any case.

**Release note**:

```release-note
NONE
```
2017-01-05 20:43:22 -08:00
NickrenREN 4ae0423d27 optimize externalAddresses() return
We do not use addresses and err in function body,so we drop them to maintain a consistent coding style
2017-01-06 09:36:53 +08:00
Steve Kuznetsov d60cb81f7f
Use privileged containers for host path e2e tests
Test containers need to run as spc_t in order to interact with the host
filesystem under /tmp, as the tests for HostPath are doing. Docker will
transition the container into this domain when running the container as
privileged.

Signed-off-by: Steve Kuznetsov <skuznets@redhat.com>
2017-01-05 17:24:09 -05:00
Jeff Grafton 1ccf106608 Add a rule to create kubernetes-src.tar.gz 2017-01-05 14:14:13 -08:00
Jeff Grafton 61fcf21d73 Update excludes for toplevel glob 2017-01-05 14:14:13 -08:00
Jeff Grafton 20d221f75c Enable auto-generating sources rules 2017-01-05 14:14:13 -08:00
Jeff Grafton f8288ed1f3 Create BUILD files in top-level subdirectories 2017-01-05 14:14:12 -08:00
Jeff Grafton a53c5f2a4f use gazel to autofix formatting 2017-01-05 14:14:12 -08:00
Jeff Grafton ab0c903c7f Update to gazel v13 2017-01-05 14:14:06 -08:00
Mike Danese eb62ac4363 add netlink and libxtables to kube-proxy image 2017-01-05 13:42:26 -08:00
Seth Jennings c4e6725236 fix nil deref 2017-01-05 15:36:42 -06:00
Kubernetes Submit Queue 8ef6902516 Merge pull request #39451 from euank/remove-abac
Automatic merge from submit-queue

cluster/cl: move abac to rbac

See #39092

We based off of GCI in the brief time where it was using abac.

fixes #39395

cc @yifan-gu 

**Release note**:
```release-note
NONE
```
2017-01-05 12:31:17 -08:00
Kubernetes Submit Queue 5503e5e6be Merge pull request #39413 from zdj6373/cinder
Automatic merge from submit-queue (batch tested with PRs 39433, 39413)

"Attach" function records information collation

In the "attach" function, the log information, for the variable "instanceid", has been described as "node", as well as recorded as "instance", recorded as "instance" should be better.
2017-01-05 10:35:18 -08:00
Kubernetes Submit Queue 13780bba82 Merge pull request #39433 from deads2k/generic-04-no-dep-01
Automatic merge from submit-queue

move no k8s.io/kubernetes dependencies round 01

Builds on the previous, adds unit testing the staging dir.

moves

 1. pkg/healthz -> apiserver/pkg/healthz
 2. pkg/util/flushwriter -> apiserver/pkg/util/flushwriter
 3. pkg/auth/authenticator -> apiserver/pkg/authentication/authenticator
 4. pkg/auth/authorizer -> apiserver/pkg/authorization/authorizer

@sttts
2017-01-05 10:18:54 -08:00
Kubernetes Submit Queue 2876c23523 Merge pull request #39449 from deads2k/generic-12-enforce-import
Automatic merge from submit-queue

add import cycle checking for staging to verify scripts

Adds an import cycle check to verify scripts since we can't yet use import-boss.  See https://github.com/kubernetes/gengo/pull/27 for details, but since the rule is very simple and global, this ought to provide sufficient protection.

@kubernetes/sig-api-machinery-misc
2017-01-05 09:12:05 -08:00
Kubernetes Submit Queue 4422ddecba Merge pull request #39432 from deads2k/generic-06-strings
Automatic merge from submit-queue

snip pkg/util/strings dependency

The `pkg/util/strings` package looks to be largely used by volumes, which are independent of the bits used by genericapiserver which aren't used by anyone else.  This moves the single function (used no where else) to its point of use.

@sttts
2017-01-05 08:32:38 -08:00
DjangoPeng 61076ede9e fix unpack docker.tar.gz failure bug 2017-01-06 00:17:36 +08:00
deads2k 4d7fcae85a mechanicals 2017-01-05 11:14:27 -05:00
deads2k b813e98a26 move no k8s.io/kubernetes dependencies round one 2017-01-05 11:09:42 -05:00
deads2k a672b501df add apiserver to list of unit tested packages 2017-01-05 11:09:42 -05:00
Kubernetes Submit Queue e18f54f9d2 Merge pull request #39444 from deads2k/generic-11-selectively
Automatic merge from submit-queue

selectively move to client-go packages

selectively update some low hanging fruit to use client-go.

@sttts
2017-01-05 07:51:11 -08:00
deads2k 4075258bf2 add import cycle checking for staging to verify scripts 2017-01-05 10:25:20 -05:00
deads2k 37c0c14215 snip pkg/util/strings dependency 2017-01-05 09:42:42 -05:00
Kubernetes Submit Queue acc81d6d96 Merge pull request #39291 from xilabao/fix-set-selector
Automatic merge from submit-queue (batch tested with PRs 38766, 39291)

fix kubectl set selector

fix #39290
2017-01-05 03:36:18 -08:00
Kubernetes Submit Queue 6d0efbc9d6 Merge pull request #38766 from jsafrane/wait-attach-backoff
Automatic merge from submit-queue

AWS: Add exponential backoff to waitForAttachmentStatus() and createTags()

We should use exponential backoff while waiting for a volume to get attached/detached to/from a node. This will lower AWS load and reduce API call throttling.

This partly fixes #33088

@justinsb, can you please take a look?
2017-01-05 03:08:04 -08:00
Kubernetes Submit Queue f8b708385e Merge pull request #39454 from foxish/fix-stateful-set-detection
Automatic merge from submit-queue (batch tested with PRs 39435, 39454)

Fix PDB by percentages for StatefulSet pods

Previously, PDBs defined in terms of percentages would error out with StatefulSet as they did not know how to find the scale associated.
This change teaches the disruption controller to also look at StatefulSets and their scale.

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

**Release note**:
```release-note
Fix issue with PodDisruptionBudgets in which `minAvailable` specified as a percentage did not work with StatefulSet Pods.
```

cc @a-robinson @kow3ns @kubernetes/sig-apps-misc
2017-01-05 02:50:20 -08:00
Kubernetes Submit Queue f76fba0da0 Merge pull request #39435 from sttts/sttts-cloudprovider-to-master
Automatic merge from submit-queue

Move apiserver cloudprovider dep into kubeapiserver
2017-01-05 02:29:11 -08:00
Kubernetes Submit Queue ed5414d333 Merge pull request #39426 from apprenda/kubeadm_95-fix_token_discovery
Automatic merge from submit-queue

kubeadm token discovery URL may not have valid input for url.Parse

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

**Which issue this PR fixes**: fixes https://github.com/kubernetes/kubeadm/issues/95

**Special notes for your reviewer**:
/cc @dgoodwin @luxas @mikedanese this is a WIP! Need a couple things:
* decide token separator, `.` or `:`
* define error handling in `token.go::37`
2017-01-05 01:47:14 -08:00
Dr. Stefan Schimanski f96fa748d8 Move apiserver cloudprovider dep into kubeapiserver 2017-01-05 09:40:03 +01:00
Kubernetes Submit Queue f605bfda61 Merge pull request #39429 from apprenda/kubeadm_80-change_etcd_datadir
Automatic merge from submit-queue

kubeadm: change etcd data dir to match host path.

**What this PR does / why we need it**: Trivial change that adopts a well-known path for etcd data, following the `hostPath` defined.

**Which issue this PR fixes**: Fixes https://github.com/kubernetes/kubeadm/issues/80

**Special notes for your reviewer**:
/cc @luxas @kad
2017-01-05 00:13:28 -08:00
Paulo Pires a6cdfdef4b
kubeadm: make sure URL is valid for token discovery. 2017-01-05 08:05:48 +00:00
Kubernetes Submit Queue 6cbec8e64e Merge pull request #39422 from fraenkel/configmap_prefix
Automatic merge from submit-queue

Check if key is a valid after prefix is prepended
2017-01-04 19:41:25 -08:00
Kubernetes Submit Queue fd7408d076 Merge pull request #39288 from rkouj/unit-test-operation-executor
Automatic merge from submit-queue

Add unit tests for operation_executor

Add unit test for `Unmount operations should start in parallel for all volume plugins`

cc: @saad-ali
2017-01-04 18:52:22 -08:00
Kubernetes Submit Queue 11402abc71 Merge pull request #39445 from mikedanese/deb-join
Automatic merge from submit-queue (batch tested with PRs 39311, 39226, 39445)

use debs to build k8s docker images

This puts the binaries in better paths and fixes compatibility issues.
2017-01-04 18:25:09 -08:00
Kubernetes Submit Queue 51e6c879e7 Merge pull request #39226 from luksa/kubectl_proxy_empty_path
Automatic merge from submit-queue (batch tested with PRs 39311, 39226, 39445)

Make kubectl proxy accept empty path

**What this PR does / why we need it**:
The kubectl proxy previously returned 403 Forbidden: Unauthorized when receiving a request from e.g. "curl localhost:8001" or "curl localhost:8001/".  The previous DefaultPathAcceptRE regex was wrong as it assumed the path in this case would be "/" (but it is actually "").

After someone runs kubectl proxy and tries accessing it with curl, they will probably just try hitting localhost:8001  (which returns an "Unauthorized" response) instead of say localhost:8001/api (which returns a proper response from the API server). Also, whoever previously modified the DefaultPathAcceptRE regex was obviously expecting the regex to accept requests for localhost:8001/

```release-note
fix issue with kubectl proxy so that it will proxy an empty path - e.g. http://localhost:8001
```
2017-01-04 18:25:07 -08:00