Commit Graph

3102 Commits (4cc5d3b9680a2cb22bf312f555b9a619dc8953c9)

Author SHA1 Message Date
Kubernetes Submit Queue f6d0632bbb
Merge pull request #57059 from ericchiang/client-go/remove-openapi-import
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>.

client-go: remove open-api import from types

This builds off of https://github.com/kubernetes/kube-openapi/pull/21 and removes the following imports from `k8s.io/client-go/kubernetes`:

```
github.com/PuerkitoBio/purell
github.com/PuerkitoBio/urlesc
github.com/emicklei/go-restful
github.com/emicklei/go-restful/log
github.com/go-openapi/jsonpointer
github.com/go-openapi/jsonreference
github.com/go-openapi/spec
github.com/go-openapi/swag
github.com/mailru/easyjson/buffer
github.com/mailru/easyjson/jlexer
github.com/mailru/easyjson/jwriter
golang.org/x/text/cases
golang.org/x/text/internal
golang.org/x/text/internal/tag
golang.org/x/text/language
golang.org/x/text/runes
golang.org/x/text/secure/precis
golang.org/x/text/width
k8s.io/kube-openapi/pkg/common
```

/assign @sttts 
/assign @mbohlool 

cc @kubernetes/sig-api-machinery-pr-reviews 


```release-note
NONE
```
2018-01-12 01:26:16 -08:00
Kubernetes Submit Queue 67a5a26673
Merge pull request #56660 from hzxuzhonghu/recommened-admission
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 admission into RecommendedOptions

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

make admission part of the RecommendedOptions

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-01-11 21:20:39 -08:00
Eric Chiang e1dda7e3be bump(k8s.io/kube-openapi): a07b7bbb58e7fdc5144f8d7046331d29fc9ad3b3 2018-01-11 09:33:27 -08:00
Eric Chiang eb0ac60175 remove OpenAPI import from types 2018-01-11 09:27:26 -08:00
Kubernetes Submit Queue 4a77bd53e8
Merge pull request #57259 from ericchiang/client-go-no-cache-import
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>.

client-go: remove import of github.com/gregjones/httpcache

Moves NewCacheRoundTripper from `k8s.io/client-go/transport` to its own package. This prevents Kubernetes clients from requiring its dependencies.

This change removes the following transitive imports from `k8s.io/client-go/kubernetes`

```
github.com/google/btree
github.com/gregjones/httpcache
github.com/gregjones/httpcache/diskcache
github.com/peterbourgon/diskv
```


```release-note
NONE
```
2018-01-11 01:25:50 -08:00
Kubernetes Submit Queue eba10f1ea1
Merge pull request #58091 from deads2k/client-01-scale
Automatic merge from submit-queue (batch tested with PRs 57823, 58091, 58093, 58096, 57020). 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>.

manually handle encoding and decoding in the scale client

@p0lyn0mial I think this resolves the problems you're seeing in https://github.com/kubernetes/kubernetes/pull/57843 by manually controlling the encode and decode in the client itself.



/assign @DirectXMan12
2018-01-10 12:37:41 -08:00
Kubernetes Submit Queue bc56a90e0b
Merge pull request #58062 from lcfang/fixurl-0110
Automatic merge from submit-queue (batch tested with PRs 58025, 57112, 57879, 57571, 58062). 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>.

fixed some bad url

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

fixed some bad url

**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-01-10 11:46:52 -08:00
Kubernetes Submit Queue 4bc286f025
Merge pull request #57571 from spiffxp/mk-staging-repos-authoritative
Automatic merge from submit-queue (batch tested with PRs 58025, 57112, 57879, 57571, 58062). 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>.

Treat staging repos as authoritative source for all files

Add CONTRIBUTING.md files to remind people not to PR directly into the published repos.

/hold
I believe this requires removing these files from the published repos if any copies exist there

ref: kubernetes/kubernetes#57559
2018-01-10 11:46:49 -08:00
Kubernetes Submit Queue 6f3e39ec94
Merge pull request #58025 from caesarxuchao/default-webhook
Automatic merge from submit-queue (batch tested with PRs 58025, 57112, 57879, 57571, 58062). 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>.

Let mutating webhook defaults the object

...after applying the patch sent back by the webhook

