Commit Graph

5761 Commits (b2091090fc99c7408eabd483158ddec1d63e59b5)

Author SHA1 Message Date
chentao1596 b31a9ecbb4 Delete redundant symbols 2018-01-17 15:44:56 +08:00
Jordan Liggitt ba09fadecf
Plumb versioned informers to authz config 2018-01-16 23:30:53 -05:00
stewart-yu 528435f8dc improve error message for expired tokens 2018-01-17 09:54:06 +08:00
Cao Shufeng 4e7398b67b remove duplicated import 2018-01-17 09:34:59 +08:00
Kubernetes Submit Queue 47f8d624df
Merge pull request #53220 from medinatiger/dev
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>.

Allow version arg to be optional in "kubeadm upgrade apply"

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

This PR make the version arg optional if --config is specified and .KuberneteVersion is available.

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

**Special notes for your reviewer**:
```release-note
Allow version arg in kubeadm upgrade apply to be optional if config file already have version info
```
2018-01-16 14:16:26 -08:00
Feng Min 8362d7f676 Allow version arg in "kubeadm upgrade apply" optional
It's optional if the config file contain the version information.
2018-01-16 11:28:46 -08:00
Kubernetes Submit Queue e290741719
Merge pull request #58103 from php-coder/describe_group_and_version_fields
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 comments for explaining the group/version fields

**What this PR does / why we need it**:
This PR adds comments for explaining group/version fields. This is my understanding of what @deads2k told me today. Please, correct me if I'm wrong or you see how it can be further improved.

I didn't find where it's documented, so I hope that this PR makes it easy for other new contributors addition of new APIs.

**Release note**:
```release-note
NONE
```

PTAL @deads2k 
CC @simo5
2018-01-15 06:37:36 -08:00
Slava Semushin 8f9cddda32 cmd/kube-apiserver/app/aggregator.go: add comments for explaining the group/version fields. 2018-01-15 14:33:44 +01:00
wackxu cd02f168e6 use shared informers for TokenCleaner controller 2018-01-15 14:56:42 +08:00
lcfang f4f8e6fc30 fix some bad url 2018-01-15 09:49:52 +08:00
Di Xu d7c9ad97e8 Enable ValidatingAdmissionWebhook and MutatingAdmissionWebhook in kubeadm from v1.9 2018-01-14 16:38:31 +08:00
Kubernetes Submit Queue 5043c7ecc5
Merge pull request #55706 from wackxu/bss
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>.

use shared informers for BootstrapSigner controller

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

fix TODO: Switch to shared informers

**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-12 11:42:50 -08:00
wackxu 0ae647bf33 use shared informers for BootstrapSigner controller 2018-01-12 11:50:02 +08:00
Davanum Srinivas ecd6361ff0 Set pids limit at pod level
Add a new Alpha Feature to set a maximum number of pids per Pod.
This is to allow the use case where cluster administrators wish
to limit the pids consumed per pod (example when running a CI system).

By default, we do not set any maximum limit, If an administrator wants
to enable this, they should enable `SupportPodPidsLimit=true` in the
`--feature-gates=` parameter to kubelet and specify the limit using the
`--pod-max-pids` parameter.

The limit set is the total count of all processes running in all
containers in the pod.
2018-01-11 21:22:38 -05:00
Kubernetes Submit Queue 999c2ae871
Merge pull request #57778 from xiangpengzhao/kubeadm-write-path
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 the full path of Kubeconfig files.

**What this PR does / why we need it**:
kubeadm init:
```
[kubeconfig] Wrote KubeConfig file to disk: "admin.conf"
[kubeconfig] Wrote KubeConfig file to disk: "kubelet.conf"
[kubeconfig] Wrote KubeConfig file to disk: "controller-manager.conf"
[kubeconfig] Wrote KubeConfig file to disk: "scheduler.conf"
```

It'd be good to print the path of the KubeConfig files in case users want to view the content of these files.

**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 https://github.com/kubernetes/kubeadm/issues/656

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-01-10 20:08:26 -08:00
Jordan Liggitt f03cdd3851
Fix cadvisor flag registration for cross build 2018-01-10 13:00:28 -05:00
Kubernetes Submit Queue 3af0b57e80
Merge pull request #58018 from deads2k/controller-04-option
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 controller port exposure optional

Makes it possible to disable the http server part of controllers if a user wishes.
2018-01-10 01:26:49 -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
David Eads f416e38a1e make controller port exposure optional 2018-01-09 15:54:39 -05:00
Kubernetes Submit Queue 34d63793fd
Merge pull request #57851 from mtaufen/kc-deprecate-old-security-knobs
Automatic merge from submit-queue (batch tested with PRs 56759, 57851, 56352). 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 some old security controls to KubeletFlags and mark them deprecated

Related to @timstclair's comment: https://github.com/kubernetes/kubernetes/pull/53833#issuecomment-355399163


```release-note
NONE
```
2018-01-09 12:40:37 -08:00
Kubernetes Submit Queue 85e0ed797f
Merge pull request #57984 from ericchiang/kubeadm-token-fix
Automatic merge from submit-queue (batch tested with PRs 56290, 57984). 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: more random tokens

The strategy of hex encoding a random byte array only uses the
following characters:

	0123456789abcdef

Instead of the entire bootstrapping token character set:

	0123456789abcdefghijklmnopqrstuvwxyz

Update the token generation to use the entire character set. This
increases the token secret from 48 bits of entropy to ~82 bits.

256^8 (1.8e+19) vs. 36^16 (7.9e+24).

Noticed this writing https://github.com/kubernetes-incubator/bootkube/pull/663

```release-note
NONE
```

/cc @mattmoyer @luxas
2018-01-09 10:52:33 -08:00
Kubernetes Submit Queue d12de5cd32
Merge pull request #56290 from xiangpengzhao/refactor-ValidateUsages
Automatic merge from submit-queue (batch tested with PRs 56290, 57984). 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>.

Refactoring ValidateUsages for bootstrap tokens.

**What this PR does / why we need it**:
Refactoring and cleanup.

**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 @luxas @jbeda 

**Release note**:

```release-note
NONE
```
2018-01-09 10:52:31 -08:00
Zihong Zheng 623ab15212 [kubeadm] Bump kube-dns to 1.14.8 2018-01-09 10:36:05 -08:00
Michael Taufen 5caf26fa84 Move some old security controls to KubeletFlags and mark them deprecated 2018-01-09 10:18:36 -08:00
Eric Chiang 8debdc1501 kubeadm: more random tokens
The strategy of hex encoding a random byte array only uses the
following characters:

	0123456789abcdef

Instead of the entire bootstrapping token character set:

	0123456789abcdefghijklmnopqrstuvwxyz

Update the token generation to use the entire character set. This
increases the token secret from 48 bits of entropy to ~82 bits.

256^8 (1.8e+19) vs. 36^16 (7.9e+24).
2018-01-09 09:20:25 -08:00
Kubernetes Submit Queue df2428c6dd
Merge pull request #57917 from roberthbailey/kubeadm-owners
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 mikedanese from kubeadm owners since he's no longer actively working on the project

**What this PR does / why we need it**: OWNERS file cleanup.

**Release note**:
```release-note
NONE
```
2018-01-08 14:10:27 -08:00
Kubernetes Submit Queue 6244ff3644
Merge pull request #57784 from rajansandeep/upgradenits
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 `kubeadm upgrade` error while CoreDNS is installed

**What this PR does / why we need it**:
In the scenario when I have CoreDNS installed via `kubeadm init` and I want to continue using CoreDNS after `kubeadm upgrade`, the upgrade is unsuccessful and it gives an error.

**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 kubernetes/kubeadm#641

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-01-08 08:28:01 -08:00
Kubernetes Submit Queue 50a641d3b5
Merge pull request #57034 from ingvagabund/remove-mention-of-experimental-on-containerized-kubelet
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>.

Containerized kubelet is no longer experimental

Blocked by https://github.com/kubernetes/kubernetes/pull/56250

Given the node e2e Conformance tests over containerized ``Kubelet`` are already running and are published at https://k8s-testgrid.appspot.com/sig-node-kubelet#kubelet-containerized-conformance-aws-e2e-rhel, we can remove all mentions of the "experimental" keyword.

Are there any other place where the "containerized Kubelet" is mentioned as experimental?
  
```release-note
NONE
```
2018-01-08 07:41:41 -08:00
Sandeep Rajan 9d7b74658d include kube-dns deployment check
ignore 404 error
2018-01-08 20:16:15 +05:30
Jan Chaloupka 93602cd823 Containerized kubelet is no longer experimental 2018-01-08 12:50:35 +01:00
Kubernetes Submit Queue bd4d511a40
Merge pull request #57852 from misterikkit/moveScheduler
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>.

Move scheduler out of plugin directory

**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)*:
This is but one step toward resolving the referenced issue.
/ref #57579

**Special notes for your reviewer**:

**Release note**:

```release-note
Default scheduler code is moved out of the plugin directory.
plugin/pkg/scheduler -> pkg/scheduler
plugin/cmd/kube-scheduler -> cmd/kube-scheduler
```
/sig scheduling
2018-01-05 22:20:13 -08:00
Kubernetes Submit Queue 70e6f45eee
Merge pull request #56084 from andrewsykim/kubeadm/400
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>.

kubeadm: set kube-apiserver advertise address using downward API

**What this PR does / why we need it**:
Sets kube-apiserver --advertise-address using downward API for self-hosted Kubernetes with kubeadm. 

**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 # https://github.com/kubernetes/kubeadm/issues/400

**Special notes for your reviewer**:
@luxas mentioned something about losing the ability to customize advertise address via kubeadm, didn't really take that into consideration yet but I can definitely make the necessary changes if needed. 

**Release note**:
```release-note
kubeadm: set kube-apiserver advertise address using downward API
```
2018-01-05 15:05:50 -08:00
Jonathan Basseri 85c5862552 Fix scheduler refs in BUILD files.
Update references to moved scheduler code.
2018-01-05 15:05:01 -08:00
Jonathan Basseri 30b89d830b Move scheduler code out of plugin directory.
This moves plugin/pkg/scheduler to pkg/scheduler and
plugin/cmd/kube-scheduler to cmd/kube-scheduler.

Bulk of the work was done with gomvpkg, except for kube-scheduler main
package.
2018-01-05 15:05:01 -08:00
Robert Bailey 761decc3b5 Remove mikedanese from kubeadm owners since he's no longer
actively working on the project.
2018-01-05 14:46:14 -08:00
Robert Pothier 12301ae319 Kubeadm: clean up MarshalToYamlForCodecs
Proxy will use PrintBytesWithLinePrefix to indent.
2018-01-05 14:38:42 -05:00
Kubernetes Submit Queue e7070354fe
Merge pull request #57492 from cheftako/node-controller
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>.

Split the NodeController into lifecycle and ipam pieces.

