Commit Graph

63184 Commits (707b7fd17959b9195278f9e350e11a8829085a91)

Author SHA1 Message Date
Kubernetes Submit Queue 707b7fd179
Merge pull request #59701 from mlmhl/kubectl_describe_pvc_condition
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 description of pvc condition for kubectl describe command

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

As the title says, add description of `PersistentVolumeClaim.Status.Conditions` for `kubectl describe pvc` command, the output will look like this:

```
Conditions:
  Type       Status  LastProbeTime                     LastTransitionTime                Reason  Message
  ----       ------  -----------------                 ------------------                ------  -------
  Resizing   True    Mon, 01 Jan 0001 00:00:00 +0000   Sat, 10 Feb 2018 19:20:56 +0800           
```

**Release note**:

```release-note
NONE
```

/sig storage
/kind enhancement
2018-03-21 11:38:29 -07:00
Anago GCB 918a83d7c6 Update CHANGELOG-1.9.md for v1.9.6. 2018-03-21 16:19:24 +00:00
Kubernetes Submit Queue bcf517e372
Merge pull request #61114 from php-coder/psp_printer_priv_fix
Automatic merge from submit-queue (batch tested with PRs 61124, 59537, 61235, 61258, 61114). 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>.

kubectl get psp: show PRIV for column with privileged flag

**What this PR does / why we need it**:
This PR improves a header in the `kubectl get psp` output.

Prior this change:
```console
$ kubectl get psp privileged
NAME         DATA      CAPS      SELINUX    RUNASUSER          FSGROUP    SUPGROUP   READONLYROOTFS   VOLUMES
privileged   true      *         RunAsAny   RunAsAny           RunAsAny   RunAsAny   false            *
```
Note that the 2nd column has DATA caption.

After this change:
```console
$ kubectl get psp 
NAME         PRIV      CAPS      SELINUX    RUNASUSER          FSGROUP    SUPGROUP   READONLYROOTFS   VOLUMES
privileged   true      *         RunAsAny   RunAsAny           RunAsAny   RunAsAny   false            *
```

**Which issue(s) this PR fixes**:
This is regression after #49700
2018-03-21 08:39:31 -07:00
Kubernetes Submit Queue 0e3b344518
Merge pull request #61258 from hzxuzhonghu/cleanup-local-up-outdated
Automatic merge from submit-queue (batch tested with PRs 61124, 59537, 61235, 61258, 61114). 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>.

remove outdated waiting apiserver comments in local-up-cluster.sh

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

Now secure port is used, remove outdated waiting for apiserver healthy comments in local-up-cluster.sh.


**Release note**:

```release-note
NONE
```
2018-03-21 08:39:27 -07:00
Kubernetes Submit Queue 130caab7d5
Merge pull request #61235 from yguo0905/client-2
Automatic merge from submit-queue (batch tested with PRs 61124, 59537, 61235, 61258, 61114). 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>.

Support new NODE_OS_DISTRIBUTION 'custom' on GCE

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

This PR allows us to run e2e tests against arbitrary OS images on GCE.

It will be cherry picked into 1.8, 1.9 and 1.10.

**Release note**:

```
Support new NODE_OS_DISTRIBUTION 'custom' on GCE.
```

/assign @dashpole
2018-03-21 08:39:23 -07:00
Kubernetes Submit Queue eda4fdb769
Merge pull request #59537 from hanxiaoshuai/fixtodo0208
Automatic merge from submit-queue (batch tested with PRs 61124, 59537, 61235, 61258, 61114). 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 todo:add function getFailContainer to report which containers failed the pod

**What this PR does / why we need it**:
fix todo:add function getFailContainer to report which containers failed the pod in runonce.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 #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-03-21 08:39:16 -07:00
Kubernetes Submit Queue d9d1364657
Merge pull request #61124 from satyasm/avoid-sync-delay
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>.

Fix Issue #61123, call syncer.Update on add event.

**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 #61123

**Special notes for your reviewer**:

**Release note**:

```release-note
Fixed #61123 by triggering syncer.Update on all cases including when a syncer is created
on a new add event.
```
2018-03-21 08:25:44 -07:00
Kubernetes Submit Queue 808545a8aa
Merge pull request #60602 from bendrucker/docker-registry-email-optional
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>.

