Commit Graph

74662 Commits

Author SHA1 Message Date
Elijah Oyekunle
805a9e7036 Fixes Golint Errors: staging/src/k8s.io/kube-aggregator (#73369)
* fixed golint errors in staging/src/k8s.io/kube-aggregator

* update openapi

* unexported autoRegisterController
2019-02-11 14:16:05 -08:00
Jingfang Liu
23a9b0c239 vendor kustomize 2019-02-11 14:15:24 -08:00
Kevin Wiesmüller
9082cac482 strip selected fields from managedFields
refactor fieldstrip and update tests

add checks and remove empty fields

shorten test and check for nil manager

fix gofmt

panic on nil manager
2019-02-11 23:10:57 +01:00
Yu-Ju Hong
1bba009689 Fix setting NODE_ARCH and NODE_PLATFORM 2019-02-11 13:55:44 -08:00
Davanum Srinivas
1d430a4a73
Remove unnecessary prefixes from various .import-restrictions files
Found using script:
https://gist.github.com/dims/384dea60754042f61d79233603034038

Just run using:
`find . -name .import-restrictions | xargs python ~/junk/sanitize-import-boss.py`

The removed entries are either packages that got moved/renamed/deleted
but are still not cleaned up from .import-restrictions files.

Change-Id: I92c400f74e6f012cc75539311ed4de280e25e918
2019-02-11 16:47:28 -05:00
Chao Xu
27166e48b8 Loosing the request body size limit to 100MB to account for the size
ratio between json and protobuf.
2019-02-11 11:32:11 -08:00
Jennifer Buckley
1a5e48e29d Honor forceAllowCreate in service registry 2019-02-11 11:05:30 -08:00
Kubernetes Prow Robot
f7c4389b79
Merge pull request #73877 from droslean/nits
apis:core:validation: remove unused, changes to idiomatic go
2019-02-11 10:31:06 -08:00
Kubernetes Prow Robot
6912bbb153
Merge pull request #71223 from sttts/sttts-openapi-aggreation-without-clone
openapi-aggregation: speed up merging from 1 sec to 50-100 ms
2019-02-11 10:30:56 -08:00
Aldo Culquicondor
17a635448a Fix cmd/kubelet/app lint issues 2019-02-11 13:18:25 -05:00
Kubernetes Prow Robot
986399b890
Merge pull request #73899 from dims/update-import-restrictions-cloud-provider
cleanup .import-restrictions for cloud provider
2019-02-11 08:49:20 -08:00
Kubernetes Prow Robot
1e6afac07c
Merge pull request #73701 from rosti/refactor-initcfg-apis
kubeadm: Refactor InitConfiguration init APIs
2019-02-11 08:49:05 -08:00
Kubernetes Prow Robot
836db5c90e
Merge pull request #73893 from neolit123/placeholder-docs
generated_files: remove line about /docs/.generated_docs (fix PR size plugin)
2019-02-11 06:41:12 -08:00
Kubernetes Prow Robot
6671d2556f
Merge pull request #73912 from JoeWrightss/patch-3
Fix fmt.Sprintf error message
2019-02-11 05:15:11 -08:00
Rostislav M. Georgiev
51197e4393 kubeadm: Refactor InitConfiguration init APIs
Currently ConfigFileAndDefaultsToInternalConfig and
FetchConfigFromFileOrCluster are used to default and load InitConfiguration
from file or cluster. These two APIs do a couple of completely separate things
depending on how they were invoked. In the case of

ConfigFileAndDefaultsToInternalConfig, an InitConfiguration could be either
defaulted with external override parameters, or loaded from file.
With FetchConfigFromFileOrCluster an InitConfiguration is either loaded from
file or from the config map in the cluster.

The two share both some functionality, but not enough code. They are also quite
difficult to use and sometimes even error prone.

To solve the issues, the following steps were taken:

- Introduce DefaultedInitConfiguration which returns defaulted version agnostic
  InitConfiguration. The function takes InitConfiguration for overriding the
  defaults.

- Introduce LoadInitConfigurationFromFile, which loads, converts, validates and
  defaults an InitConfiguration from file.

- Introduce FetchInitConfigurationFromCluster that fetches InitConfiguration
  from the config map.

- Reduce, when possible, the usage of ConfigFileAndDefaultsToInternalConfig by
  replacing it with DefaultedInitConfiguration or LoadInitConfigurationFromFile
  invocations.

- Replace all usages of FetchConfigFromFileOrCluster with calls to
  LoadInitConfigurationFromFile or FetchInitConfigurationFromCluster.

- Delete FetchConfigFromFileOrCluster as it's no longer used.

- Rename ConfigFileAndDefaultsToInternalConfig to
  LoadOrDefaultInitConfiguration in order to better describe what the function
  is actually doing.

Signed-off-by: Rostislav M. Georgiev <rostislavg@vmware.com>
2019-02-11 14:45:34 +02:00
Dr. Stefan Schimanski
233178eec6 Update staging godeps 2019-02-11 13:16:37 +01:00
Dr. Stefan Schimanski
f488ed4b82 openapi: add spec roundtrip test 2019-02-11 13:16:37 +01:00
Dr. Stefan Schimanski
8da9b50ebf apiextensions: use canonical empty OpenAPI type 2019-02-11 13:16:37 +01:00
Dr. Stefan Schimanski
e67d5f2d8d apiserver: fix openapi extension types to be JSON 2019-02-11 13:16:37 +01:00
Dr. Stefan Schimanski
01bc4eff0e openapi-aggregation: merge without clones 2019-02-11 13:16:37 +01:00
Dr. Stefan Schimanski
84f0629e95 bump(k8s.io/kube-openapi): c12348ce28de40eed0136aa2b644d0ee0650e56c 2019-02-11 13:16:36 +01:00
Dr. Stefan Schimanski
2fe54a144b Update openapi spec 2019-02-11 13:16:36 +01:00
Dr. Stefan Schimanski
2393799e2e hack/update-openapi-spec.sh: normalize indention of spec through jq 2019-02-11 13:16:36 +01:00
Kubernetes Prow Robot
196047fc28
Merge pull request #73143 from micahhausler/code-generator-godoc-fix
Fixed import-boss godoc comment formatting
2019-02-11 03:53:17 -08:00
Kubernetes Prow Robot
d820b5024e
Merge pull request #70903 from ping035627/k8s-181110
Fix function comment to consistent with its name
2019-02-11 02:43:54 -08:00
Kubernetes Prow Robot
9c72a33685
Merge pull request #73896 from ping035627/k8s-190211
Fix function comment to consistent with its name
2019-02-11 00:53:30 -08:00
zhoulin xie
f71bc19ca8 Fix fmt.Sprintf error message
Signed-off-by: zhoulin xie <zhoulin.xie@daocloud.io>
2019-02-11 16:43:20 +08:00
JoeWrightss
e47b159c76
Merge pull request #1 from kubernetes/master
update from base repository
2019-02-11 15:56:32 +08:00
houjun
a5cde1a463 Check for pvcVolume with IsOperationPending() before markPVCResizeInProgress() 2019-02-11 15:23:17 +08:00
Clayton Coleman
a7dfbb99c4
updates: DaemonSet test should tolerate all taints
The test specifically includes all nodes, but doesn't actually ensure
the daemonset covers all nodes despite taints.
2019-02-10 23:53:57 -05:00
Clayton Coleman
3e0dd7f365
upgrade: ClusterUpgrade and MasterUpgrade are equivalent
Some tests were only checking for MasterUpgrade, but that is also
implied by ClusterUpgrade.
2019-02-10 23:51:27 -05:00
Kubernetes Prow Robot
69cf2684bb
Merge pull request #73669 from WanLinghao/add_get_case
Add a case to illustrate how to use `kubectl get -o custom-columns`
2019-02-10 20:47:26 -08:00
Davanum Srinivas
9870b74f90
cleanup .import-restrictions for cloud provider
Change-Id: I8f9b8a28474d12d6eb74ecef85a988dd3f1f851e
2019-02-10 22:56:53 -05:00
xiezongzhe
3cec62b3f5
fix typo
Is ->It in line 6
2019-02-11 11:38:25 +08:00
Kubernetes Prow Robot
162b79d2ec
Merge pull request #70931 from m1kola/port-forward-consistency
Fixes inconsistent behaviour in portforward
2019-02-10 19:37:27 -08:00
PingWang
d8e3d11c8b Fix function comment to consistent with its name
Signed-off-by: PingWang <wang.ping5@zte.com.cn>
2019-02-11 10:51:35 +08:00
WanLinghao
e9edbf1d52 Clean unused code in pkg/securitycontext/util.go 2019-02-11 10:30:47 +08:00
danielqsj
342dc93187 fix shellcheck in kube-aggregator 2019-02-11 10:30:34 +08:00
Kubernetes Prow Robot
e47973bd31
Merge pull request #69086 from bruceauyeung/log-useful-info-instead-of-silent-exit-when-etcd-already-installed
log useful information instead of silent exit without error
2019-02-10 18:14:26 -08:00
WanLinghao
de85b7c8a8 Clean deprecated ShowAll variable in PrintOptions 2019-02-11 09:18:40 +08:00
Clayton Coleman
25e0a8f56c
Print the involved object in the event table as resource/name
The involved object is important and only some events include its
name in the message. Change the `Kind` column to `Object` and print
the object in `resource/name` form to allow copy and paste
to `kubectl get`. Also move the source field column to the right
of involved object since it is related.
2019-02-10 20:16:07 -05:00
Lubomir I. Ivanov
e965738244 generated_files: remove line about /docs/.generated_docs 2019-02-11 02:54:45 +02:00
Kubernetes Prow Robot
903cdff633
Merge pull request #73889 from mattjmcnaughton/mattjmcnaughton/improve-client-go-docs
Improve in-cluster-client-conf client-go docs
2019-02-10 16:05:44 -08:00
Kubernetes Prow Robot
3dfb9e8f49
Merge pull request #73888 from smarterclayton/duration
Make CRD column printers consistent with typed printers
2019-02-10 13:50:30 -08:00
Clayton Coleman
49250c6efc
Make container create, start, and stop events consistent
The messages for container lifecycle events are subtly inconsistent
and should be unified.

First, the field format for containers is hard to parse for a human,
so include the container name directly in the message for create
and start, and for kill remove the container runtime prefix.

Second, the pulling image event has inconsistent capitalization, fix
that to be sentence without punctuation.

Third, the kill container event was unnecessarily wordy and inconsistent
with the create and start events. Make the following changes:

* Use 'Stopping' instead of 'Killing' since kill is usually reserved for
  when we decide to hard stop a container
* Send the event before we dispatch the prestop hook, since this is an
  "in-progress" style event vs a "already completed" type event
* Remove the 'cri-o://' / 'docker://' prefix by printing the container
  name instead of id (we already do that replacement at the lower level
  to prevent high cardinality events)
* Use 'message' instead of 'reason' as the argument name since this is a
  string for humans field, not a string for machines field
* Remove the hash values on the container spec changed event because no
  human will ever be able to do anything with the hash value
* Use 'Stopping container %s(, explanation)?' form without periods to
  follow event conventions

The end result is a more pleasant message for humans:

```
35m         Normal    Created                       Pod    Created container
35m         Normal    Started                       Pod    Started container
10m         Normal    Killing                       Pod    Killing container cri-o://installer:Need to kill Pod
10m         Normal    Pulling                       Pod    pulling image "registry.svc.ci.openshift.org/openshift/origin-v4.0-2019-02-10-172026@sha256:3da5303d4384d24691721c1cf2333584ba60e8f82c9e782f593623ce8f83ddc5"
```

becomes

```
35m         Normal    Created                       Pod    Created container installer
35m         Normal    Started                       Pod    Started container installer
10m         Normal    Killing                       Pod    Stopping container installer
10m         Normal    Pulling                       Pod    Pulling image "registry.svc.ci.openshift.org/openshift/origin-v4.0-2019-02-10-172026@sha256:3da5303d4384d24691721c1cf2333584ba60e8f82c9e782f593623ce8f83ddc5"
```
2019-02-10 16:39:42 -05:00
mattjmcnaughton
fb4148e5f8 Improve in-cluster-client-conf client-go docs
Make a small formatting change to make it clear that you must take the
RBAC actions regardless of whether you're using Minikube or not.
2019-02-10 15:19:42 -05:00
Clayton Coleman
6b1a5101c3
Make CRD column printers consistent with typed printers
Almost all other server side printers use duration.HumanDuration
which has higher precision output. Switch CRD printers to use this
as well.
2019-02-10 15:17:58 -05:00
Mikalai Radchuk
4ee2010111 Fixes address parsing in port-forward
The rules for address parsing are:

* Explicitly specified addresses must bind successfully
* `localhost` is pinned to `127.0.0.1` and `::1` and at least one of those must bind successfully

This change also makes output of the command consistent
between runs with the same arguments.
Previously the command was using the range via map of addresses
which sometimes was producing different output because the order
of values is not guaranteed in Go.
2019-02-10 12:48:52 +00:00
Kubernetes Prow Robot
b862590bfc
Merge pull request #73847 from wojtek-t/watch_metric
Add metric exposing amount of processed init events in watchcache
2019-02-10 03:47:35 -08:00
WanLinghao
4a1a2c9017 Add a case to illustrate how to use kubectl get -o custom-columns 2019-02-10 14:42:13 +08:00