**What this PR does / why we need it**: Separates node controller into ipam and lifecycle components. 

    Prepatory work for removing cloud provider dependency from node
    controller running in Kube Controller Manager. Splitting the node
    controller into its two major pieces life-cycle and CIDR/IP
    management. Both pieces currently need the the cloud system to do their work.
    Removing lifecycles dependency on cloud will be fixed ina followup PR.
    
    Moved node scheduler code to live with node lifecycle controller.
    Got the IPAM/Lifecycle split completed. Still need to rename pieces.
    Made changes to the utils and tests so they would be in the appropriate
    package.
    Moved the node based ipam code to nodeipam.
    Made the relevant tests pass.
    Moved common node controller util code to nodeutil.
    Removed unneeded pod informer sync from node ipam controller.


**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 #https://github.com/kubernetes/kubernetes/issues/52369

**Special notes for your reviewer**:

**Release note**:
```release-note
None
```
2018-01-05 07:52:43 -08:00
Kubernetes Submit Queue afbbd394c1
Merge pull request #57517 from verb/paws-bump
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>.

Bump pause container used by kubelet and tests to 3.1

This updates the version of the pause container used by the kubelet and
various test utilities to 3.1.

**What this PR does / why we need it**: The pause container hasn't been rebuilt in quite a while and needs an update to reap zombies (#50865) and for schema2 manifest (#56253).

**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 #50865, Fixes #56253

**Special notes for your reviewer**:

**Release note**:

```release-note
The kubelet uses a new release 3.1 of the pause container with the Docker runtime. This version will clean up orphaned zombie processes that it inherits.
```
2018-01-04 17:06:48 -08:00
Walter Fender 9187b343e1 Split the NodeController into lifecycle and ipam pieces.
Prepatory work fpr removing cloud provider dependency from node
controller running in Kube Controller Manager. Splitting the node
controller into its two major pieces life-cycle and CIDR/IP
management. Both pieces currently need the the cloud system to do their work.
Removing lifecycles dependency on cloud will be fixed ina followup PR.

Moved node scheduler code to live with node lifecycle controller.
Got the IPAM/Lifecycle split completed. Still need to rename pieces.
Made changes to the utils and tests so they would be in the appropriate
package.
Moved the node based ipam code to nodeipam.
Made the relevant tests pass.
Moved common node controller util code to nodeutil.
Removed unneeded pod informer sync from node ipam controller.
Fixed linter issues.
Factored in  feedback from @gmarek.
Factored in feedback from @mtaufen.
Undoing unneeded change.
2018-01-04 12:48:08 -08:00
Lee Verberne 1ea697044a Update pause container version to 3.1
This updates the version of the pause container used by the kubelet and
various test utilities to 3.1.

This also adds a CHANGELOG.md for build/pause
2018-01-04 11:35:29 +01: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 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 cbdfed1ebe
Merge pull request #57770 from mtaufen/fix-kc-flag-defaults
Automatic merge from submit-queue (batch tested with PRs 57572, 57512, 57770). 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>.

More default fixups for Kubelet flags

Similar to #57621, this fixes some other Kubelet flags that were
defaulted wrong.


```release-note
NONE
```
2018-01-03 13:46:35 -08:00
Kubernetes Submit Queue d8d680be6e
Merge pull request #57797 from kargakis/i-can-do-reviews
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 myself in kubeadm reviewers

/cc @luxas @roberthbailey
2018-01-03 11:15:41 -08:00
Michalis Kargakis dddee91392
Add myself in kubeadm reviewers 2018-01-03 17:17:39 +01:00
Michael Taufen 300ceadf39 More default fixups for Kubelet flags
Similar to #57621, this fixes some other Kubelet flags that were
defaulted wrong.
2018-01-03 07:13:37 -08:00
Allen Petersen 3d69cea1e5 Update generated files 2018-01-02 22:13:19 -08:00
Kubernetes Submit Queue 900177d033
Merge pull request #57621 from mtaufen/fix-podcidr-flag
Automatic merge from submit-queue (batch tested with PRs 57746, 57621, 56839, 57464). 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 PodCIDR flag: defaults come from the object, not as literal args to the flag function

The defaulter runs on the object before adding flags. Flags should be registered with defaults sourced from this object, so that the defaulter, not the flag var function, determines the canonical default value.

```release-note
NONE
```
2018-01-02 15:26:42 -08:00
Kubernetes Submit Queue 5aacc8e06d
Merge pull request #57624 from mtaufen/kc-file-arg
Automatic merge from submit-queue (batch tested with PRs 57651, 56411, 56779, 57523, 57624). 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>.

Replace --init-config-dir with --config

Rather than a directory with magic names, just give the Kubelet a file path.
Was originally in #55718, but I'm splitting it out for clarity.

Fixes #57763

```release-note
The alpha `--init-config-dir` flag has been removed. Instead, use the `--config` flag to reference a kubelet configuration file directly.
```
2018-01-02 14:09:51 -08:00
Kubernetes Submit Queue f4bfcba0c8
Merge pull request #56411 from supereagle/authentication-client-with-version
Automatic merge from submit-queue (batch tested with PRs 57651, 56411, 56779, 57523, 57624). 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>.

Use authentication client with explicit version

**What this PR does / why we need it**:
Authentication client without explicit version has been deprecated, change them to the one with explicit version.

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

**Special notes for your reviewer**:
/cc @caesarxuchao @sttts

**Release note**:
```release-note
NONE
```
2018-01-02 14:09:43 -08:00
Kubernetes Submit Queue f5d5d18b2c
Merge pull request #57340 from jmcmeek/jmcmeek_57044
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 garbage collector when leader-elect=false

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

In a 1.8.x master with --leader-elect=false, the garbage collector controller
does not work.

When deleting a deployment with v1meta.DeletePropagationForeground, the deployment
had its deletionTimestamp set and a foreground Deletion finalizer was added,
but the deployment, rs and pod were not deleted.

This is an issue with how the garbage collector graph_builder behaves when the
stopCh=nil.  This PR creates a dummy stop channel for the garbage collector controller (and other
controllers started by the controller-manager) so that they can work more like they do when
when the controller-manager is configured with --leader-elect=true.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
Fix garbage collection when the controller-manager uses --leader-elect=false
```
2018-01-02 11:45:25 -08:00
Andy Goldstein fa3fb91a76 kube-proxy: fix field name comments & json tags
Signed-off-by: Andy Goldstein <andy.goldstein@gmail.com>
2018-01-02 10:20:43 -05:00
Christoph Blecker 80e344644e
Regenerate all generated code 2018-01-02 00:21:07 -08:00
xiangpengzhao 38a8c72f8a Print the full path of Kubeconfig files. 2018-01-02 14:33:48 +08:00
Michael Taufen 96f30d49dc Replace --init-config-dir with --config 2017-12-26 19:38:30 -06:00
andrewsykim 49e01b05e7 kubeadm: set kube-apiserver advertise address using downward API 2017-12-26 14:41:07 -05:00
Kubernetes Submit Queue 18758f502c
Merge pull request #57594 from m1093782566/hairpin
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 incorrect hairpin-mode value and validate it

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

* Fix incorrect hairpin-mode value 

* Add validation

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-12-26 03:59:59 -08:00
Kubernetes Submit Queue 025886a8bf
Merge pull request #57231 from xiangpengzhao/remove-wkl
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 unused well_known_labels in kubeadm.

**What this PR does / why we need it**:
Cleanup. This is no longer used.

fixes: https://github.com/kubernetes/kubeadm/issues/615

**Release note**:

```release-note
NONE
```
2017-12-26 03:21:15 -08:00
xiangpengzhao 347cdcf198 Auto generated BUILD files. 2017-12-26 10:38:49 +08:00
xiangpengzhao 926baf5fe7 Refactoring ValidateUsages for for bootstrap tokens. 2017-12-26 10:38:49 +08:00
Michael Taufen 392903c9f3 Fix PodCIDR flag: defaults come from the object, not as literal args to the flag function 2017-12-25 19:12:08 -06:00
Kubernetes Submit Queue 980a5e80b1
Merge pull request #57132 from zjj2wry/kube-schedule-initflag
Automatic merge from submit-queue (batch tested with PRs 55483, 57132). 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>.

enhance kube-schedule init flag

**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)*:
```
remove TODO: once we switch everything over to Cobra commands, we can go back to calling
utilflag.InitFlags() (by removing its pflag.Parse() call). 
For now, we have to set the normalize func and add the go flag set by hand.
```

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-12-25 10:53:28 -08:00
Kubernetes Submit Queue 0f210153f7
Merge pull request #55483 from xiangpengzhao/kubeadm-test
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 test case for RunCreateToken

**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)*:
ref: https://github.com/kubernetes/kubernetes/pull/55377#discussion_r149910681

**Special notes for your reviewer**:
/cc @luxas
**Release note**:

```release-note
none
```
2017-12-25 10:32:25 -08:00
Di Xu 1c715d51c4 some code change
fix wrong required flags

disable the addition of [flags] to the usage, use customized useline

fix function rename
2017-12-25 16:23:38 +08:00
m1093782566 120a23a025 update kubeadm validation test to fix test error 2017-12-25 11:37:55 +08:00
xiangpengzhao 8b2da625fe Fix kubeadm upgrade unit test failure. 2017-12-25 10:53:33 +08:00
xiangpengzhao 205cbf470e Update DNS version in kubeadm of 1.10 cycle. 2017-12-25 09:13:36 +08:00
Jeff Grafton 46e894bfd3 Switch go binaries from (hacky) static to pure Go 2017-12-23 13:13:09 -08:00
Jeff Grafton efee0704c6 Autogenerate BUILD files 2017-12-23 13:12:11 -08:00
Tim Hockin e9dd8a68f6 Revert k8s.gcr.io vanity domain
This reverts commit eba5b6092a.

Fixes https://github.com/kubernetes/kubernetes/issues/57526
2017-12-22 14:36:16 -08:00
Kubernetes Submit Queue 09b5e8f411
Merge pull request #57207 from cimomo/kubeadm-fixes
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>.

Improve error messages and comments in KubeAdm.

**What this PR does / why we need it**:
Improve error messages and comments in KubeAdm.

**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
```
2017-12-22 06:56:13 -08:00
Kubernetes Submit Queue cfdf8ae231
Merge pull request #56565 from stewart-yu/fixTextErrorKubeadm
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 minor err in kubeadm

**What this PR does / why we need it**:
fix minor text error in kubeadm.