remove docker-email from required args for "create secret docker-registry"

Completes https://github.com/kubernetes/kubernetes/pull/42191

While that removed `docker-email` as required from the generator, the CLI still asserts the presence of the argument resulting in "error: flag docker-email is required" when `--docker-email` is omitted from a `kubectl create secret docker-registry` call.

Comments on the original issue (https://github.com/kubernetes/kubernetes/issues/41727) note that this change is still needed to accomplish the original intent.
2018-03-21 07:34:21 -07:00
Kubernetes Submit Queue 3b04de4be3
Merge pull request #60826 from WanLinghao/job_dry_run
Automatic merge from submit-queue (batch tested with PRs 61087, 61075, 61213, 61149, 60826). 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 support for --dry-run to kubectl create job

**What this PR does / why we need it**:
Create job subcommand lacks dry-run flag, this patch fix this.
**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-03-21 06:41:38 -07:00
Kubernetes Submit Queue f4398293a7
Merge pull request #61149 from hanxiaoshuai/fixtodo0314
Automatic merge from submit-queue (batch tested with PRs 61087, 61075, 61213, 61149, 60826). 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>.

remove unnecessary TODOs in meta.go

**What this PR does / why we need it**:
I notice there are TODOs in apimachinery\pkg\api\meta\meta.go,return bool instead of error func CommonAccessor, ListAccessor, Accessor. If is it necessary to do,I push a PR for 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 #
[#61153](https://github.com/kubernetes/kubernetes/issues/61153)
**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-03-21 06:41:33 -07:00
Kubernetes Submit Queue e6bd4ffbe9
Merge pull request #61213 from junxu/remove-deprecate-authorization-rbac-super-user
Automatic merge from submit-queue (batch tested with PRs 61087, 61075, 61213, 61149, 60826). 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>.

Remove deprecated paramter "authorization-rbac-super-user"

**What this PR does / why we need it**: As RBAC is v1 now, we need remove the deprecated  "authorization-rbac-super-user" paramter for RBAC alpha

**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

```
2018-03-21 06:41:30 -07:00
Kubernetes Submit Queue d84c938da5
Merge pull request #61075 from tallclair/feature-owners
Automatic merge from submit-queue (batch tested with PRs 61087, 61075, 61213, 61149, 60826). 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>.

Grant sig leads feature approval powers

**What this PR does / why we need it**:
Sig leads already approve features for milestones and do a lot of code reviews. They should be able to approve changes to the associated feature gates, rather than needing to escalate every feature to root owners.

I omitted some sigs that shouldn't need to approve features in the base repo. LMK if I missed any, or these should be included in the approvers:

- AWS
- Azure
- Big Data
- Contributor Experience
- Docs
- GCP
- OpenStack
- Product Management
- Service Catalog
- Testing
- UI

For posterity, here's the script I used: https://gist.github.com/tallclair/1128aefa3186b0c3a8f4603929d2354e

**Special notes for your reviewer**:

@sig-leads: Please use responsibly :)

**Release note**:
```release-note
NONE
```
2018-03-21 06:41:27 -07:00
Kubernetes Submit Queue 8c1e171eec
Merge pull request #61087 from lcfang/test0313
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>.

remove check "d >= 0" since go 1.8 is no longer supported on master branch

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

remove check "d >= 0" since go 1.8 is no longer supported on master branch

**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-03-21 06:39:34 -07:00
Kubernetes Submit Queue 622ad35677
Merge pull request #61115 from php-coder/psp_fix_provider_error_msgs
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>.

PSP: fix strategy name in the error messages

**What this PR does / why we need it**:
This PR corrects strategy names in the error messages.
2018-03-21 04:37:58 -07:00
Kubernetes Submit Queue 01e67e2808
Merge pull request #61169 from muhongwei/mhw_branch1
Automatic merge from submit-queue (batch tested with PRs 59536, 61104, 61030, 59013, 61169). 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 spelling
2018-03-21 03:43:24 -07:00
Kubernetes Submit Queue bd745a4080
Merge pull request #59013 from crimsonfaith91/ds-integration-3
Automatic merge from submit-queue (batch tested with PRs 59536, 61104, 61030, 59013, 61169). 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 rolling update daemonset existing pod adoption integration test

**What this PR does / why we need it**:
This PR adds rolling update DaemonSet existing pod adoption integration test. It also shifts all helper functions to a new utility file.

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

**Release note**:
```release-note
NONE
```
2018-03-21 03:43:21 -07:00
Kubernetes Submit Queue 6ab841580f
Merge pull request #61030 from krmayankk/utrunas
Automatic merge from submit-queue (batch tested with PRs 59536, 61104, 61030, 59013, 61169). 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 UT for validatePSPRunAsUser

This PR is the first in a series which will continue to finish the work started in https://github.com/kubernetes/kubernetes/pull/52077 to add RunAsGroup feature in Pod and PSP

This PR simply adds a UT for RunAsUser validation in PSP

@pmorie @tallclair
2018-03-21 03:43:18 -07:00
Kubernetes Submit Queue a5a3bc93f1
Merge pull request #61104 from hzxuzhonghu/AlwaysAdmit-stop-using
Automatic merge from submit-queue (batch tested with PRs 59536, 61104, 61030, 59013, 61169). 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>.

stop using AlwaysAdmit admission

`AlwaysAdmit ` was deprecated, and stop using it in test.

**Release note**:

```release-note
NONE
```
2018-03-21 03:43:14 -07:00
Kubernetes Submit Queue a66301b313
Merge pull request #59536 from linyouchong/lyc-20180208
Automatic merge from submit-queue (batch tested with PRs 59536, 61104, 61030, 59013, 61169). 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 incorrect logic in glusterfs.go#canSupport

**What this PR does / why we need it**:
if `spec.PersistentVolume` is nil or `spec.Volume` is nil, func `canSupport` should return false.

**Release note**:
```
NONE
```
/release-note-none
/sig storage
2018-03-21 03:43:11 -07:00
Kubernetes Submit Queue a7d788d91f
Merge pull request #60886 from mattjmcnaughton/mattjmcnaughton/59975-object-metrics-ignore-unready-pods
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>.

Ignore unready pods when calculating desired replicas

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

This PR causes `GetExternalMetricReplicas` and `GetObjectMetricReplicas` to ignore unready pods when computing the number of desired replicas. If we don't ignore unready pods, there is a risk of overscaling. See the commit messages for examples and implementation info.

**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 #59975 

**Special notes for your reviewer**:
@MaciekPytel and I consciously chose to save `GetExternalPerPodMetricReplicas` for a separate PR, as we aren't definite on what is the preferred behavior.

**Release note**:

```release-note
Unready pods will no longer impact the number of desired replicas when using horizontal auto-scaling with external metrics or object metrics.
```
2018-03-21 01:34:23 -07:00
Kubernetes Submit Queue 0254399884
Merge pull request #61105 from lcfang/test0313-2
Automatic merge from submit-queue (batch tested with PRs 57871, 61094, 60459, 61089, 61105). 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>.

remove the outdated TODO

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

remove the outdated TODO in [a7d6340ad2/staging/src/k8s.io/apiserver/pkg/registry/rest/meta.go (L42))

**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-03-20 23:34:42 -07:00
Kubernetes Submit Queue e15066f902
Merge pull request #61089 from tanshanshan/fix1012
Automatic merge from submit-queue (batch tested with PRs 57871, 61094, 60459, 61089, 61105). 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 namespace when we describe pod

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

Add namespace when we describe pod

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


**Special notes for your reviewer**:

**Release note**:

```release-note

```
2018-03-20 23:34:39 -07:00
Kubernetes Submit Queue 22a040a1b9
Merge pull request #60459 from agau4779/gce-internal-lb-tests
Automatic merge from submit-queue (batch tested with PRs 57871, 61094, 60459, 61089, 61105). 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>.

[GCE] Internal Loadbalancer Tests

**What this PR does / why we need it**:
Adds unit tests for the GCE Internal Loadbalancer. According to the test coverage tool, this PR brings test coverage of `gce_loadbalancer_internal.go` from 0% to 74.0%.

```release-note
NONE
```

/assign nicksardo bowei
2018-03-20 23:34:36 -07:00
Kubernetes Submit Queue de8400c09e
Merge pull request #61094 from nikhita/remove-hack-test-cmd
Automatic merge from submit-queue (batch tested with PRs 57871, 61094, 60459, 61089, 61105). 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>.

remove hack/test-cmd.sh: make is the main build tool

The script suggests to use `make test-cmd` and we don't use this script anywhere.

**Release note**:

```release-note
NONE
```

/kind cleanup
/assign sttts cblecker
2018-03-20 23:34:33 -07:00
Kubernetes Submit Queue 23844fe0f4
Merge pull request #57871 from CaoShuFeng/delete_test
Automatic merge from submit-queue (batch tested with PRs 57871, 61094, 60459, 61089, 61105). 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>.

Remove invalid comments in unit tests

**Release note**:

```release-note
NONE
```
2018-03-20 23:34:30 -07:00
Kubernetes Submit Queue ad432fa6bd
Merge pull request #60971 from CaoShuFeng/audit_throttle_burst
Automatic merge from submit-queue (batch tested with PRs 60919, 60953, 61085, 61083, 60971). 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>.

[advanced audit]fix comment about throttle burst

/assign @sttts

**Release note**:
```release-note
NONE
```
2018-03-20 20:34:38 -07:00
Kubernetes Submit Queue 32d6a9356d
Merge pull request #61083 from hzxuzhonghu/bug-fix-0313
Automatic merge from submit-queue (batch tested with PRs 60919, 60953, 61085, 61083, 60971). 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 bug in apiserver.k8s.io RootScopedKinds

RootScopedKinds in group ` apiserver.k8s.io` should be `AdmissionConfiguration`

**Release note**:

```release-note
NONE
```
2018-03-20 20:34:35 -07:00
Kubernetes Submit Queue dbea6f6372
Merge pull request #61085 from hzxuzhonghu/unversioned-cleanup
Automatic merge from submit-queue (batch tested with PRs 60919, 60953, 61085, 61083, 60971). 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>.

remove unused `pkg/api/unversioned`

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

clean code, see #61084 

**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 #61084

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-03-20 20:34:31 -07:00
Kubernetes Submit Queue 2d864f2359
Merge pull request #60953 from anfernee/sched-cache-resync
Automatic merge from submit-queue (batch tested with PRs 60919, 60953, 61085, 61083, 60971). 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>.

Sched cache resync

**What this PR does / why we need it**:  Scheduler cache comparer
    
    A debug tool that collects resources from api server and compares it
    with the scheduler cache. It currently only compares the node list, but
    it should be easy to extend. The compare is triggered by signal USER2,
    by doing
    
      kill -12 ${SCHED_PID}
    
    The compare result goes to scheduler log.

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

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

**Release note**:
```release-note
None
```
2018-03-20 20:34:28 -07:00
WanLinghao a3424872bd this patch do tow things:
1.add dry-run flag for create job subcommand
	2.add cmd-util test for create job subcommand
	modified:   pkg/kubectl/cmd/create_job.go
	modified:   hack/make-rules/test-cmd-util.sh
2018-03-21 10:41:17 +08:00
Kubernetes Submit Queue 3e5596321e
Merge pull request #60919 from dixudx/file_visit_error_info
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>.

include file name in the error when visiting files

**What this PR does / why we need it**:
/kind bug
/sig cli

**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 #60916

**Special notes for your reviewer**:
/cc @kubernetes/sig-cli-api-reviews 
**Release note**:

```release-note
include file name in the error when visiting files
```
2018-03-20 19:34:23 -07:00
Kubernetes Submit Queue 7fa3c9fa63
Merge pull request #60922 from hzxuzhonghu/userspace-proxier-cleanup
Automatic merge from submit-queue (batch tested with PRs 61003, 61031, 60360, 58349, 60922). 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>.

move `newUDPEchoServer` to proxier_test.go

move userspace proxier test code into test go file 

/kind cleanup

**Release note**:

```release-note
NONE
```
2018-03-20 18:34:38 -07:00
Kubernetes Submit Queue a0eede6411
Merge pull request #58349 from humblec/patch-2
Automatic merge from submit-queue (batch tested with PRs 61003, 61031, 60360, 58349, 60922). 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 supported SC parameters to the SC example yaml file.

**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

```
2018-03-20 18:34:35 -07:00
Kubernetes Submit Queue 4159be8a5a
Merge pull request #60360 from dixudx/kubectl_apply_flag_value_bind
Automatic merge from submit-queue (batch tested with PRs 61003, 61031, 60360, 58349, 60922). 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>.

flag value bindings for kubectl apply commands

**What this PR does / why we need it**:
/kind cleanup
/sig cli

xxxOptions did not get bound as default value for some flags.
This PR cleans those flag bindings for `kubectl apply` commands.

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

**Special notes for your reviewer**:
/assign @deads2k 

**Release note**:

```release-note
None
```
2018-03-20 18:34:32 -07:00
Kubernetes Submit Queue 16081cca2b
Merge pull request #61031 from zjj2wry/kubectl_create_role
Automatic merge from submit-queue (batch tested with PRs 61003, 61031, 60360, 58349, 60922). 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>.

resource-name not present in the URL for list,watch,deletecollection

**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**:
cc @deads2k @liggitt 
/sig cli
/sig auth

**Release note**:

```release-note
NONE
```
2018-03-20 18:34:29 -07:00
Kubernetes Submit Queue 4c8657c087
Merge pull request #61003 from CaoShuFeng/amdission_controller_glog_v2
Automatic merge from submit-queue (batch tested with PRs 61003, 61031, 60360, 58349, 60922). 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>.

log enabled admission controller in order

This change log enabled mutating and validating admission controller
in order.

ref: https://github.com/kubernetes/kubernetes/pull/60838/files#r173295334



**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
```
2018-03-20 18:34:26 -07:00
Kubernetes Submit Queue 7a273aa85d
Merge pull request #60796 from ravisantoshgudimetla/extender-log-fix
Automatic merge from submit-queue (batch tested with PRs 60898, 60912, 60753, 61002, 60796). 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>.

Change to fix scheduler extender error return message

**What this PR does / why we need it**:
As of now, scheduler always logs extender endpoint without verb like "filter", "prioritize" etc. With this change, we are including the verb as well while logging which helps in debugging
**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-03-20 17:37:20 -07:00
Kubernetes Submit Queue e3ac40264f
Merge pull request #61002 from FengyunPan2/fix-isNotFound
Automatic merge from submit-queue (batch tested with PRs 60898, 60912, 60753, 61002, 60796). 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>.

IsNotFound should check ErrDefault404 and ErrUnexpectedResponseCode

Related to: #60658 #60976
Refer to:
 https://github.com/gophercloud/gophercloud/pull/103/files#diff-e8ad71423a1527851f282515739eecc2R265

**Release note**:
```release-note
NONE
```
2018-03-20 17:37:17 -07:00
Kubernetes Submit Queue 9a3b0bd74f
Merge pull request #60753 from resouer/equiv-hash
Automatic merge from submit-queue (batch tested with PRs 60898, 60912, 60753, 61002, 60796). 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>.

Revert revert of equivalence class hash calculation in scheduler

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

NOTE: This is a revert revert of https://github.com/kubernetes/kubernetes/pull/58555

But since the original PR has been changed, I have to copy the original changes and resend this new PR. See: https://github.com/kubernetes/kubernetes/pull/58555#issuecomment-364345972

And I kept @misterikkit 's change as the first commit (by co-author feature of github) in the history. 

We decide to do revert revert because #58989 has been fixed, which should help to improve the time consumed by integration test.

**But** we should still pay attention to integration tests to see if there's frequent timeout happen.

**Special notes for your reviewer**:

**Release note**:

```release-note
Improve equivalence class hash calculation in scheduler
```
2018-03-20 17:37:14 -07:00
Kubernetes Submit Queue 6a431d1c0e
Merge pull request #60912 from m1093782566/refactor-hostport
Automatic merge from submit-queue (batch tested with PRs 60898, 60912, 60753, 61002, 60796). 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 TODO: move openHostPorts and closeHostPorts into a common struct and add UTs

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

* Fix [TODO](https://github.com/kubernetes/kubernetes/blob/master/pkg/kubelet/network/hostport/hostport.go#L132): move openHostPorts and closeHostPorts into a common struct, and eliminate the `hostportOpener` parameter in openHostPorts(), to make them looks more consistent.

* Add UTs for closeHostPorts.

**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-03-20 17:37:10 -07:00
Kubernetes Submit Queue d7c863e082
Merge pull request #60898 from lnsp/master
Automatic merge from submit-queue (batch tested with PRs 60898, 60912, 60753, 61002, 60796). 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 ranges field to PSP group Validate error details

**What this PR does / why we need it**: When the PodSecurityPolicy provider validation of a `fsGroup` fails, it throws a very non-descriptive error that redundantly announces that the group ID is not allowed. Since the group ID is already contained in the error stack, this is not required. This PR fixes it by storing the allowed ranges in the error details and therefore improves the debugging experience.

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

**Release note**:

```release-note
NONE
```
2018-03-20 17:37:07 -07:00
Kubernetes Submit Queue f3539784f3
Merge pull request #60927 from islinwb/ipset_ut
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>.

fix TODO: test more SetType

**What this PR does / why we need it**:
fix TODO in pkg/util/ipset/ipset_test.go: test more SetType

**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-03-20 16:34:22 -07:00
Kubernetes Submit Queue 14e3efe26a
Merge pull request #58717 from resouer/extender-interface
Automatic merge from submit-queue (batch tested with PRs 60759, 60531, 60923, 60851, 58717). 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>.

Implement preemption for extender with a verb and new interface

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

This is an alternative way of implementing #51656

**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 #51656

**Special notes for your reviewer**:

We will also want to compare with #56296 to see which one is the best solution. See: https://github.com/kubernetes/kubernetes/pull/56296#discussion_r163381235

cc @ravigadde @bsalamat 

**Release note**:

```release-note
Implement preemption for extender with a verb and new interface
```
2018-03-20 15:34:41 -07:00
Kubernetes Submit Queue 502c99f2a2
Merge pull request #60851 from aveshagarwal/master-rhbz-1548987
Automatic merge from submit-queue (batch tested with PRs 60759, 60531, 60923, 60851, 58717). 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>.

Do not create dangling legacy symlink

Do not create dangling legacy symlink if the new symlink to container logs does not exist.
These dangling legacy symlink are later removed by kube runtime gc, so it's better if we do not
create them in the first place to avoid unnecessary work from kube runtime gc. This situation occurs when docker uses journald logging driver.  

**What this PR does / why we need it**:
This PR fixes an issue where dangling symlink are being created.

**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.
```
@derekwaynecarr @sjenning @dashpole @kubernetes/sig-node-pr-reviews
2018-03-20 15:34:37 -07:00
Kubernetes Submit Queue 9b8323f174
Merge pull request #60923 from ipuustin/shell-bugfix5
Automatic merge from submit-queue (batch tested with PRs 60759, 60531, 60923, 60851, 58717). 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 build scripts to work in case there are spaces in directory names.

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

Fix kubernetes build scripts to work in case the source directory is in a directory path which contains a space.

You can prepare such a directory like this:
```
$ mkdir '/tmp/test dir/'
$ cd '/tmp/test dir/'
$ git clone https://github.com/kubernetes/kubernetes.git
$ cd kubernetes
```
Then, without the fix:
```
$ KUBE_FASTBUILD=true KUBE_RELEASE_RUN_TESTS=n build/release.sh
cat: /tmp/test: No such file or directory
cat: dir/kubernetes/build/build-image/cross/VERSION: No such file or directory
cat: /tmp/test: No such file or directory
cat: dír/kubernetes/build/build-image/VERSION: No such file or directory
+++ [0307 18:10:33] Verifying Prerequisites....
cp: target '/tmp/test dir/kubernetes/_output/images/kube-build:build-7c7cd10a18--/Dockerfile' is not a directory
!!! [0307 18:10:33] Call tree:
!!! [0307 18:10:33]  1: build/release.sh:35
kube::build::build_image(...)
!!! Error in build/../build/common.sh:454
  Error in build/../build/common.sh:454. '((i<3-1))' exited with status 1
Call stack:
  1: build/../build/common.sh:454 kube::build::build_image(...)
  2: build/release.sh:35 main(...)
Exiting with status 1
```
With the fix the compilation succeeds. The fix is done adding double quotes to required places (and also just in case to other places where shellcheck recommended adding them).

Note that this fix doesn't as such help with the official make-based build: it's tricky to make makefiles work with targets with spaces in their names.

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

**Special notes for your reviewer**:

This PR needs pretty thorough review since this touches the core build scripts. 

**Release note**:

```release-note
NONE
```
2018-03-20 15:34:34 -07:00
Kubernetes Submit Queue a2f1c24254
Merge pull request #60531 from dashpole/memcg_update
Automatic merge from submit-queue (batch tested with PRs 60759, 60531, 60923, 60851, 58717). 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>.

Subtract inactive_file from usage when setting memcg threshold

**What this PR does / why we need it**:
Implements solution for #51745, proposed in  https://github.com/kubernetes/community/pull/1451.
This is a prerequisite to fixing https://github.com/kubernetes/kubernetes/issues/57901.

**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 #51745

**Special notes for your reviewer**:

**Release note**:
```release-note
NONE
```
/sig node
/priority important-longterm
/kind bug

/assign @sjenning @derekwaynecarr @dchen1107
2018-03-20 15:34:30 -07:00
Kubernetes Submit Queue 691a7d4358
Merge pull request #60759 from hzxuzhonghu/etcd-flag-validate
Automatic merge from submit-queue (batch tested with PRs 60759, 60531, 60923, 60851, 58717). 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>.

validate EtcdOptions.EtcdServersOverrides in EtcdOptions.Validate

move `EtcdOptions.EtcdServersOverrides` validation from `BuildStorageFactory` to `EtcdOptions.Validate`, which fails fast in kube-apiserver startup.

**Release note**:

```release-note
NONE
```
2018-03-20 15:34:27 -07:00
Kubernetes Submit Queue d9008e0880
Merge pull request #60875 from charrywanganthony/rm_ServiceAcountKeyFile
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>.

remove --service-account-private-key-file in v1.11

`kube-cloud-controller-manager` flag `--service-account-private-key-file` is removed in v1.11

ref: #50289


**Release note**:

```release-note
`kube-cloud-controller-manager` flag `--service-account-private-key-file` is removed in v1.11
```
2018-03-20 14:34:22 -07:00
Kubernetes Submit Queue ab639118e7
Merge pull request #60428 from rosti/kubeadm-readOnly-opt
Automatic merge from submit-queue (batch tested with PRs 60696, 60876, 60901, 60925, 60428). 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>.

kubeadm: Add writable option to *ExtraVolumes init config

**What this PR does / why we need it**:
This PR adds `writable` boolean option for each volume under the `apiServerExtraVolumes`, `controllerManagerExtraVolumes` and `schedulerExtraVolumes` kubeadm init config keys. The option controls write access on a per-volume basis. It is inverted and transferred to the corresponding static pod YAML file as the `readOnly` option of kubelet.

The default value for `writable` is `false`, which does not change the current kubeadm behavior.

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

**Special notes for your reviewer**:

/cc @kubernetes/sig-cluster-lifecycle-pr-reviews
/area kubeadm
/assign @luxas
/assign @timothysc

**Release note**:
```release-note
kubeadm: Add the writable boolean option to kubeadm config. The option works on a per-volume basis for *ExtraVolumes config keys.
```
2018-03-20 13:36:25 -07:00
Kubernetes Submit Queue de1a0e3249
Merge pull request #60925 from aleksandra-malinowska/debug-curl-fix
Automatic merge from submit-queue (batch tested with PRs 60696, 60876, 60901, 60925, 60428). 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>.

Improve debug curl command

When logging debug curl command, add single quotes around URL and headers. This prevents quietly removing any parameters after '&' when running resulting command and improves formatting.

```release-note
NONE
```
2018-03-20 13:36:21 -07:00