Commit Graph

41478 Commits (8ef690251641b7df6749f67abff86fa01c10b070)

Author SHA1 Message Date
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
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
Kubernetes Submit Queue eb8739d3c1 Merge pull request #39311 from rkouj/refactor-tear-down-at
Automatic merge from submit-queue

Check if pathExists before performing Unmount

Unmount operation should not fail if path does not exist

Part two of: https://github.com/kubernetes/kubernetes/pull/38547
Plugins status captured here: https://github.com/kubernetes/kubernetes/issues/39251

cc: @saad-ali
2017-01-04 18:10:30 -08:00
Anirudh 05dafa9cd0 Updated bazel 2017-01-04 18:06:25 -08:00
Anirudh 1508ecfe37 Make PDBs represent percentage in StatefulSet 2017-01-04 17:54:58 -08:00
Kubernetes Submit Queue 84df067967 Merge pull request #39450 from pipejakob/file-disc
Automatic merge from submit-queue (batch tested with PRs 36229, 39450)

Bugfix on kubeadm join with non-token discovery.

Without this change, using a non-token discovery mechanism during a join triggers a nil pointer panic (instead of an error message about not being implemented yet).

CC @mikedanese 

**Release note**:
```release-note
NONE
```
2017-01-04 17:36:08 -08:00
Kubernetes Submit Queue f4a8713088 Merge pull request #36229 from wojtek-t/bump_etcd_version
Automatic merge from submit-queue (batch tested with PRs 36229, 39450)

Bump etcd to 3.0.14 and switch to v3 API in etcd.

Ref #20504

**Release note**:

```release-note
Switch default etcd version to 3.0.14.
Switch default storage backend flag in apiserver to `etcd3` mode.
```
2017-01-04 17:36:06 -08:00
Kubernetes Submit Queue a104229e1a Merge pull request #38981 from liggitt/remove-rbac-user-all
Automatic merge from submit-queue (batch tested with PRs 39408, 38981)

Remove RBAC UserAll

* Removes special handling of User * subjects in rolebinding matching evaluation
* Converts v1alpha1 rolebindings to `User *` subjects to `Group system:authenticated` subjects for backwards compatibility

```release-note
RBAC's special handling of the User subject named "*" in RoleBinding and ClusterRoleBinding objects is being deprecated and will be removed in v1beta1. Existing v1alpha1 role bindings to User "*" will be converted to the group "system:authenticated". To match unauthenticated requests, RBAC role bindings must explicitly bind to the group "system:unauthenticated".
```
2017-01-04 16:14:05 -08:00
Euan Kemp c1afc4a3d8 cluster/cl: move abac to rbac
See #39092

We based off of GCI in the brief time where it was using abac.
2017-01-04 16:10:59 -08:00
Jacob Beacham 5cc36c9f05 Bugfix on kubeadm join with non-token discovery.
Without this change, using a non-token discovery mechanism during a join
triggers a nil pointer panic (instead of an error message about not
being implemented yet).
2017-01-04 15:40:52 -08:00
Mike Danese 35ca259464 uses debs to build k8s docker images 2017-01-04 15:35:49 -08:00
Kubernetes Submit Queue 06de081d96 Merge pull request #39408 from liggitt/invalid-token-401
Automatic merge from submit-queue

Ensure invalid token returns 401 error, not 403

fixes #39267

If a user attempts to use a bearer token, and the token is rejected, the authenticator should return an error. This distinguishes requests that did not provide a bearer token (and are unauthenticated without error) from ones that attempted to, and failed.
2017-01-04 15:18:18 -08:00
deads2k 1ebe759743 selectively move to client-go packages 2017-01-04 17:49:24 -05:00
Michael Fraenkel f6c9ab4312 Check if key is a valid after prefix is prepended
- Allow invalid keys to become valid by requiring a prefix
2017-01-04 17:26:44 -05:00
Kubernetes Submit Queue cb78349735 Merge pull request #39431 from deads2k/generic-05-validation
Automatic merge from submit-queue

snip links from genericapiserver to api/validation

We had a trip dependency on `pkg/api/validation` through `pkg/api/rest` which is used for RESTStorage.  This splits the generic validation required for a genericapiserver out from the rest of validation.  For now, functions still delegate.