**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
```
2017-12-22 06:12:38 -08:00
Kubernetes Submit Queue 7e22151db7
Merge pull request #57358 from ericchiang/kubeadm-upgrade/unit-test-fix
Automatic merge from submit-queue (batch tested with PRs 57139, 57358). 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 upgrade: fix unit test flake

The CA generated for each test case is global and the cases modify
the expiry. This can flake depending on what order the tests run.

Generate a new CA for each test case.

```release-note
NONE
```

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

/cc @kubernetes/sig-cluster-lifecycle-bugs 
/cc @xiangpengzhao
/cc @luxas
2017-12-22 06:04:29 -08:00
Kubernetes Submit Queue 6730a6e927
Merge pull request #57139 from bistros/master
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>.

fixed typo in kubeadm/v1alpha1/defaults.go

**What this PR does / why we need it**:
fixed some typo in comment

**Release note**:

```release-note
NONE
```
2017-12-22 05:27:04 -08:00
Kubernetes Submit Queue 49a3eed10c
Merge pull request #57235 from xiangpengzhao/update-apps-ver
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>.

Use apps/v1 API in kubeadm

**What this PR does / why we need it**:
The core workloads API has been promoted to GA stability in the apps/v1 group version from 1.9. Use apps/v1 API in kubeadm.

**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 https://github.com/kubernetes/kubeadm/issues/596

**Special notes for your reviewer**:
/cc @kubernetes/sig-cluster-lifecycle-pr-reviews

**Release note**:

```release-note
NONE
```
2017-12-22 04:33:47 -08:00
Kubernetes Submit Queue 90b12413f2
Merge pull request #57296 from xiangpengzhao/update-coredns-corefile
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 CoreDNS version and Corefile in kubeadm

**What this PR does / why we need it**:
We bumped CoreDNS version to 1.0.0 (#56802) and added CoreDNS as an optional addon in kube-up (#55728), but something wrt log was missed.  The log option of CoreDNS was changed since 1.0.0. We should update the Corefile to reflect the change.

**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 https://github.com/kubernetes/kubernetes/issues/57277

ref: https://github.com/coredns/coredns/issues/1218 https://github.com/coredns/coredns/pull/1221

**Special notes for your reviewer**:
/cc @luxas @rajansandeep
cc @fturib @johnbelamaric

**Release note**:

```release-note
NONE
```
2017-12-21 09:49:22 -08:00
Kubernetes Submit Queue 2a1cdfffaa
Merge pull request #57221 from mtaufen/kc-event
Automatic merge from submit-queue (batch tested with PRs 57434, 57221, 57417, 57474, 57481). 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>.

Send an event just before the Kubelet restarts to use a new config

**What this PR does / why we need it**:
This PR makes the Kubelet send events for configuration changes. This makes it much easier to see a recent history of configuration changes for the Kubelet. 

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

**Special notes for your reviewer**:

**Release note**:
```release-note
NONE
```

/cc @dchen1107 @liggitt @dashpole
2017-12-20 17:42:37 -08:00
Michael Taufen d5d7d6d684 Send an event just before the Kubelet restarts to use a new config 2017-12-20 13:02:55 -08:00
Kubernetes Submit Queue 5e4ff8ac54
Merge pull request #52371 from cheftako/external
Automatic merge from submit-queue (batch tested with PRs 56716, 52371). 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>.

Separate loop and plugin control

**What this PR does / why we need it**: Separate loop and plugin control in the kube-controller-manager.
Adding an "--external-plugin" flag to specify a plugin to load when
cloud-provider is set to "external". Flag has no effect currently
when the cloud-provider is not set to external. The expectation is
that the cloud provider and external plugin flags would go away once
all cloud providers are on stage 2 cloud-controller-manager solutions.

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

**Special notes for your reviewer**:

**Release note**:
```release-note Added --external-plugin flag to kube-controller-manager to determine plugin when --cloud-provider is set to external.
```
2017-12-19 12:55:38 -08:00
xiangpengzhao 8c8cdfe7b7 Update CoreDNS version and Corefile. 2017-12-19 12:10:02 +08:00
xiangpengzhao 88f609fe4d Auto generate BUILD files. 2017-12-19 11:44:19 +08:00
xiangpengzhao 7d919fbd0c Use apps/v1 API in kubeadm. 2017-12-19 11:44:19 +08:00
Eric Chiang eab0e37a63 kubeadm upgrade: fix unit test
The CA generated for each test case is global and the cases modify
the expiry. This can flake depending on what order the tests run.

Generate a new CA for each test case.
2017-12-18 15:35:31 -08:00
Walter Fender 070a7b5823 Seperate loop and plugin control
Seperate loop and plugin control in the kube-controller-manager.
Adding an "--external-plugin" flag to specify a plugin to load when
cloud-provider is set to "external". Flag has no effect currently
when the cloud-provider is not set to external. The expectation is
that the cloud provider and external plugin flags would go away once
all cloud providers are on stage 2 cloud-controller-manager solutions.

Managing the control loops more directly based on start up flags.
Addressing issue brought up by @wlan0

Switched to using the main node controller in CCM.
Changes to enable full NodeController to start in CCM.
Fix related tests.
Unifying some common code between KCM and CCM.
Fix related tests and comments.
Folded in feedback from @jhorwit2 and @wlan0
2017-12-18 10:58:45 -08:00
John McMeeking 880a68ade6 Fix garbage collector when leader-elect=false
**What this PR does / why we need it**:

In a 1.8.x master with --leader-elect=false, the garbage collector controller
does not work.

When deleting a deployment with v1meta.DeletePropagationForeground, the deployment
had its deletionTimestamp set and a foreground Deletion finalizer was added,
but the deployment, rs and pod were not deleted.

This is an issue with how the garbage collector graph_builder behaves when the
stopCh=nil.  This PR creates a dummy stop channel for the garbage collector controller (and other
controllers started by the controller-manager) so that they can work more like they do when
when the controller-manager is configured with --leader-elect=true.

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

**Special notes for your reviewer**:

**Release note**:
<!--  Write your release note:
1. Enter your extended release note in the below block. If the PR requires additional action from users switching to the new release, include the string "action required".
2. If no release note is required, just write "NONE".
-->
```release-note
Garbage collection doesn't work when the controller-manager uses --leader-elect=false

```
2017-12-18 11:39:51 -06:00
Tim Hockin eba5b6092a Use k8s.gcr.io vanity domain for container images 2017-12-18 09:18:34 -08:00
Kubernetes Submit Queue 035ff73f7b
Merge pull request #56294 from xiangpengzhao/kubeadm-minor-cleanup
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>.

Minor cleanup in kubeadm.

```release-note
NONE
```
2017-12-18 03:10:27 -08:00
stewart-yu f41f1887e2 Fix minor err in kubeadm 2017-12-18 18:36:06 +08:00
Kubernetes Submit Queue a35ac9e8fc
Merge pull request #57305 from xiangpengzhao/update-addon-kubeproxy
Automatic merge from submit-queue (batch tested with PRs 57287, 57233, 57305). 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 kube-proxy 1.8 configmap and daemonset manifests in kubeadm

**What this PR does / why we need it**:
Remove unsupported manifests of kube-proxy in kubeadm of 1.10.

**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 @kubernetes/sig-cluster-lifecycle-pr-reviews 

**Release note**:

```release-note
NONE
```
2017-12-18 02:19:36 -08:00
Kubernetes Submit Queue a6891528a7
Merge pull request #57233 from xiangpengzhao/kubeadm-support-version
Automatic merge from submit-queue (batch tested with PRs 57287, 57233, 57305). 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 kubeadm's minimum supported kubernetes to 1.9.

**What this PR does / why we need it**:
Update it in 1.10 cycle.

**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 @kubernetes/sig-cluster-lifecycle-pr-reviews

**Release note**:

```release-note
Update kubeadm's minimum supported Kubernetes version in v1.10.x to v1.9.0
```
2017-12-18 02:19:33 -08:00
xiangpengzhao 9c9ac106b8 Auto generated BUILD files. 2017-12-18 15:17:29 +08:00
xiangpengzhao 0de49c461f Remove kube-proxy 1.8 configmap and daemonset manifests in kubeadm. 2017-12-18 15:17:17 +08:00
Matt Kelly 41a4db7f48 kubeadm: Only check for well-known files in preflight 2017-12-17 13:41:15 -05:00
Kubernetes Submit Queue 94327c5f72
Merge pull request #56754 from dims/remove-hacks-for-mesos
Automatic merge from submit-queue (batch tested with PRs 57127, 57011, 56754, 56601, 56483). 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 hacks added for mesos

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

Since Mesos is no longer in your main repository and since we have
things like dynamic kubelet configuration in progress, we should
drop these undocumented, untested, private hooks.

cmd/kubelet/app/server.go::CreateAPIServerClientConfig
CreateAPIServerClientConfig::getRuntime
pkg/kubelet/kubelet_pods.go::getPhase

Also remove stuff from Dependencies struct that were specific to
the Mesos integration (ContainerRuntimeOptions and Options)

Also remove stale references in test/e2e and and test owners 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)*:
Fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
Drop hacks used for Mesos integration that was already removed from main kubernetes repository
```
2017-12-17 06:25:56 -08:00
Kubernetes Submit Queue 3e2de4e427
Merge pull request #56828 from oracle/for/upstream/master/ccm-lock-id
Automatic merge from submit-queue (batch tested with PRs 56828, 55184, 56849, 57081, 56654). 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>.

Use hostname for CCM resource lock id

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

Uses the hostname for the resource lock id without the `-external-cloud-controller` which follows how the kube-scheduler and KCM select their ID. This is useful for tools that use the id to fetch logs from the leader among other things. 

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/cc @wlan0 @luxas
2017-12-16 17:45:38 -08:00
Kubernetes Submit Queue d936754269
Merge pull request #56287 from stewart-yu/removeDeprecatedCode
Automatic merge from submit-queue (batch tested with PRs 54902, 56831, 56702, 56287, 56878). 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 kubelet's `--cloud-provider=auto-detect` feature

**What this PR does / why we need it**:
 Set no cloud provider as the default in kubelet, remove deprecated explain and variable.
This PR covers step 3:
 `v1.10 - completely remove the option to use auto-detect`