This should be treated as a bug and cherrypicked to 1.9.

Fixes #57982
2018-01-10 11:46:40 -08:00
David Eads 877143e547 manuallly handle encoding and decoding in the scale client 2018-01-10 12:11:17 -05:00
lcfang 713e28874a fixed some bad url 2018-01-10 22:05:00 +08:00
Kubernetes Submit Queue b4ad7e6e38
Merge pull request #58003 from antoineco/gen-cli-logtostderr
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>.

Make code generators log to stderr by default

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

Most code generators inside `staging/` are CLI tools. It makes sense for CLI tools (in general) to log to stdout/err, especially knowing that [`glog` has a 30sec flush interval](a227c1ea2c/pkg/kubectl/util/logs/logs.go (L49)), which leads to logs being lost and makes troubleshooting tedious for people not aware of that quirk.

Fixes #53791

```release-note
NONE
```
2018-01-10 03:58:14 -08:00
Kubernetes Submit Queue 5e444bbe12
Merge pull request #57613 from mtaufen/explicit-kubelet-flags
Automatic merge from submit-queue (batch tested with PRs 57733, 57613, 57953). 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>.

Explicit kubelet flags

The Kubelet was using the global flag set.
Libraries also often use the global flag set.
There are flags in the Kubelet's usage statement for which the Kubelet does not control registration.
This is bad, we must have full control of our command-line API.
This PR puts a stop to it.

I worked through the Kubelet's usage printout and tracked down the flags. 

In the below list, flags with checkboxes are one of:
- explicitly **registered** in this PR
- thought about and outright **rejected**
- thought about and **registered-deprecated** for legacy reasons

For the others we need to figure out whether they should be **registered** or **rejected** or **registered-deprecated**. 