@sttts
2017-01-04 14:16:03 -08:00
Jordan Liggitt b8c2ad6d42
Deprecate RBAC UserAll, convert v1alpha1 User * rolebindings to Group system:authenticated 2017-01-04 17:11:16 -05:00
Kubernetes Submit Queue 6b70211568 Merge pull request #38844 from nikhiljindal/fednewkubectlTests
Automatic merge from submit-queue

Adding test-federation-cmd.sh to test kubectl with federation apiserver

There are 2 parts to the PR:
* Adding ability to run kubectl tests for a subset of resources.
* Adding test-federation-cmd.sh that runs kubectl tests for resources that are supported by federation-apiserver.

cc @kubernetes/sig-federation @kubernetes/sig-api-machinery 

```release-note
Adding kubectl tests for federation
```
2017-01-04 13:07:17 -08:00
deads2k 80143ee0b4 snip links from genericapiserver to api/validation 2017-01-04 15:17:18 -05:00
Kubernetes Submit Queue 5ee52e8bce Merge pull request #39384 from deads2k/generic-01-start-staging
Automatic merge from submit-queue

Start moving genericapiserver to staging

This moves `pkg/auth/user` to `staging/k8s.io/genericapiserver/pkg/authentication/user`.  I'll open a separate pull into the upstream gengo to support using `import-boss` on vendored folders to support staging.

After we agree this is the correct approach and see everything build, I'll start moving other packages over which don't have k8s.io/kubernetes deps.

@kubernetes/sig-api-machinery-misc @lavalamp 
@sttts @caesarxuchao ptal
2017-01-04 12:06:34 -08:00
nikhiljindal 5424d50c03 Adding test-federation-cmd.sh to test kubectl with federation apiserver 2017-01-04 11:17:05 -08:00
Kubernetes Submit Queue d12d012a55 Merge pull request #39330 from foolusion/fix-labels-Parse-go-doc
Automatic merge from submit-queue

pkg/labels: fix the godoc for Parse()

previously the formatting was broken for labels.Parse() function. I
fixed the spacing so it will format correctly for the generated go docs.
There was also a dangling "]" at the end of the first line so i deleted
it.



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

This fixes a formatting issue with the generated go documentation.

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

**Release note**:

```release-note
NONE
```
2017-01-04 10:04:11 -08:00
Kubernetes Submit Queue ee47db8c84 Merge pull request #39399 from zhouhaibing089/namespace-controller
Automatic merge from submit-queue

make discovery static when extensions/thirdpartyresources is not enabled

this should be a bug fix, if `extensions/thirdpartyresources` is enabled, the result of `Discovery().ServerPreferredNamespacedResources` will be dynamic then, so we are making the `discoverResourcesFn` static only when the `extensions/thirdpartyresources` is not enabled.
2017-01-04 10:04:00 -08:00
Kubernetes Submit Queue 17f8d82fa3 Merge pull request #39359 from tianshapjq/add-top-specification
Automatic merge from submit-queue

add some specifications on the top command

**What this PR does / why we need it**:
the top command is available when heapster works fine on the server, but the specifications doesn't mention about this. So I added some specifications here.
2017-01-04 08:45:54 -08:00
Paulo Pires 241c530648
kubeadm: change etcd data dir to match host path.
Fixes https://github.com/kubernetes/kubeadm/issues/80
2017-01-04 16:43:13 +00:00
Jordan Liggitt 0902c55c8b
Ensure invalid token returns 401 error 2017-01-04 11:37:05 -05:00
Kubernetes Submit Queue ee03b9b206 Merge pull request #39400 from xilabao/fix-wrong-help-message-for-taint
Automatic merge from submit-queue (batch tested with PRs 39409, 39400)

fix wrong help message for taint

fix #39381
2017-01-04 08:03:10 -08:00
Kubernetes Submit Queue 7d31bf46fa Merge pull request #39409 from NickrenREN/apiserver-drop-err
Automatic merge from submit-queue (batch tested with PRs 39409, 39400)

remove newAPIGroupVersion() and getAPIGroupVersion() second return value
2017-01-04 08:03:09 -08:00
deads2k ca58ec0237 mechanical changes for move 2017-01-04 10:27:05 -05:00
deads2k 442d2c1404 move pkg/auth/user to staging 2017-01-04 10:27:04 -05:00