For more details [https://github.com/kubernetes/kubernetes/issues/50986](https://github.com/kubernetes/kubernetes/issues/50986)

**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 [https://github.com/kubernetes/kubernetes/issues/50986](https://github.com/kubernetes/kubernetes/issues/50986)

**Special notes for your reviewer**:

**Release note**:

```release-note
[action required] Remove the kubelet's `--cloud-provider=auto-detect` feature
```
2017-12-16 09:33:42 -08:00
Kubernetes Submit Queue b3cbfed4d8
Merge pull request #56812 from dims/drop-using-cloud-provider-for-setting-host-address
Automatic merge from submit-queue (batch tested with PRs 56250, 56809, 56812, 56792, 56724). 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>.

Drop using cloud provider to set host address feature

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

Follow up to PR #54516, also see notice to -dev@ : 
https://groups.google.com/forum/#!topic/kubernetes-dev/2NaxUCSbIw8

**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
kube-apiserver: The external hostname no longer longer use the cloud provider API to select a default. It can be set explicitly using --external-hostname, if needed.
```
2017-12-16 07:46:43 -08:00
Kubernetes Submit Queue e1ee105bba
Merge pull request #56410 from stewart-yu/cloudeprovider-fixcloudnil
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>.

If cloud==nil, it should exits to avoid Panic

**What this PR does / why we need it**:
If `cloud == nil`, it should exits, otherwise `cloud.HasClusterID()` 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
```
2017-12-16 04:11:02 -08:00
Kubernetes Submit Queue 6ca0bdd455
Merge pull request #55572 from wackxu/altname
Automatic merge from submit-queue (batch tested with PRs 56390, 56334, 55572, 55598, 56563). 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 apiServerCertSANs case for test GetAltNames

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

When fix #55566 , found there is not test case for apiServerCertSANs 

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

assgin @luxas 

**Release note**:

```release-note
NONE
```
2017-12-15 22:51:43 -08:00
Kubernetes Submit Queue bb94058b4f
Merge pull request #56390 from m1093782566/test-mode
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>.

Test Proxy Mode

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

Currently, IPVS-based kube-proxy is protected by feature gateway and there is no UT for it. We should test ipvs proxy mode when feature gateway is set.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-12-15 21:59:32 -08:00
xiangpengzhao ed4c51053e Update kubeadm's minimum supported kubernetes to 1.9. 2017-12-16 10:56:55 +08:00
Kubernetes Submit Queue 139048d2a4
Merge pull request #56364 from stewart-yu/codeClean
Automatic merge from submit-queue (batch tested with PRs 56308, 54304, 56364, 56388, 55853). 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>.

should check return err

**What this PR does / why we need it**:
It should check  errors and remove redundancy 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
```
2017-12-15 02:04:40 -08:00
xiangpengzhao 02dabb84eb Remove unused well_known_labels in kubeadm. 2017-12-15 14:59:05 +08:00
Kubernetes Submit Queue 2d57d9b1ea
Merge pull request #56146 from jiulongzaitian/style_code
Automatic merge from submit-queue (batch tested with PRs 57172, 55382, 56147, 56146, 56158). 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>.

delete useless params containerized

Signed-off-by: zhangjie <zhangjie0619@yeah.net>



**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
     delete useless params containerized
```
2017-12-14 12:38:19 -08:00
Kai Chen 67cf959a1d Improve error messages and comments in KubeAdm. 2017-12-14 11:11:58 -08:00
zhengjiajin ffbfd81c06 remove dependency from cobra, only use option test init flag 2017-12-14 17:31:49 +08:00
Kubernetes Submit Queue bf6907c509
Merge pull request #55900 from cimomo/small-fixes
Automatic merge from submit-queue (batch tested with PRs 55900, 55995, 55913, 55467, 55376). 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 a typo in kubeadm/GetEtcdPodSpec

**What this PR does / why we need it**:
Fix a typo in kubeadm/GetEtcdPodSpec.

**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
```
2017-12-14 00:45:12 -08:00
Kubernetes Submit Queue 32ecf25264
Merge pull request #54994 from xiangpengzhao/kubeadm-val-test
Automatic merge from submit-queue (batch tested with PRs 55954, 56037, 55866, 55984, 54994). 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 kubeadm validation unit test coverage.

**What this PR does / why we need it**:
From:
`ok  	k8s.io/kubernetes/cmd/kubeadm/app/apis/kubeadm/validation	0.100s	coverage: 92.3% of statements`
To:
`ok  	k8s.io/kubernetes/cmd/kubeadm/app/apis/kubeadm/validation	0.114s	coverage: 100.0% of statements`

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

**Release note**:

```release-note
NONE
```
2017-12-13 23:26:03 -08:00
bistros 8ac24a5ed2 fixed typo in kubeadm/v1alpha1/defaults.go
fixed some type in comment
2017-12-13 18:43:30 +09:00
Kubernetes Submit Queue b953341d13
Merge pull request #56599 from xiangpengzhao/kubeadm_stable_v19_version
Automatic merge from submit-queue (batch tested with PRs 56599, 56824, 56918, 56967, 56959). 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: Use the v1.9 branch by default

**What this PR does / why we need it**:
As per https://github.com/kubernetes/kubeadm/blob/master/docs/release-cycle.md, bump the default Kubernetes version to use in kubeadm right before v1.9.0-rc.1 (or maybe rc.0 ?) is cut.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
ref: https://github.com/kubernetes/kubernetes/pull/47440 https://github.com/kubernetes/kubernetes/pull/52085

**Special notes for your reviewer**:
/cc @luxas @kubernetes/sig-cluster-lifecycle-pr-reviews @kubernetes/kubernetes-release-managers

**Release note**:

```release-note
NONE
```
2017-12-11 19:58:12 -08:00
Kubernetes Submit Queue 2a71ed2141
Merge pull request #57043 from luxas/kubeadm_v19_fixup
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>.

kubeadm: Don't downgrade etcd on cluster downgrade

**What this PR does / why we need it**:
 - Don't try downgrade etcd on k8s downgrade -- that doesn't work
 - Mark self-hosting as alpha as discussed in the SIG
 - Don't print the beta warning as it confuses users
 - Slightly make the wording around upgrade/downgrade clearer

**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
```
@kubernetes/sig-cluster-lifecycle-pr-reviews
2017-12-11 13:20:21 -08:00
zacharysarah 9ca41b451a Doc updates for 1.9 2017-12-11 13:03:17 -06:00
Lucas Käldström f99aae9ce3
kubeadm: Don't downgrade etcd on cluster downgrade 2017-12-11 19:37:18 +02:00
Davanum Srinivas 31332fa84a Drop using cloud provider to set host address feature
As part of the larger plan to drop --cloud-provider and --cloud-config
from kube-apiserver, we need to stop calling Cloud Provider API to
find the external ip address when one is not specified on the command
line.

When ExternalHost is not specified, we check if AdvertiseAddress is
specified and use that, if that is missing then we use os.Hostname().

When testing this feature, found a problem that when ExternalHost
is specified, the port was not added in the generated URL. So fixed
that as well.
2017-12-05 13:58:20 -06:00
Josh Horwitz def22b796c Use hostname for CCM resource lock id 2017-12-04 21:52:33 -05:00
Kubernetes Submit Queue 77a2a64674
Merge pull request #56802 from rajansandeep/updateversion
Automatic merge from submit-queue (batch tested with PRs 55360, 56444, 56687, 56791, 56802). 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>.

Bump CoreDNS version to 1.0.0

**What this PR does / why we need it**:
Updating the CoreDNS version to 1.0.0, which fixes bugs, including the ones which were failing the e2e tests for kubeadm with CoreDNS as the default DNS server (kubernetes/test-infra#5601)

**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
```
2017-12-04 13:40:22 -08:00
Kubernetes Submit Queue 31375e30ba
Merge pull request #56638 from crassirostris/audit-webhook-make-configurable
Automatic merge from submit-queue (batch tested with PRs 56790, 56638). 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 audit batch webhook backend configurable

This PR adds an ability to configure key parameters for the most important audit backend at-scale, so that if the default parameters don't fit and audit events are lost/delayed, it's possible to adjust these parameters to fix the problem. In the future those parameters will stay, but will be used to populate the values for the generic buffering backend, both for webhook and log backends.

/cc @kubernetes/sig-auth-pr-reviews @sttts @tallclair @ericchiang

```release-note
Audit webhook batching parameters are now configurable via command-line flags in the apiserver.
```

ref #54551
2017-12-04 09:53:13 -08:00
Sandeep Rajan d832e6ae63 coredns 1.0.0 2017-12-04 11:57:18 -05:00
Davanum Srinivas 7568462ec3 Remove hacks added for mesos
Since Mesos is no longer in your main repository and since we have
things like dynamic kubelet configuration in progress, we should
drop these undocumented, untested, private hooks.

cmd/kubelet/app/server.go::CreateAPIServerClientConfig
CreateAPIServerClientConfig::getRuntime
pkg/kubelet/kubelet_pods.go::getPhase

Also remove stuff from Dependencies struct that were specific to
the Mesos integration (ContainerRuntimeOptions and Options)

Also remove stale references in test/e2e and and test owners file
2017-12-03 13:52:30 -05:00
Vladimir Vivien 179d8e108e CSI - feature gate fix, gated RBAC rules, csi nodeID label
This commit tracks chages to fix blocking bugs such as feature gates, rbac rules, usage
of csi nodeID to derive attachment ID.
2017-12-02 05:54:54 -05:00
Lucas Käldström f7c494fe5b
kubeadm: Fix a couple of upgrade/downgrade-related bugs 2017-12-02 00:27:07 +02:00
Mik Vyatskov 7e717ef3a6 Make audit batch webhook backend configurable
Signed-off-by: Mik Vyatskov <vmik@google.com>
2017-11-30 19:00:52 +01:00
Kubernetes Submit Queue 160270800f
Merge pull request #56535 from dims/create-volume-mount-and-host-path-for-cloud-config
Automatic merge from submit-queue (batch tested with PRs 56400, 56535). 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>.

Create volumeMount and hostPath for cloud config file

We have a way to specify the cloudProvider in kubeadm.conf. We also
add `--cloud-config /etc/kubernetes/cloud-config` to both the
kubernetes api server and controller manager yaml files if one exists
on the box. However we fail to make that file available to the
process running in the container. We need to make this `cloud-config`
file available to both processes similar to how controller-manager.conf
is passed to controller manager.



**What this PR does / why we need it**:
Fixes https://github.com/kubernetes/kubeadm/issues/576

**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
```
2017-11-29 18:59:13 -08:00
xiangpengzhao 91ccdaa057 kubeadm: Use the v1.9 branch by default 2017-11-30 09:31:46 +08:00
Kubernetes Submit Queue 617821eb39
Merge pull request #56544 from leblancd/v6_dns_probe_brackets
Automatic merge from submit-queue (batch tested with PRs 56497, 56500, 55018, 56544, 56425). 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 brackets around IPv6 kube-dns liveness probe addrs

**What this PR does / why we need it**:
Previously, when an IPv6-only Kubernetes cluster was instantiated
via 'kubeadm init ...', the liveness probes that were
configured by kubeadm for kube-dns currently use IP:port
strings of "::1:53" and "::1:10053". These IP:port strings should
instead include brackets around the ::1 IPv6 loopback address, e.g.
"[::1]:53" and "[::1]:10053".

This change adds the necessary brackets around the ::1 IPv6 loopback
address.

Without this change, the kube-dns sidecar container interprets the
bracket-less strings as IPv4 IP:port strings that have too many
colons, and the kube-dns pod is restarted about once every 2 minutes.

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

/area ipv6
/sig network

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE

```
2017-11-29 15:26:08 -08:00
Kubernetes Submit Queue b86569fe10
Merge pull request #56500 from sbezverk/kubeadm_etcd_fix_1
Automatic merge from submit-queue (batch tested with PRs 56497, 56500, 55018, 56544, 56425). 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 etcd modifying recovery steps

Closes #56499
```release-note
Modifying etcd recovery steps for the case of failed upgrade
```
2017-11-29 15:26:02 -08:00
Serguei Bezverkhi 294114a219 kubeadm etcd modifying recover steps 2017-11-29 15:53:07 -05:00
Davanum Srinivas a11f984356 Create volumeMount and hostPath for cloud config file
We have a way to specify the cloudProvider in kubeadm.conf. We also
add `--cloud-config /etc/kubernetes/cloud-config` to both the
kubernetes api server and controller manager yaml files if one exists
on the box. However we fail to make that file available to the
process running in the container. We need to make this `cloud-config`
file available to both processes similar to how controller-manager.conf
is passed to controller manager.
2017-11-29 15:29:01 -05:00
Dane LeBlanc d626de113f Add brackets around IPv6 kube-dns liveness probe addrs
When a Kubernetes cluster is instantiated in IPv6-only mode
via 'kubeadm init ...', the liveness probes that are
configured by kubeadm for kube-dns currently use IP:port
strings of "::1:53" and "::1:10053". These IP:port strings should
instead include brackets around the ::1 IPv6 loopback address, e.g.
"[::1]:53" and "[::1]:10053".

This change adds the necessary brackets around the ::1 IPv6 loopback
address.

Without this change, the kube-dns sidecar container interprets the
bracket-less strings as IPv4 IP:port strings that have too many
colons, and the kube-dns pod is restarted about once every 2 minutes.

fixes #56543

/area ipv6
/sig network
2017-11-29 07:44:06 -05:00
Davanum Srinivas 6ec2bdf9db Allow config and ignore-preflight to be specified together
In commit 3a0aa06fc9, the flag
was changed from `ignore-checks-errors` to `ignore-preflight-errors`,
but the condition check in ValidateMixedArguments was not updated.
So specifying say `--config kubeadm.conf --ignore-preflight-errors all`
would fail.
2017-11-29 05:56:22 -05:00
stewart-yu 50520be649 completely remove the option to use auto-detect 2017-11-28 09:54:28 +08:00
m1093782566 10aea7e88c update bazel BUILD file 2017-11-28 09:33:10 +08:00
m1093782566 1a10652173 test ipvs proxy mode when feature gateway set 2017-11-28 09:33:09 +08:00
supereagle 7dce7fe1eb use authentication client with explicit version 2017-11-27 22:13:19 +08:00
stewart-yu eed826a25e fix bug when cloud is nil 2017-11-27 21:55:32 +08:00
m1093782566 7b372143c5 test ipvs proxy mode when feature gateway unset 2017-11-27 20:06:51 +08:00
m1093782566 dc2e57ba74 refactor canUseIPVSMode and test it 2017-11-27 20:06:47 +08:00
stewart-yu 26626529a7 should check return err 2017-11-26 11:03:14 +08:00
xiangpengzhao b5b75997fb Add test case for validate kube-proxy configuration. 2017-11-25 12:29:48 +08:00
xiangpengzhao 2419af51fd Improve kubeadm validation unit test coverage. 2017-11-25 11:43:00 +08:00
Lion-Wei 92117f69e3 add kube config file of kube-proxy to kube-proxy config map 2017-11-25 09:11:54 +08:00
xiangpengzhao cf97d6f6eb Run the kubeletconfig defaulter in kubeadm defaults 2017-11-25 01:15:54 +08:00
xiangpengzhao 1e26acfa52 Enable kube-proxy validation in kubeadm validation. 2017-11-25 01:15:54 +08:00
xiangpengzhao da971d8020 Only set defaults when DynamicKubeletConfig feature gate is on. 2017-11-25 01:15:54 +08:00
xiangpengzhao 845a10f0a9 Auto generated BUILD files. 2017-11-25 01:15:50 +08:00
xiangpengzhao 737c0ec9eb Add validation of kubelet configuration in kubeadm. 2017-11-25 01:11:33 +08:00
Kubernetes Submit Queue 64ccd7665f
Merge pull request #56311 from xiangpengzhao/kubeadm-proxy-ipvs
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 SupportIPVSProxyMode feature gate in kubeadm.

**What this PR does / why we need it**:
Since #55972 gets merged, kubeadm now supports using kube-proxy ComponentConfig. Then `SupportIPVSProxyMode` feature gate can be configured in kube-proxy config. There is no need to config the feature gate in kubeadm (workaround introduced by #53962). The benefit of removing it I can think of is that we don't need to care about the IPVS feature evolution in kubeadm any longer.

**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 https://github.com/kubernetes/kubeadm/issues/512

**Special notes for your reviewer**:
/cc @luxas @Lion-Wei @kubernetes/sig-cluster-lifecycle-pr-reviews 

**Release note**:

```release-note
NONE
```
2017-11-24 07:20:27 -08:00
Kubernetes Submit Queue 58fca39de3
Merge pull request #56130 from anguslees/kubeadm-nodehealth
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 healthchecks skippable, and check masters only

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

Previously kubeadm would abort if _any_ node was not Ready.  This is obviously infeasible in a non-trivial (esp. baremetal) cluster.

This PR makes two changes:
- Allows kubeadm healthchecks to be selectively skipped (made non-fatal) with --ignore-checks-errors.
- Check only that the *master* nodes are Ready.

**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 kubernetes/kubeadm#539

**Special notes for your reviewer**:

Builds on #56072

**Release note**:

```release-note
kubeadm health checks can also be skipped with `--ignore-checks-errors`
```
2017-11-24 04:20:26 -08:00
xiangpengzhao f13e374ddb Auto generated BUILD files. 2017-11-24 12:03:34 +08:00
xiangpengzhao 70983e2838 Remove SupportIPVSProxyMode feature gate in kubeadm. 2017-11-24 12:03:13 +08:00
Kubernetes Submit Queue 0b597b51d6
Merge pull request #55972 from rpothier/v6_proxy_bind_addr
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>.

Use kube-proxy ComponentConfig in kubeadm clusters

This change adds configuring the kube-proxy bind address to be an
IPv6 address based on the whether the API server advertise address is IPv6.

It is doing this via the kube-proxy ComponentConfig API now from v1.9

**What this PR does / why we need it**:
This PR sets the bind address for kube-proxy to be a IPv6 address. This is needed for IPv6

**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 #50927
Fixes https://github.com/kubernetes/kubeadm/issues/527

**Special notes for your reviewer**:

**Release note**:

```release-note
Adds kubeadm support for using ComponentConfig for the kube-proxy
```
2017-11-23 17:58:09 -08:00
Angus Lees 3da5985916 Only check Readiness of masters, not every node 2017-11-24 10:27:35 +11:00
Angus Lees 68ea48bd2b Allow healthchecks to be skipped with --ignore-checks-errors too 2017-11-24 10:27:35 +11:00
Kubernetes Submit Queue 362e6293ce
Merge pull request #56190 from edisonxiang/fixcontrolplaneunittests
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 controlplane unit tests

What this PR does / why we need it:

when the flexvolumeDirVolumePath is truely existent in the host,
```cmd/kubeadm/app/phases/controlplane``` unit tests will be failed.

Fixes #56189

Release note:
```release-note
NONE
```
2017-11-23 15:07:32 -08:00
Kubernetes Submit Queue 04d1fcc9f3
Merge pull request #52049 from cheftako/ccm-cleanup
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 failure to load volume plugins for #52048

Currently we have two plugin managers.
However one of them limits the cloud plugins it loads.
This means that if cloud provider is set to external the plugins will
not be loaded in *that* plugin manager. However they will be loaded in
the other instance of the plugin manager. So it does not actually save
us anything. It does hamper the efforts to actually get stage 1
separation working.

**What this PR does / why we need it**: It allows the plugins be found for the cloud providers working on stage 1 separation.

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

**Special notes for your reviewer**:

**Release note**:
```release-note NONE
```
2017-11-23 12:53:40 -08:00
Kubernetes Submit Queue 06963c5384
Merge pull request #56208 from kad/ignore-errors-flag
Automatic merge from submit-queue (batch tested with PRs 56208, 55690). 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: rename flag to --ignore-preflight-errors

**What this PR does / why we need it**:
Addresses comments in #56072
Improves user experience by using name that is more
descriptive.

**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 kubernetes/kubeadm#480

**Special notes for your reviewer**:
/area kubeadm
/sig cluster-lifecycle
/assign @timothysc

**Release note**:
```release-note
NONE
```
2017-11-23 08:20:30 -08:00
Alexander Kanevskiy 3a0aa06fc9 kubeadm: rename flag to --ignore-preflight-errors
Improves user experience by using name that is more
descriptive.
2017-11-23 15:37:57 +02:00
xiangpengzhao 1c96fa21d2 Minor cleanup in kubeadm. 2017-11-23 20:32:09 +08:00
xiangpengzhao 7de8d545f3 Add test case for RunCreateToken 2017-11-23 19:32:36 +08:00
jsafrane 4ad4ee3153 Added PVC Protection Controller
This controller removes protection finalizer from PVCs that are being
deleted and are not referenced by any pod.
2017-11-23 11:46:34 +01:00
pospispa a06901a868 Admission Controller PVC Finalizer Plugin
This admission plugin puts finalizer to every created PVC. The finalizer is
removed by PVCProtectionController when the PVC is not referenced by any
pods and thus the PVC can be deleted.
2017-11-23 11:46:28 +01:00
Kubernetes Submit Queue 7f8521819d
Merge pull request #56256 from thockin/fix-broken-NewProxyServer
Automatic merge from submit-queue (batch tested with PRs 56249, 56118, 56255, 56252, 56256). 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-proxy: Fix NewProxyServer

Different OSes need different args.  This is not a great fix, but better
than adding an arg to Windows which doesn't need it.

Fixes #56238

```release-note
NONE
```
2017-11-23 00:23:29 -08:00
Kubernetes Submit Queue ad4f8a2f67
Merge pull request #56255 from sbezverk/fix_etcd_version
Automatic merge from submit-queue (batch tested with PRs 56249, 56118, 56255, 56252, 56256). 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>.

Fixing etcd version for 1.10.X kubernetes

Closes #56254
2017-11-23 00:23:23 -08:00
Kubernetes Submit Queue 60c2090191
Merge pull request #49112 from gmarek/eventAPI
Automatic merge from submit-queue (batch tested with PRs 55952, 49112, 55450, 56178, 56151). 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>.

New API group for Events.

Fix kubernetes/features#383

cc @shyamjvs 

```release-note
Add events.k8s.io api group with v1beta1 API containing redesigned Event type.
```
2017-11-22 21:48:42 -08:00
Kubernetes Submit Queue 408f64062f
Merge pull request #55952 from rajansandeep/corednsupgrade
Automatic merge from submit-queue (batch tested with PRs 55952, 49112, 55450, 56178, 56151). 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 to kubeadm upgrade for CoreDNS

**What this PR does / why we need it**:
This PR enables to get CoreDNS in the kubeadm upgrade and alpha phases addons via feature-gates.

**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 https://github.com/kubernetes/kubeadm/issues/446

**Special notes for your reviewer**:

**Release note**:

```release-note
kubeadm: Add CoreDNS support for kubeadm "upgrade" and "alpha phases addons".
```
2017-11-22 21:48:38 -08:00
Robert Pothier ce8113d9a9 Update kubeadm config for setting kube-proxy bind address
This change adds configuring the kube-proxy bind address to be an
IPv6 address based on the whether the API server advertise address is IPv6.
2017-11-23 00:48:20 -05:00
Kubernetes Submit Queue 55d8781b09
Merge pull request #56185 from mattmoyer/kubeadm-print-join-command
Automatic merge from submit-queue (batch tested with PRs 55545, 55548, 55815, 56136, 56185). 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 `--print-join-command` flag for token create.

**What this PR does / why we need it**: This change adds a new flag `kubeadm token create --print-join-command`. When this flag is passed, kubeadm prints the full `kubeadm join [...]` command, including the CA certificate hash which is otherwise annoying to calculate.

**Which issue(s) this PR fixes** fixes https://github.com/kubernetes/kubeadm/issues/519

**Special notes for your reviewer**:

### Example Output
```
$ kubeadm token create --print-join-command
kubeadm join --token 447067.20b55955bd6abe6c 192.168.99.100:8443 --discovery-token-ca-cert-hash sha256:17023a5c90b996e50c514e63e161e46f78be216fd48c0c3df3be67e008b28889
$ kubeadm token create -h
[...]
      --print-join-command   Instead of printing only the token, print the full 'kubeadm join' flag needed to join the cluster using the token.
[...]
```

I ended up not using the approach suggested by @xiangpengzhao in https://github.com/kubernetes/kubernetes/pull/56025 (and also by @fabriziopandini) of reusing the `bootstrap-token` phase code, since that code assumes it can load the CA certificates from `/etc/kubernetes`, but that is only true if kubeadm is run on an already-joined node.

Instead, I wrote code to pull the CA certificates and server endpoint from the kubeconfig that `kubeadm token create` is called with, since that also contains the data and is available even if, e.g., kubeadm is being run from outside the cluster.

**Release note**:
```release-note
kubeadm: added `--print-join-command` flag for `kubeadm token create`.
```

/sig cluster-lifecycle

/cc @fabriziopandini @xiangpengzhao @luxas
2017-11-22 16:52:34 -08:00
Kubernetes Submit Queue 704a0b52b0
Merge pull request #55548 from dhilipkumars/Extend-testapiserver
Automatic merge from submit-queue (batch tested with PRs 55545, 55548, 55815, 56136, 56185). 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>.

Extend apiserver testserver

**What this PR does / why we need it**:
Extend the test pkg of api-server a little bit so that it can be used by others
**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 wanted to use this test pkg while creating a new integration test fixture, the idea of starting the api-server without actually starting a proper etcd (integration etcd ) is very useful, if would be great to extend this for other usecases such as `insecure` mode too.

It will also be useful to get the working `tmpdir` returned so that we could store additional certs (such as service account public and private keys and kubeconf for this apiserver) if needed, which will be cleaned up automatically by the `teardownFn` when the api server is terminating.

**Release note**:

```release-note
NONE
```
ref: https://github.com/kubernetes/kubernetes/pull/50144
2017-11-22 16:52:26 -08:00
Tim Hockin 79778288de Fix NewProxyServer
Different OSes need different args.  This is not a great fix, but better
than adding an arg to Windows which doesn't need it.
2017-11-22 14:17:10 -08:00
Serguei Bezverkhi a63fadfbd5 Fixing etcd version for 1.10.X kubernetes 2017-11-22 17:16:11 -05:00
Kubernetes Submit Queue 93dc3763b0
Merge pull request #56201 from luxas/new_kubeadm_owners
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>.

Restructure cmd/kubeadm/OWNERS

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

After a year of virtually the same people in `cmd/kubeadm/OWNERS`, the SIG has decided to refresh the list of reviewers/approvers a little. If you feel more/other changes are needed yet, please speak up here in this thread, in our weekly SIG meeting or ping me on Slack.

Thanks all everyone that has helped out here and thanks to you who are stepping up more now!

**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
```
@kubernetes/sig-cluster-lifecycle-pr-reviews 

Please ACK that you are ok with this officially here as well:
@kad @timothysc @jamiehannaford @xiangpengzhao @lukemarsden @errordeveloper @mattmoyer @justinsb @fabriziopandini
2017-11-22 14:13:10 -08:00
Kubernetes Submit Queue f8ffbd9d61
Merge pull request #55976 from caesarxuchao/move-mutating-to-last
Automatic merge from submit-queue (batch tested with PRs 51321, 55969, 55039, 56183, 55976). 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 mutating to run last in the mutating admission plugin chain

ref: kubernetes/features#492

Follow up on #54892. (see https://github.com/kubernetes/kubernetes/pull/54892#discussion_r151333585)

Only the last commit is relevant.

The reasons are:
* Mutating webhooks are dynamic, they can always adjust according to the behavior of compiled-in admission plugins, but not the other-way around.
* We'll document that if user deploys mutating webhooks that over some built-in mutating plugins decision, user needs also to disable the built-in validating plugins, otherwise the cluster might block.
2017-11-22 12:00:01 -08:00
Marek Grabowski ef6f0b8c6e generated 2017-11-22 18:40:09 +00:00
gmarek 69e2a9cb48 Add new Events API group 2017-11-22 18:40:09 +00:00
Kubernetes Submit Queue 4e2f5e2212
Merge pull request #56020 from xiangpengzhao/write-kubeletconf-todisk
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>.

 Write marshalled kubeletconfig object to init-config-dir

**What this PR does / why we need it**:
from @luxas :
>Write the the marshalled kubeletconfig object to /var/lib/kubelet/config/init/kubelet so that the kubelet will start up with the right params on init/join. The only params expected in the kubelet command-line after this is kubelet --init-config-dir /var/lib/kubelet/config/init --dynamic-config-dir /var/lib/kubelet/config/dynamic

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
ref: https://github.com/kubernetes/kubeadm/issues/28#issuecomment-345502933

**Special notes for your reviewer**:
/cc @kubernetes/sig-cluster-lifecycle-pr-reviews

**Release note**:

```release-note
NONE
```
2017-11-22 10:17:56 -08:00
Chao Xu 8e8e32fa05 move the MutatingAdmissionWebhook to the last in the mutating amdission
plugin chain.
2017-11-22 08:55:16 -08:00
Sandeep Rajan 90a9cd8ca1 support upgrade plan for coredns 2017-11-22 11:14:08 -05:00
Matt Moyer b4b275d255 kubeadm: add `--print-join-command` flag for token create.
This change adds a new flag `kubeadm token create --print-join-command`. When this flag is passed, kubeadm prints the full `kubeadm join [...]` command, including the CA certificate hash which is otherwise annoying to calculate.

Example:
```
$ kubeadm token create --print-join-command
kubeadm join --token 447067.20b55955bd6abe6c 192.168.99.100:8443 --discovery-token-ca-cert-hash sha256:17023a5c90b996e50c514e63e161e46f78be216fd48c0c3df3be67e008b28889
```
2017-11-22 09:29:47 -06:00
xiangpengzhao e89927a890 Should make dir before writing file. 2017-11-22 23:01:54 +08:00
Kubernetes Submit Queue b2a233b6d4
Merge pull request #56156 from sbezverk/kubeadm_upgrade_plan_etcd
Automatic merge from submit-queue (batch tested with PRs 55873, 56156). 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>.

Adding etcd version for kubeadm upgrade plan

Adding etcd version display to kubeadm upgrade plan subcommand
```release-note
Adding etcd version display to kubeadm upgrade plan subcommand
```
Closes https://github.com/kubernetes/kubeadm/issues/531
2017-11-22 06:43:26 -08:00
Serguei Bezverkhi a9ea1b881b Adding etcd version for kubeadm upgrade plan 2017-11-22 07:01:13 -05:00
edisonxiang 29d42afe08 fix fmt wording error 2017-11-22 19:58:59 +08:00
Kubernetes Submit Queue 991e33d36a
Merge pull request #55998 from xiangpengzhao/regen-apiserver-crt
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>.

Regenerate API server serving certificates when upgrading.

**What this PR does / why we need it**:
TODO: 
- [x] check the age of crt.
- [x] check the new version number.

**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 https://github.com/kubernetes/kubeadm/issues/548

**Special notes for your reviewer**:
/cc @luxas 

**Release note**:

```release-note
NONE
```
2017-11-22 03:43:05 -08:00
Lucas Käldström f60b43d6b0
Restructure cmd/kubeadm/OWNERS 2017-11-22 12:01:17 +02:00
dhilipkumars fd8758b047 Extend apiserver testserver such that in can be used in integration tests
abstract out etcd server creation
test/integration/framework: cleanup master_utils.go
kube-apiserver: move StartTestServer tests into test/integration/master
Fix the failing scale test
kube-apiserver's TestServer now returns a struct instead of individual values
2017-11-22 15:16:25 +05:30
Kubernetes Submit Queue bd8d8f4387
Merge pull request #56186 from liggitt/master
Automatic merge from submit-queue (batch tested with PRs 55103, 56036, 56186). 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 "Kubelet flags take precedence over config from files/ConfigMaps"

This reverts commit cbebb61450.

Per https://github.com/kubernetes/kubernetes/pull/56097#issuecomment-346243014

```release-note
NONE
```
2017-11-22 00:27:32 -08:00
Kubernetes Submit Queue a83869276f
Merge pull request #56036 from m1093782566/flush-ipvs
Automatic merge from submit-queue (batch tested with PRs 55103, 56036, 56186). 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 cleanup-ipvs flag for kube-proxy 

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

There is no way to tell if a given ipvs rule is created by ipvs proxier or not, and some people have complained that iptables/userspace proxier will clean up their ipvs rules when start up - both iptables and userspace proxiers need to clean up legacy proxy rules created by ipvs proxier.

This PR adds a new `--cleanup-ipvs` flag for kube-proxy for the sake of providing users a way to decide if clean up IPVS rules or not when start iptables or userspace proxier.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
Add cleanup-ipvs flag for kube-proxy 
```

/sig network
/area ipvs
/king bug
2017-11-22 00:27:30 -08:00
xiangpengzhao 6034ef48a9 Fix deadlock of writing file on node. 2017-11-22 15:53:20 +08:00
xiangpengzhao 7adced12a6 Refactoring writing kubeletconfig. 2017-11-22 15:53:20 +08:00
xiangpengzhao 8565ee89c5 Write marshalled kubeletconfig object to init-config-dir 2017-11-22 15:53:19 +08:00
xiangpengzhao 5322cc5e02 Auto generated BUILD files. 2017-11-22 15:53:07 +08:00
xiangpengzhao e75c6628de Add unit test case for new funcs 2017-11-22 14:41:41 +08:00
xiangpengzhao 7549b4184f Make expired cert check more clear. 2017-11-22 14:41:40 +08:00
xiangpengzhao 2b00d36241 Address review comments. 2017-11-22 14:41:40 +08:00
xiangpengzhao b37d6641a7 Auto generated BUILD files. 2017-11-22 14:41:37 +08:00
edisonxiang 18f0802852 fix controlplane unit tests
What this PR does / why we need it:

when the flexvolumeDirVolumePath is truely existent in the host,
```cmd/kubeadm/app/phases/controlplane``` unit tests will be failed.

Fixes #56189

Release note:
```release-note
NONE
```
2017-11-22 14:19:12 +08:00
Kubernetes Submit Queue 1bdb61f828
Merge pull request #54529 from vladimirvivien/k8s-csi-intree-plugin
Automatic merge from submit-queue (batch tested with PRs 54529, 53765). 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>.

Kubernetes CSI - in-tree Plugin Implementation

**What this PR does / why we need it**:
This PR is part of the internal Kubernetes CSI Volume plugin.  It implements the Attach/Detach/Mount/Unmount API.

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

**Special notes for your reviewer**:
- Implements feature https://github.com/kubernetes/features/issues/178
- Designed https://github.com/kubernetes/community/pull/1258

Other CSI Volume plugin PRs
- CSI Persistent Volume Source - https://github.com/kubernetes/kubernetes/pull/55204

**Release note**:
```release-note
NONE
```
2017-11-21 21:38:56 -08:00
Jordan Liggitt ae7dccf2e9
Revert "Kubelet flags take precedence over config from files/ConfigMaps"
This reverts commit cbebb61450.
2017-11-21 23:55:43 -05:00
Kubernetes Submit Queue 947295a760
Merge pull request #56072 from kad/fine-checks
Automatic merge from submit-queue (batch tested with PRs 51494, 56097, 56072, 56175). 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 individual control for kubeadm preflight checks

**What this PR does / why we need it**:
With new flag `--ignore-checks-errors` user is able to
decrease severity of each individual check error to warning.

Old flag `--skip-preflight-checks` now acts as `--ignore-checks-errors=all` and will produce warnings.

**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 kubernetes/kubeadm#480

**Special notes for your reviewer**:
/area kubeadm 
/sig cluster-lifecycle

cc @luxas 

**Release note**:
```release-note
New kubeadm flag `--ignore-checks-errors` that enables to decrease severity of each individual error to warning.
Old flag `--skip-preflight-checks` is marked as deprecated and acts as `--ignore-checks-errors=all`
```
2017-11-21 19:49:31 -08:00
Kubernetes Submit Queue d7a96d5e88
Merge pull request #56097 from mtaufen/kc-file-e2e-test
Automatic merge from submit-queue (batch tested with PRs 51494, 56097, 56072, 56175). 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>.

Kubelet flags take precedence over config from files/ConfigMaps

Changes the Kubelet configuration flag precedence order so that flags
take precedence over config from files/ConfigMaps.

See:
https://docs.google.com/document/d/18-MsChpTkrMGCSqAQN9QGgWuuFoK90SznBbwVkfZryo/

Also modifies e2e node test suite to transform all relevant Kubelet flags into
a config file before starting tests when the KubeletConfigFile feature gate is
true, and turns on the KubeletConfigFile gate for all e2e node tests.
This allows the alpha dynamic Kubelet config feature to continue to 
work in tests after the precedence change.

fixes #56171

Related: https://github.com/kubernetes/features/issues/281


```release-note
CLI flags passed to the Kubelet now take precedence over Kubelet config files and dynamic Kubelet config. This helps ensure backwards compatible behavior across Kubelet binary updates.
```
2017-11-21 19:49:27 -08:00
Kubernetes Submit Queue 943d37246a
Merge pull request #56170 from rajansandeep/corefileupdate
Automatic merge from submit-queue (batch tested with PRs 55340, 55329, 56168, 56170, 56105). 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 the configmap manifest in CoreDNS

**What this PR does / why we need it**:
This PR updates the corefile to retain the pod requests support like in kube-dns. This helps when upgrading CoreDNS using kubeadm upgrade (#55952).

**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
```
2017-11-21 18:56:37 -08:00
Kubernetes Submit Queue 277d866111
Merge pull request #50984 from timothysc/checkpoint
Automatic merge from submit-queue (batch tested with PRs 55812, 55752, 55447, 55848, 50984). 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>.

Initial basic bootstrap-checkpoint support

**What this PR does / why we need it**:
Adds initial support for Pod checkpointing to allow for controlled recovery of the control plane during self host failure conditions. 

fixes #49236
xref https://github.com/kubernetes/features/issues/378

**Special notes for your reviewer**:

Proposal is here: https://docs.google.com/document/d/1hhrCa_nv0Sg4O_zJYOnelE8a5ClieyewEsQM6c7-5-o/edit?ts=5988fba8#

1. Controlled tests work, but I have not tested the self hosted api-server recovery, that requires validation and logs.  /cc @luxas 
2. In adding hooks for checkpoint manager much of the tests around basicpodmanager appears to be stub'd.  This has become an anti-pattern in the code and should be avoided.  
3. I need a node-e2e to ensure consistency of behavior. 

**Release note**:
```
Add basic bootstrap checkpointing support to the kubelet for control plane recovery
```

/cc @kubernetes/sig-cluster-lifecycle-misc @kubernetes/sig-node-pr-reviews
2017-11-21 17:57:40 -08:00
Vladimir Vivien c90a68c133 CSI - Generated source code
This commit tracks all auto-generated sources.
2017-11-21 20:21:04 -05:00
Vladimir Vivien dd08d1b489 CSI - API source code implementation
This commit tracks source code update for the CSI volume plugin implementation.
2017-11-21 20:20:58 -05:00
Kubernetes Submit Queue 630dbedef9
Merge pull request #56042 from stewart-yu/kubeadm#554
Automatic merge from submit-queue (batch tested with PRs 56128, 56004, 56083, 55833, 56042). 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>.

Automatically opt into dependent feature gates when using kubeadm

**What this PR does / why we need it**:
There will be a dependency chain between  feature gates.  kubeadm needs to automatically opt into dependent feature gates of a chosen one.

**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 # [https://github.com/kubernetes/kubeadm/issues/554](https://github.com/kubernetes/kubeadm/issues/554)

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-11-21 17:05:02 -08:00
Kubernetes Submit Queue 4cafc5459b
Merge pull request #56004 from caesarxuchao/admission-v1beta1
Automatic merge from submit-queue (batch tested with PRs 56128, 56004, 56083, 55833, 56042). 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>.

Graduate the admission and admissionregistration (webhook part) API to v1beta1

ref: kubernetes/features#492

Most changes are mechanical. Please take a look at the commit message to see if the commit is worth reviewing.

```release-note
Action required:
The `admission/v1alpha1` API has graduated to `v1beta1`. Please delete your existing webhooks before upgrading the cluster, and update your admission webhooks to use the latest API, because the API has backwards incompatible changes.
The webhook registration related part of the `admissionregistration` API has graduated to `v1beta1`. Please delete your existing configurations before upgrading the cluster, and update your configuration file to use the latest API.
```
2017-11-21 17:04:54 -08:00
Michael Taufen cbebb61450 Kubelet flags take precedence over config from files/ConfigMaps
Changes the Kubelet configuration flag precedence order so that flags
take precedence over config from files/ConfigMaps.

See issue #56171 for more details.

Also modifies e2e node test suite to transform all relevant Kubelet
flags into a config file before starting tests when the
KubeletConfigFile feature gate is true, and turns on the
KubeletConfigFile gate for all e2e node tests. This allows the alpha
dynamic Kubelet config feature to continue to work in tests after
the precedence change.
2017-11-21 16:02:27 -08:00
Chao Xu fcf4f15c89 update-all generated 2017-11-21 13:00:40 -08:00
Chao Xu 3ad49765d6 change storage, registry, discovery version for admissionregistration 2017-11-21 13:00:39 -08:00
Sandeep Rajan 475d30c814 update coredns manifest 2017-11-21 15:30:10 -05:00
Kubernetes Submit Queue 5337ff8009
Merge pull request #55859 from hzxuzhonghu/listener-genericapiserver
Automatic merge from submit-queue (batch tested with PRs 56021, 55843, 55088, 56117, 55859). 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>.

apiserver:  pass a listener into genericapiserver bootstrapping 

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

>At the moment we pass a port via the options into the config. A zero port does not work because the loopback clients created during apiserver initialization need to know the port before. Passing a listener into the server instead would allow us to use a zero port beforehand and bootstrapping order should be fine.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-11-21 12:16:59 -08:00
Kubernetes Submit Queue ec036d9c0e
Merge pull request #56025 from fabriziopandini/kubeadm-bootstrap
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>.

Enhance kubeadm `bootstrap-token`

**What this PR does / why we need it**:
This PR is part of the effort for improving kubeadm phases, and more specifically improves `bootstrap-token` phase by implementing a behaviour consistent with `kubeadm init`, that is:
- `all` subcommand
- `create` subcommand (with CA pinning stuff and --config) 
- `cluster-info` subcommand was modified, removing --config (thus making it consistent with other phases)
- `allow-auto-approve` subcommand was improved, implementing also creation of RBAC rules for certificate rotation (thus making it consistent with `kubeadm init`)
- Reference docs improved

**Which issue(s) this PR fixes** 
part of the effort for [#461](https://github.com/kubernetes/kubeadm/issues/461)
part of the effort for [#454](https://github.com/kubernetes/kubeadm/issues/454)
part of the effort for [#265](https://github.com/kubernetes/kubeadm/issues/265)

**Special notes for your reviewer**:
CC @luxas

**Release note**:
```release-note
NONE
```
2017-11-21 03:38:34 -08:00
Alexander Kanevskiy e42eb28500 Implement individual control for kubeadm preflight checks
With new flag `--ignore-checks-errors` user is able to
decrease severity of each individual check to warning.

Old flag `--skip-preflight-checks` now acts as
`--ignore-checks-errors=all` and will produce warnings.

Fixes: kubernetes/kubeadm#480
2017-11-21 13:35:38 +02:00
zhangjie 226f8b3c73 delete useless params containerized
Signed-off-by: zhangjie <zhangjie0619@yeah.net>
2017-11-21 18:21:59 +08:00
Kubernetes Submit Queue 80e1c7907e
Merge pull request #52322 from davidz627/multizoneWrongZone
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>.

Fixes issue where PVCs using `standard` StorageClass create PDs in disks in wrong zone in multi-zone GKE clusters

Fixes #50115

Changed GetAllZones to only get zones with nodes that are currently running (renamed to GetAllCurrentZones). Added E2E test to confirm this behavior.
2017-11-21 01:35:01 -08:00
fabriziopandini 5a569b9486 kubeadm-bootstrap 2017-11-21 09:52:46 +01:00
m1093782566 f3e744b661 add cleanup-ipvs flag 2017-11-21 15:05:23 +08:00
Kubernetes Submit Queue 1a831cc243
Merge pull request #56029 from wackxu/errmsg
Automatic merge from submit-queue (batch tested with PRs 55112, 56029, 55740, 56095, 55845). 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 kubeadm upgrade apply  error logging style

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

Improve kubeadm upgrade apply  error logging style

**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 # https://github.com/kubernetes/kubeadm/issues/549

**Special notes for your reviewer**:

/assign @luxas 

**Release note**:

```release-note
NONE
```
2017-11-20 21:03:41 -08:00
Timothy St. Clair ed4401c126 Addition of bootstrap checkpointing 2017-11-20 21:54:15 -06:00
stewart-yu 51fe9299f6 complish feature gate dependency in kubeadm 2017-11-21 11:18:59 +08:00
hzxuzhonghu 6ba30f678c pass listener to genericapiserver 2017-11-21 11:00:15 +08:00
David Zhu e5aec8645d Changed GetAllZones to only get zones with nodes that are currently
running (renamed to GetAllCurrentZones). Added E2E test to confirm this
behavior.

Added node informer to cloud-provider controller to keep track of zones
with k8s nodes in them.
2017-11-20 16:04:18 -08:00
Kubernetes Submit Queue db4134d03f
Merge pull request #56069 from xiangpengzhao/change-kubeadm-validation
Automatic merge from submit-queue (batch tested with PRs 55839, 54495, 55884, 55983, 56069). 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 condition "len(cfg.DiscoveryToken) != 0" to ValidateArgSelection.

**What this PR does / why we need it**:
as per https://github.com/kubernetes/kubernetes/pull/54982#discussion_r149968848
>only when the conditions having len(cfg.DiscoveryToken) != 0 means "using token-based discovery" as is mentioned in the error message.

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

**Special notes for your reviewer**:
/cc @kubernetes/sig-cluster-lifecycle-pr-reviews 

**Release note**:

```release-note
NONE
```
2017-11-20 13:08:14 -08:00
Kubernetes Submit Queue 563edef707
Merge pull request #55983 from mtaufen/seccomp-is-alpha
Automatic merge from submit-queue (batch tested with PRs 55839, 54495, 55884, 55983, 56069). 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>.

seccomp is an alpha feature and not feature gated

Move SeccompProfileRoot to KubeletFlags and document flag as alpha.

wrt https://github.com/kubernetes/kubernetes/pull/53833#issuecomment-345396575, seccomp is an alpha feature, but this isn't clearly documented anywhere (the annotation just has the word "alpha" in it, and that's your signal that it's alpha). 

Since seccomp was around before feature gates, it doesn't have one.

Thus SeccompProfileRoot should not be part of KubeletConfiguration, and this PR moves it to KubeletFlags, and amends the help text to note the alpha state of the feature.

fixes: #56087

```release-note
NONE
```
2017-11-20 13:08:12 -08:00
Kubernetes Submit Queue 79edffc93d
Merge pull request #54495 from mikedanese/csr2
Automatic merge from submit-queue (batch tested with PRs 55839, 54495, 55884, 55983, 56069). 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>.

certs: start deprecation of signing asset default paths

Per https://github.com/kubernetes/kubernetes/pull/52334#issuecomment-331212749

```release-note
Defaulting of controller-manager options for --cluster-signing-cert-file and --cluster-signing-key-file is deprecated and will be removed in a later release.
```
2017-11-20 13:08:05 -08:00
Kubernetes Submit Queue b3f7ad7407
Merge pull request #55839 from mindprince/extended-resource-toleration
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 ExtendedResourceToleration admission controller.

/kind feature
/sig scheduling
/area hw-accelerators

There's elaborate discussion on this in #55080. In short, we would like to enable cluster operators and/or cloud providers to create dedicated nodes with extended resources (like GPUs, FPGAs etc.) that are reserved for pods requesting such resources. [Taints is the kubernetes concept to create dedicated nodes.](https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/#example-use-cases) If the cluster operator or cloud provider wants to create dedicated node pools, they are expected to taint the nodes containing extended resources with the key equal to the name of the resource and effect equal to NoSchedule. If they do that, only pods that have a toleration for such a taint can be scheduled there. To make it easy for the user, this admission controller when enabled, automatically adds a toleration with key `example.com/device`, operator `Exists` and effect `NoSchedule` if an extended resource of name `example.com/device` is requested.

**Release note**:
```release-note
Add ExtendedResourceToleration admission controller. This facilitates creation of dedicated nodes with extended resources. If operators want to create dedicated nodes with extended resources (like GPUs, FPGAs etc.), they are expected to taint the node with extended resource name as the key. This admission controller, if enabled, automatically adds tolerations for such taints to pods requesting extended resources, so users don't have to manually add these tolerations. 
```
2017-11-20 12:28:36 -08:00
xiangpengzhao 6609512890 Regenerate API server serving certificates when upgrading. 2017-11-21 00:03:34 +08:00
xiangpengzhao 35138acfdf Add condition "len(cfg.DiscoveryToken) != 0" to ValidateArgSelection. 2017-11-20 23:54:03 +08:00
wackxu 3592c1be18 Improve kubeadm apply error logging style 2017-11-20 20:40:14 +08:00
Dr. Stefan Schimanski e19257f2ec admission/webhook: move webhook initializer into plugin 2017-11-20 09:28:42 +01:00
Kubernetes Submit Queue 3df3c580b7
Merge pull request #54219 from m1093782566/ipset
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>.

Using ipset doing SNAT and packet filter in IPVS kube-proxy

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

Try ipset in ipvs proxy mode.

**Which issue this PR fixes**: 

fixes #54203

xref: #53393, #53775

**Special notes for your reviewer**:

**Release note**:

```release-note
Using ipset doing SNAT and packet filtering in IPVS kube-proxy
```

/sig network

/area kube-proxy
2017-11-19 22:09:13 -08:00
Kubernetes Submit Queue ff0d72a3fa
Merge pull request #56007 from stewart-yu/fixerror
Automatic merge from submit-queue (batch tested with PRs 55939, 56007). 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 bad return error text

**What this PR does / why we need it**:
fix bad return error text

**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
```
2017-11-19 10:01:37 -08:00
Kubernetes Submit Queue 26230218b8
Merge pull request #55939 from fabriziopandini/kubeadm-improve-doc1
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>.

Improve documentation for kubeadm phases

**What this PR does / why we need it**:
This PR is part of the effort for improving kubeadm reference doc (CLI, website, manpages), and more specifically improves documentation for:
- kubeadm alpha phase certs
- kubeadm alpha phase kubeconfig
- kubeadm alpha phase controlplane
- kubeadm alpha phase etcd
- kubeadm alpha phase uploadconfig
- kubeadm alpha phase addons
- kubeadm alpha phase selfhosting

**Which issue(s) this PR fixes**:
part of the effort for [#265](https://github.com/kubernetes/kubeadm/issues/265)

**Special notes for your reviewer**:

**Release note**:
```release-note
NONE
```
2017-11-19 09:49:03 -08:00
Kubernetes Submit Queue e89bbb5ca9
Merge pull request #56014 from xiangpengzhao/join-kubelet-conf
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>.

Re-engineer the kubeadm join logic.

**What this PR does / why we need it**:
- wait for the kubelet to create `/etc/kubernetes/kubelet.conf`
- use those credentials to PATCH the node

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
ref: https://github.com/kubernetes/kubeadm/issues/28#issuecomment-345502933

**Special notes for your reviewer**:
/cc @kubernetes/sig-cluster-lifecycle-pr-reviews

**Release note**:

```release-note
NONE
```
2017-11-19 08:06:33 -08:00
Kubernetes Submit Queue 0291bd35fb
Merge pull request #56015 from luxas/kubeadm_fix_selfhosting_bug
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>.

kubeadm: Fix a small bug in the self-hosting code

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

`apps/v1beta2` requires that `DaemonSet.spec.selector.matchLabels` equals `DaemonSet.spec.template.metadata.labels`. Without this change, the API server rejects the DaemonSet in the validation stage.

**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
```
@kubernetes/sig-cluster-lifecycle-pr-reviews @xiangpengzhao
2017-11-19 06:32:26 -08:00
fabriziopandini 78cfb5d8a2 kubeadm-improve-doc1 2017-11-19 15:31:17 +01:00
xiangpengzhao 045937aaad Auto generated BUILD files. 2017-11-19 22:03:59 +08:00
xiangpengzhao 12409789a1 Re-engineer the kubeadm join logic. 2017-11-19 22:03:50 +08:00
Kubernetes Submit Queue f0ce7ca051
Merge pull request #55010 from sbezverk/kubeadm_etcd_upgrade_apply
Automatic merge from submit-queue (batch tested with PRs 51192, 55010). 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>.

Adding etcd upgrade option to kubeadm upgrade apply 

This PR adds etcd upgrade functionality to kubeadm upgrade apply.
First commit adds certain functions to be able to deal with a single component of control plane and not just with all three components (apiserver, controller-manager and scheduler). It adds granularity as a result code can be reused. 

Closes: https://github.com/kubernetes/kubeadm/issues/490

```release-note
Adds to **kubeadm upgrade apply**, a new **--etcd-upgrade** keyword. When this keyword is specified, etcd's static pod gets upgraded to the etcd version officially recommended for a target kubernetes release.
```
2017-11-19 05:22:26 -08:00
Lucas Käldström 2a047211f4
kubeadm: Fix a small bug in the self-hosting code 2017-11-19 14:45:16 +02:00
Kubernetes Submit Queue 27b3681cec
Merge pull request #56013 from xiangpengzhao/kubeadm-dns-ip
Automatic merge from submit-queue (batch tested with PRs 56008, 56013). 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>.

KubeletConfiguration.BaseConfig.ClusterDNS defaults to the tenth address of MasterConfiguration.Networking.ServiceSubnet

**What this PR does / why we need it**:
If can get DNS IP from MasterConfiguration.Networking.ServiceSubnet, defaults to it. Otherwise defaults to DefaultClusterDNSIP

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
ref: https://github.com/kubernetes/kubeadm/issues/28#issuecomment-345502933

**Special notes for your reviewer**:
/cc @luxas 

**Release note**:

```release-note
NONE
```
2017-11-19 03:13:19 -08:00
xiangpengzhao 81c72826ef Move GetDNSIP to a "higher level" pkg. 2017-11-19 17:46:29 +08:00
xiangpengzhao 41281b727f Auto generated BUILD files. 2017-11-19 17:39:57 +08:00
xiangpengzhao 0c7663510d KubeletConfiguration.BaseConfig.ClusterDNS defaults to the tenth address of MasterConfiguration.Networking.ServiceSubnet 2017-11-19 17:31:16 +08:00
stewart-yu 471fd43f53 fix bad return error text 2017-11-19 17:04:20 +08:00
xiangpengzhao 4453f2c777 Fix panic when assigning configmap UID of kubelet configuration. 2017-11-19 15:57:11 +08:00
m1093782566 268da85445 fix fakeIPSet ut error 2017-11-19 12:39:43 +08:00
Chao Xu d3c0765780 Rename GenericAdmissionWebhook to ValidatingAdmissionWebhook 2017-11-18 17:30:23 -08:00