### cadvisor:
grep commands, for reference:
```
# flag definitions in cadvisor
git grep -E "\"application_metrics_count_limit\"|\"boot_id_file\"|\"container_hints\"|\"containerd\"|\"docker\"|\"docker_env_metadata_whitelist\"|\"docker_only\"|\"docker_root\"|\"docker-tls\"|\"docker-tls-ca\"|\"docker-tls-cert\"|\"docker-tls-key\"|\"enable_load_reader\"|\"event_storage_age_limit\"|\"event_storage_event_limit\"|\"global_housekeeping_interval\"|\"housekeeping_interval\"|\"log_cadvisor_usage\"|\"machine_id_file\"|\"storage_driver_buffer_duration\"|\"storage_driver_db\"|\"storage_driver_host\"|\"storage_driver_password\"|\"storage_driver_secure\"|\"storage_driver_table\"|\"storage_driver_user\"" -- vendor/github.com/google/cadvisor
# flag invocations
git grep -E "\--application_metrics_count_limit|--boot_id_file|--container_hints|--containerd|--docker|--docker_env_metadata_whitelist|--docker_only|--docker_root|--docker_tls|--docker_tls_ca|--docker_tls_cert|--docker_tls_key|--enable_load_reader|--event_storage_age_limit|--event_storage_event_limit|--global_housekeeping_interval|--housekeeping_interval|--log_cadvisor_usage|--machine_id_file|--storage_driver_buffer_duration|--storage_driver_db|--storage_driver_host|--storage_driver_password|--storage_driver_secure|--storage_driver_table|--storage_driver_user" -- ':(exclude)pkg/generated/bindata.go' ':(exclude)Godeps' ':(exclude)CHANGELOG*' ':(exclude)vendor'
# normalized flag invocations
git grep -E "\--application-metrics-count-limit|--boot-id-file|--container-hints|--containerd|--docker|--docker-env-metadata-whitelist|--docker-only|--docker-root|--docker-tls|--docker-tls-ca|--docker-tls-cert|--docker-tls-key|--enable-load-reader|--event-storage-age-limit|--event-storage-event-limit|--global-housekeeping-interval|--housekeeping-interval|--log-cadvisor-usage|--machine-id-file|--storage-driver-buffer-duration|--storage-driver-db|--storage-driver-host|--storage-driver-password|--storage-driver-secure|--storage-driver-table|--storage-driver-user" -- ':(exclude)pkg/generated/bindata.go' ':(exclude)Godeps' ':(exclude)CHANGELOG*' ':(exclude)vendor'
# flag names
git grep -E "application_metrics_count_limit|boot_id_file|container_hints|containerd|docker|docker_env_metadata_whitelist|docker_only|docker_root|docker_tls|docker_tls_ca|docker_tls_cert|docker_tls_key|enable_load_reader|event_storage_age_limit|event_storage_event_limit|global_housekeeping_interval|housekeeping_interval|log_cadvisor_usage|machine_id_file|storage_driver_buffer_duration|storage_driver_db|storage_driver_host|storage_driver_password|storage_driver_secure|storage_driver_table|storage_driver_user"  ':(exclude)pkg/generated/bindata.go' ':(exclude)Godeps' ':(exclude)CHANGELOG*' ':(exclude)vendor'
# normalized flag names
git grep -E "application-metrics-count-limit|boot-id-file|container-hints|containerd|docker|docker-env-metadata-whitelist|docker-only|docker-root|docker-tls|docker-tls-ca|docker-tls-cert|docker-tls-key|enable-load-reader|event-storage-age-limit|event-storage-event-limit|global-housekeeping-interval|housekeeping-interval|log-cadvisor-usage|machine-id-file|storage-driver-buffer-duration|storage-driver-db|storage-driver-host|storage-driver-password|storage-driver-secure|storage-driver-table|storage-driver-user"  ':(exclude)pkg/generated/bindata.go' ':(exclude)Godeps' ':(exclude)CHANGELOG*' ':(exclude)vendor'
# normalized and underscore names combined
git grep -E "application_metrics_count_limit|boot_id_file|container_hints|containerd|docker|docker_env_metadata_whitelist|docker_only|docker_root|docker_tls|docker_tls_ca|docker_tls_cert|docker_tls_key|enable_load_reader|event_storage_age_limit|event_storage_event_limit|global_housekeeping_interval|housekeeping_interval|log_cadvisor_usage|machine_id_file|storage_driver_buffer_duration|storage_driver_db|storage_driver_host|storage_driver_password|storage_driver_secure|storage_driver_table|storage_driver_user|application-metrics-count-limit|boot-id-file|container-hints|containerd|docker-env-metadata-whitelist|docker-only|docker-root|docker-tls|docker-tls-ca|docker-tls-cert|docker-tls-key|enable-load-reader|event-storage-age-limit|event-storage-event-limit|global-housekeeping-interval|housekeeping-interval|log-cadvisor-usage|machine-id-file|storage-driver-buffer-duration|storage-driver-db|storage-driver-host|storage-driver-password|storage-driver-secure|storage-driver-table|storage-driver-user"  ':(exclude)pkg/generated/bindata.go' ':(exclude)Godeps' ':(exclude)CHANGELOG*' ':(exclude)vendor'
```
- [x]      --docker-root (**registered** - this is used in `cluster/saltbase/salt/kubelet/default`)
- [x]      --housekeeping-interval (**registered** - e2e node tests rely on this (`test/e2e_node/resource_collector.go`))
- [x]      --application-metrics-count-limit (**registered-deprecated** - temporarily register for legacy)
- [x]      --boot-id-file (**registered-deprecated** - temporarily register for legacy)
- [x]      --container-hints (**registered-deprecated** - temporarily register for legacy)
- [x]      --containerd (**registered-deprecated** - temporarily register for legacy)
- [x]      --docker (**registered-deprecated** - temporarily register for legacy)
- [x]      --docker-env-metadata-whitelist (**registered-deprecated** - temporarily register for legacy)
- [x]      --docker-only (**registered-deprecated** - temporarily register for legacy)
- [x]      --docker-tls (**registered-deprecated** - temporarily register for legacy)
- [x]      --docker-tls-ca (**registered-deprecated** - temporarily register for legacy)
- [x]      --docker-tls-cert (**registered-deprecated** - temporarily register for legacy)
- [x]      --docker-tls-key (**registered-deprecated** - temporarily register for legacy)
- [x]      --enable-load-reader (**registered-deprecated** - temporarily register for legacy)
- [x]      --event-storage-age-limit (**registered-deprecated** - the Kubelet overrides the default via the global flagset (`pkg/kubelet/cadvisor/cadvisor_linux.go`), but nothing else in core repo provides)
- [x]      --event-storage-event-limit (**registered-deprecated** - the Kubelet overrides the default via the global flagset (`pkg/kubelet/cadvisor/cadvisor_linux.go`), but nothing else in core repo provides)
- [x]      --global-housekeeping-interval (**registered-deprecated** - temporarily register for legacy)
- [x]      --log-cadvisor-usage (**registered-deprecated** - temporarily register for legacy)
- [x]      --machine-id-file (**registered-deprecated** - temporarily register for legacy)
- [x]      --storage-driver-user (**registered-deprecated** - temporarily register for legacy)
- [x]      --storage-driver-password (**registered-deprecated** - temporarily register for legacy)
- [x]      --storage-driver-host (**registered-deprecated** - temporarily register for legacy)
- [x]      --storage-driver-db (**registered-deprecated** - temporarily register for legacy)
- [x]      --storage-driver-table (**registered-deprecated** - temporarily register for legacy)
- [x]      --storage-driver-secure (**registered-deprecated** - temporarily register for legacy)
- [x]      --storage-driver-buffer-duration (**registered-deprecated** - temporarily register for legacy)

### pkg/apiserver/util/logs:
- [x]      --log-flush-frequency (**registered** - like the glog flags, this is probably useful)

### pkg/credentialprovider/azure/azure_credentials.go:
- [x]      --azure-container-registry-config (**registered** - This isn't quite as straightforward as --google-json-key, because the file it points to isn't static. For now we will just register, and we will deprecate it when there is an alternative. See below comments.)

### pkg/credentialprovider/gcp/jwt.go:
- [x]      --google-json-key (**registered-deprecated** - This is really old legacy stuff to allow kubelets to authenticate with gcr (see: d5e0054eb0). See @liggit's below comment for what should be used instead.)

### pkg/cloudprovider/providers/gce/gce_loadbalancer.go:
- [x]      --cloud-provider-gce-lb-src-cidrs (**rejected** - Kubelet doesn't need to know about the cidrs that were opened in the firewall for the load balancer)

### glog:
I registered all of these, since this logging library is used pretty much everywhere in the Kubelet, and all of its toggles are probably useful.
- [x]      --logtostderr (**registered**)
- [x]      --alsologtostderr (**registered**)
- [x]  -v, --v (**registered**)
- [x]      --stderrthreshold (**registered**)
- [x]      --vmodule (**registered**)
- [x]      --log-backtrace-at (**registered**)
- [x]      --log-dir (**registered**)

### verflag:
This is how you get the Kubelet's version, absolutely necessary to register this.
- [x]      --version (**registered**)

```release-note
The Kubelet now explicitly registers all of its command-line flags with an internal flagset, which prevents flags from third party libraries from unintentionally leaking into the Kubelet's command-line API. Many unintentionally leaked flags are now marked deprecated, so that users have a chance to migrate away from them before they are removed. One previously leaked flag, --cloud-provider-gce-lb-src-cidrs, was entirely removed from the Kubelet's command-line API, because it is irrelevant to Kubelet operation.
```

Thanks to @liggitt for being surprised that we didn't already do this.
Thanks to @dashpole for realizing cadvisor flags were leaked after seeing #55863.
Thanks to @tallclair who recognized this problem a long time ago in #19432.
2018-01-09 21:51:37 -08:00
Michael Taufen 8ec1958667 All Kubelet flags should be explicitly registered
This explicitly registers Kubelet flags from libraries that were
registering flags globally, and stops parsing the global flag set.
In general, we should always be explicit about flags we register
and parse, so that we maintain control over our command-line API.
2018-01-09 17:37:34 -08:00
Chao Xu 5029bb56c4 Let mutating webhook defaults the object after applying the patch sent back by the webhook 2018-01-09 15:58:18 -08:00
Aaron Crickenberger d9b5773101 Treat staging repos as authoritative for all files
Move files from kubernetes/foo root back to
kubernetes/kubernetes/staging/src/k8s.io/foo root

Then:
- add CONTRIBUTING.md for all staging repos
- add .PULL_REQUEST_TEMPLATE to all staging repos
- ignore .github while diffing generated protobuf
2018-01-09 15:18:27 -08:00
Antoine Cotten d8924c1da8
Make code generators log to stderr by default 2018-01-09 13:54:50 +01:00
Kubernetes Submit Queue 55c5d75e5d
Merge pull request #57966 from hzxuzhonghu/rm-apiserver-key-cert
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

update apiextentions-apiserver integration test key/crt

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

apiextentions-apiserver integration test key/crt will expire very soon. If they expire, the test case will fail.

We should fix it before hand.

regenerate it with a very long expire time, like 100 years.

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

We have two choice:
1. remove the certificate 
2. generate a certificate with a very long expire time.
Both is ok, I think.
**Release note**:

```release-note
NONE
```
2018-01-09 02:21:01 -08:00
hzxuzhonghu b0654ffeb8 update apiserver key/crt with a long expire time 2018-01-09 10:05:25 +08:00
Eric Chiang dedeb99c97 generated: update staging godeps 2018-01-08 10:00:13 -08:00
Eric Chiang ea085e0a32 client-go: remove import of github.com/gregjones/httpcache 2018-01-08 09:54:12 -08:00
Kubernetes Submit Queue af78b9bac4
Merge pull request #57864 from hzxuzhonghu/kube-aggregator
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>.

kube-aggregator APIServiceRegistrationController remove watch services 

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

>Currently APIServiceRegistrationController watch service change and find the related APIServices related if any. Then it AddAPIService/RemoveAPIService for APIAggregator.

>I dig into the kube-aggregator and find it no need totally, because AvailableConditionController update
APIServices status when related service or endpoint change. So if APIServiceRegistrationController does not watch services, it will not miss any event for APIServices.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-01-08 05:51:29 -08:00
Kubernetes Submit Queue 51acead084
Merge pull request #57958 from nikhita/sample-controller-crd-validation
Automatic merge from submit-queue (batch tested with PRs 57902, 57958). 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 CustomResourceValidation example in sample-controller

Add `CustomResourceValidation` example in sample-controller.

Addresses the following part of https://github.com/kubernetes/sample-controller/issues/2:

> CRDs support json-schema schemas. These CRDs don't have them. It would be nice to show how to add them

**Release note**:

```release-note
NONE
```

/assign sttts munnerz
2018-01-08 03:18:35 -08:00
Kubernetes Submit Queue 8504591def
Merge pull request #57508 from chechiachang/enable-label-selector-for-client-go-listwatch
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Enable list option modification when create list watch

**What this PR does / why we need it**:
metav1.ListOptions support both field selector and label selector, but the current NewListWatchFromClient in client-go only support field selector.
 It would be helpful to use label selector in client-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-01-08 01:48:13 -08:00
Nikhita Raghunath 74c9efa148 Add CustomResourceValidation example in sample-controller
- Mention the schema in the example CRD.
- Update README and mention about feature gates.
2018-01-08 14:53:14 +05:30
Kubernetes Submit Queue 9f80ae7410
Merge pull request #57940 from mbssaiakhil/patch-6
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 Typo in apiserver README
2018-01-07 21:17:15 -08:00
Kubernetes Submit Queue a2bce0d74e
Merge pull request #56769 from dixudx/forbid_unnamed_context
Automatic merge from submit-queue (batch tested with PRs 57521, 56769). 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>.

forbid unnamed context

**What this PR does / why we need it**:
forbid unnamed contexts with validation

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

**Special notes for your reviewer**:
/assign @sttts @fabianofranz 

**Release note**:

```release-note
forbid unnamed context
```
2018-01-07 11:19:45 -08:00
Joe Betz 6a0c69e971 Fix build and test errors from etcd 3.2.13 upgrade 2018-01-07 08:22:08 -08:00
Joe Betz 71c5f8ab12 Update staging deps for etcd 3.2.13 version bump 2018-01-07 08:22:08 -08:00
weekface ef85265025 tiny fix 2018-01-07 17:49:21 +08:00
M.B.S. Sai Akhil 5e9704572f
Fix Typo in apiserver README 2018-01-07 08:45:11 +05:30
Di Xu 792a229936 forbid unnamed context 2018-01-07 10:52:03 +08:00
hzxuzhonghu 2c438a8f21 update bazel 2018-01-06 13:08:57 +08:00
hzxuzhonghu a3af8e1236 remove useless service watch in APIServiceRegistrationController 2018-01-06 13:08:48 +08:00
David Chang 2780b8f9e4 Enable list option modification when create list watch 2018-01-05 18:04:21 +08:00
Kubernetes Submit Queue 23c87f0ca7
Merge pull request #55218 from chentao1596/optimize-error-nomatchkind
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>.

Print apiVersion info when failed to execute kubectl apply -f XXX.yaml

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

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

**Special notes for your reviewer**:

**Release note**:

```release-note

```
2018-01-04 20:43:20 -08:00
chentao1596 42bd794654 fix-bug: version info should be printed when failed to execute 'kubectl apply -f XXXXX' 2018-01-05 09:49:02 +08:00
ymqytw 51f033a4f1 fix bug of swallowing missing merge key error 2018-01-04 16:53:42 -08:00
Davanum Srinivas c258d4df84 Fix ExternalAddress parsing problem under IPv6
`!strings.Contains(host, ":")` will fail miserably under ipv6
2018-01-04 15:04:36 -05:00
Kubernetes Submit Queue 4cadc31965
Merge pull request #57830 from hzxuzhonghu/buf-fix
Automatic merge from submit-queue (batch tested with PRs 56971, 57570, 57830, 57742). 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 possible panic in kube-aggregator

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

91dc55562c/staging/src/k8s.io/kube-aggregator/pkg/apiserver/handler_proxy.go (L210)

If startup kube-aggregator as a standalone process. `r.proxyTransport ` is uninitialized, so `r.proxyTransport.Dial` will panic.

**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-01-04 08:59:42 -08:00
Kubernetes Submit Queue 541b1103bf
Merge pull request #57821 from hzxuzhonghu/hard-code
Automatic merge from submit-queue (batch tested with PRs 57696, 57821, 56317). 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 hard-coded namespace

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

Since import cycle is solved, should use metav1.Namespace* instead of hard coding.

**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-01-04 03:22:39 -08:00
Kubernetes Submit Queue c634886539
Merge pull request #56615 from hzxuzhonghu/validate-admission-control
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>.

validate admission-control startup param

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

validate admission plugins, if not registered, return err to prevent going on until call AdmissionOptions.ApplyTo.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-01-04 02:02:31 -08:00
hzxuzhonghu 91dc55562c fix possible panic 2018-01-04 15:39:18 +08:00
hzxuzhonghu 8b501cc364 update bazel 2018-01-04 12:23:18 +08:00
hzxuzhonghu 9669acc38e remove hard coding Namespace 2018-01-04 12:23:16 +08:00
hzxuzhonghu 64a7c60e00 validate admission-control param 2018-01-04 10:03:01 +08:00
Kubernetes Submit Queue 46eabb7d91
Merge pull request #56534 from allenpetersen/updateGengo
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Update gengo version to include goimports formatter

Update gengo which now uses goimports to format code and organize imports.

Fixes #55542

**Special notes for your reviewer**:
Updates version of k8s.io/gengo
Takes new dependency on golang.org/x/tools/imports and golang.org/x/tools/go/ast/astutil

**Release Notes**:
```release-note
NONE
```
2018-01-03 17:47:05 -08:00
Kubernetes Submit Queue 4d23873a2f
Merge pull request #57572 from sttts/sttts-move-metrics-md
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>.

metrics: make IMPLEMENTATIONS.md and CONTRIBUTING.md authorative in k/k

Part of https://github.com/kubernetes/kubernetes/issues/57559.
2018-01-03 13:29:41 -08:00
Kubernetes Submit Queue fcabf0263e
Merge pull request #57366 from hzxuzhonghu/cacher-fix
Automatic merge from submit-queue (batch tested with PRs 57366, 57779). 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>.

Cacher stopLock should be unlocked

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

Cacher.Stop should also unlock stopLock when isStopped. 
Lock & Unlock should be paired in any case.

**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-01-03 12:09:32 -08:00
Kubernetes Submit Queue 08bab3b5c2
Merge pull request #55699 from hzxuzhonghu/log
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 comment typo and use wait.Forever

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

fix comment typo and use wait.Forever

**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-01-03 08:36:16 -08:00