Commit Graph

298 Commits (98277ff20bcdb3b91a1cfebe53efc024323a037e)

Author SHA1 Message Date
Wojciech Tyczynski c3b0a83a5c Configurable liveness probe initial delays for etcd and kube-apiserver in GCE 2018-01-02 15:10:33 +01: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
Tim Hockin eba5b6092a Use k8s.gcr.io vanity domain for container images 2017-12-18 09:18:34 -08:00
Kubernetes Submit Queue d001a745e7
Merge pull request #56824 from freehan/fix-glbc-image
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>.

add yaml-quote for GCE_GLBC_IMAGE

fix a bug that `GCE_GLBC_IMAGE` was not processed by yaml-quote.
```release-note
NONE
```
2017-12-11 19:58:15 -08:00
Mik Vyatskov fe0577e1a1 Make audit webhook backend configurable in startup scripts
Signed-off-by: Mik Vyatskov <vmik@google.com>
2017-12-06 16:33:08 +01:00
Minhan Xia 8d2f9fe1cf add yaml-quote for GCE_GLBC_IMAGE 2017-12-04 14:25:22 -08:00
Kubernetes Submit Queue ca37d42048
Merge pull request #55728 from rajansandeep/kubeupcoredns
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 CoreDNS as an optional addon in kube-up

**What this PR does / why we need it**:
This PR adds the option of installing CoreDNS as an addon instead of kube-dns in kube-up.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
kube-up: Add optional addon CoreDNS. 
Install CoreDNS instead of kube-dns by setting CLUSTER_DNS_CORE_DNS value to 'true'.
```
2017-11-27 14:10:54 -08:00
Kubernetes Submit Queue ba09291ba7
Merge pull request #56219 from kawych/agents_deployment
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 deployment for Stackdriver Metadata Agent with version and resource requirement controlled by env variable

**What this PR does / why we need it**:
Introduces Stackdriver Metadata Agent - a daemon set providing metadata for kubernetes objects connected to the same node.

**Special notes for your reviewer**:

**Release note**:
```release-note
NONE
```
2017-11-23 02:35:21 -08:00
Karol Wychowaniec 52f7695f00 Add deployment for Stackdriver Metadata Agent with version and resource requirement controlled by env variable 2017-11-22 16:21:52 +01:00
David Zhu f780eefd39 Set up alternate mount point for SCSI/NVMe local SSD by UUID in /mnt/disks/by-uuid/, set up ability to have unformatted disk symlinked in /dev/disk/by-uuid/. Added tests. Preserved backwards compatibility. 2017-11-17 10:56:48 -08:00
Mike Danese 0117006a54
Revert "Add options for mounting SCSI or NVMe local SSD though Block or Filesystem and do all of that with UUID" 2017-11-16 07:51:38 -08:00
Kubernetes Submit Queue c3ed0f2663
Merge pull request #53466 from davidz627/localSSDUUID
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 options for mounting SCSI or NVMe local SSD though Block or Filesystem and do all of that with UUID

Fixes: #51431

Mount SCSI local SSD by UUID in /mnt/disks/by-uuid/, also allows for users to request and mount NVMe disks. Both types of disks will be accessable either through block or filesystem

To see code in progress for NVMe and block support see working branch: https://github.com/davidz627/kubernetes/tree/localExt
2017-11-15 18:25:30 -08:00
David Zhu 028258244c Set up alternate mount point for SCSI/NVMe local SSD by UUID in /mnt/disks/by-uuid/, set up ability to have unformatted disk symlinked in /dev/disk/by-uuid/. Added tests. Preserved backwards compatibility. 2017-11-14 17:14:41 -08:00
Kubernetes Submit Queue 95b4312899
Merge pull request #55466 from x13n/addon-manager
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 results of kube-controller-manager leader election in addon manager

**What this PR does / why we need it**:
This adds leader election-like mechanism to addon manager. Currently, in a multi-master setup, upgrading one master will trigger a fight between addon managers on different masters, each forcing its own versions of addons. This leads to pod unavailability until all masters are upgraded to new version.

To avoid implementing leader election in bash, results of leader election in kube-controller-manager are used. Long term, addon manager probably should be rewritten in a real prgramming language (probably Go), and then, real leader election should be implemented there.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
I don't think there was an issue for this specifically, but this PR is related to https://github.com/kubernetes/kubernetes/issues/473

**Special notes for your reviewer**:

**Release note**:
```release-note
Addon manager supports HA masters.
```
2017-11-14 11:26:31 -08:00
Kubernetes Submit Queue 330a615466
Merge pull request #55243 from porridge/cert-errors
Automatic merge from submit-queue (batch tested with PRs 54602, 54877, 55243, 55509, 55128). 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 some error handling in place of ilusory one.

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

TL;DR: "set -e" is ignored inside function foo when it's called like
"foo || something".

See https://github.com/kubernetes/kubernetes/issues/55229 for details.

This is a short-term hack that will hopefully let us at least see the
error messages whenever we hit intermittent certificate setup errors
next time. Once we know what fails there, we can start working on an
actual fix, which may very well involve rewriting this in a language
other than shell, with better error handling.

**Which issue(s) this PR fixes**
Partially addresses #55229

**Release note**:
```release-note
NONE
```
2017-11-14 03:03:27 -08:00
Daniel Kłobuszewski ae6e506fdc
Merge branch 'master' into addon-manager 2017-11-14 09:36:20 +01:00
Sandeep Rajan 5c7392368f Add CoreDNS as an optional addon in kube-up 2017-11-13 18:38:51 -05:00
Kubernetes Submit Queue 4f91113075
Merge pull request #54826 from mindprince/addon-manager
Automatic merge from submit-queue (batch tested with PRs 54826, 53576, 55591, 54946, 54825). 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>.

Run nvidia-gpu device-plugin daemonset as an addon on GCE nodes that have nvidia GPUs attached

- Instead of the old `Accelerators` feature that added `alpha.kubernetes.io/nvidia-gpu` resource, use the new `DevicePlugins` feature that adds vendor specific resources. (In case of nvidia GPUs it will
add `nvidia.com/gpu` resource.)

- Add node label to GCE nodes with accelerators attached. This node label is the same as what GKE attaches to node pools with accelerators attached. (For example, for nvidia-tesla-p100 GPU, the label would be `cloud.google.com/gke-accelerator=nvidia-tesla-p100`) This will help us target accelerator specific
daemonsets etc. to these nodes.

- Run nvidia-gpu device-plugin daemonset as an addon on GCE nodes that have nvidia GPUs attached.

- Some minor documentation improvements in addon manager.

**Release note**:
```release-note
GCE nodes with NVIDIA GPUs attached now expose `nvidia.com/gpu` as a resource instead of `alpha.kubernetes.io/nvidia-gpu`.
```

/sig cluster-lifecycle
/sig scheduling
/area hw-accelerators

https://github.com/kubernetes/features/issues/368
2017-11-13 14:46:55 -08:00
Daniel Kłobuszewski 5e4692f784 Use results of kube-controller-manager leader election in addon manager 2017-11-13 14:54:37 +01:00
Marcin Owsiany 7b745e0016 Review comments addressed. 2017-11-10 09:39:02 +01:00
Marcin Owsiany 9c5a058708 fixup: remove useless errexit setting 2017-11-07 17:07:16 +01:00
Marcin Owsiany dbcf0faa00 Add some error handling in place of ilusory one.
TL;DR: "set -e" is ignored inside function foo when it's called like
"foo || something".

See https://github.com/kubernetes/kubernetes/issues/55229 for details.

This is a short-term hack that will hopefully let us at least see the
error messages whenever we hit intermittent certificate setup errors
next time. Once we know what fails there, we can start working on an
actual fix, which may very well involve rewriting this in a language
other than shell, with better error handling.
2017-11-07 15:36:14 +01:00
Kubernetes Submit Queue 7a28aaffa7
Merge pull request #54964 from Random-Liu/add-containerd-e2e
Automatic merge from submit-queue (batch tested with PRs 54488, 54838, 54964). 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 for alternative container runtime in `kube-up.sh`

For https://github.com/kubernetes/features/issues/286.

This PR added 4 new environment variables in `kube-up.sh` to support alternative container runtime:
1) `KUBE_MASTER_EXTRA_METADATA` and `KUBE_NODE_EXTRA_METADATA`. Add extra metadata on master and node instance. With this we could specify different cloud-init for a different container runtime, and also add extra metadata for the new cloud-init, e.g. [master.yaml](7d73966214/test/e2e/master.yaml)
2) `KUBE_CONTAINER_RUNTIME_ENDPOINT`. Specify different sock for different container runtime. It's only used when it's not empty.
3) `KUBE_LOAD_IMAGE_COMMAND`. Specify different load image command for different container runtime.

An example for cri-containerd:
```
export KUBE_MASTER_EXTRA_METADATA="user-data=${GOPATH}/src/github.com/kubernetes-incubator/cri-containerd/test/e2e/master.yaml,cri-containerd-configure-sh=${GOPATH}/src/github.com/kubernetes-incubator/cri-containerd/test/configure.sh"
export KUBE_NODE_EXTRA_METADATA="user-data=${GOPATH}/src/github.com/kubernetes-incubator/cri-containerd/test/e2e/node.yaml,cri-containerd-configure-sh=${GOPATH}/src/github.com/kubernetes-incubator/cri-containerd/test/configure.sh"
export KUBE_CONTAINER_RUNTIME="remote"
export KUBE_CONTAINER_RUNTIME_ENDPOINT="/var/run/cri-containerd.sock"
export KUBE_LOAD_IMAGE_COMMAND="/home/cri-containerd/usr/local/bin/cri-containerd load"
export NETWORK_POLICY_PROVIDER="calico"
```

Signed-off-by: Lantao Liu <lantaol@google.com>

```release-note
none
```
/cc @yujuhong @dchen1107 @feiskyer @mikebrow @abhi @mrunalp @runcom 
/cc @kubernetes/sig-node-pr-reviews
2017-11-02 18:01:19 -07:00
Lantao Liu 8279916c65 Fix calico network policy for opensource.
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-11-02 21:56:46 +00:00
Rohit Agarwal cf292754ba Run nvidia-gpu device-plugin daemonset as an addon on GCE nodes that have nvidia GPUs attached. 2017-11-02 12:58:29 -07:00
Lantao Liu 75293ac7a2 Add containerd e2e.
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-11-02 03:44:42 +00:00
Tim Allclair 88db819170
GCP PodSecurityPolicy configuration 2017-11-01 14:03:09 -07:00
Kubernetes Submit Queue 51652d1c23 Merge pull request #53816 from marun/remove-federation
Automatic merge from submit-queue (batch tested with PRs 54112, 54150, 53816, 54321, 54338). 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 federation

This PR removes the federation codebase and associated tooling from the tree.

The first commit just removes the `federation` path and should be uncontroversial.  The second commit removes references and associated tooling and suggests careful review.

Requirements for merge:

- [x] Bazel jobs no longer hard-code federation as a target ([test infra #4983](https://github.com/kubernetes/test-infra/pull/4983))
- [x] `federation-e2e` jobs are not run by default for k/k

**Release note**:

```release-note
Development of Kubernetes Federation has moved to github.com/kubernetes/federation.  This move out of tree also means that Federation will begin releasing separately from Kubernetes.  The impact of this is Federation-specific behavior will no longer be included in kubectl, kubefed will no longer be released as part of Kubernetes, and the Federation servers will no longer be included in the hyperkube binary and image.
```

cc: @kubernetes/sig-multicluster-pr-reviews @kubernetes/sig-testing-pr-reviews
2017-10-26 17:07:28 -07:00
Kubernetes Submit Queue abe9d2f736 Merge pull request #54150 from ihmccreery/mdc-e2e
Automatic merge from submit-queue (batch tested with PRs 54112, 54150, 53816, 54321, 54338). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Enable metadata concealment for tests

**What this PR does / why we need it**: Metadata concealment is going to beta for v1.9; enable it by default in tests.  Also, just use `ENABLE_METADATA_CONCEALMENT` instead of two different vars.  Work toward #8867.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
Metadata concealment on GCE is now controlled by the `ENABLE_METADATA_CONCEALMENT` env var.  See cluster/gce/config-default.sh for more info.
```
2017-10-26 17:07:24 -07:00
Maru Newby adc338d330 Remove all traces of federation 2017-10-26 13:37:37 -07:00
Wojciech Tyczynski 2fbe39fc8f Fix etcd hostnames 2017-10-23 13:49:28 +02:00
Isaac Hollander McCreery 6c1f63ab79 Use PROVIDER_VARS 2017-10-19 14:17:46 -07:00
Isaac Hollander McCreery 3ee03fd033 Enable metadata concealment for tests 2017-10-18 08:31:18 -07:00
Joe Betz 2e362ea142 Add 'ETCD_DOCKER_REPOSITORY' environment variable override to 'cluster/' scripts.
This allows the etcd docker registry that is currently hard coded to
`gcr.io/google_containers/etcd` in the `etcd.manifest` template to be
overridden.  This can be used to test new versions of etcd with
kubernetes that have not yet been published to
`gcr.io/google_containers/etcd` and also enables cluster operators to
manage the etcd images used by their cluster in an internal
repository.
2017-10-10 12:38:18 -07:00
Kubernetes Submit Queue 7b8d7dee52 Merge pull request #51367 from cjcullen/abacaway
Automatic merge from submit-queue (batch tested with PRs 48970, 52497, 51367, 52549, 52541). 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>..

Default ABAC to off in GCE (for new clusters).

**What this PR does / why we need it**:
Disables the legacy ABAC authorizer by default on GCE/GKE clusters using kube-up.sh. Existing clusters upgrading to 1.8 will keep their existing configuration.

**Release note**:
```release-note
New GCE or GKE clusters created with `cluster/kube-up.sh` will not enable the legacy ABAC authorizer by default. If you would like to enable the legacy ABAC authorizer, export ENABLE_LEGACY_ABAC=true before running `cluster/kube-up.sh`.
```
2017-09-19 01:17:45 -07:00
Jacob Simpson ca48fca127 Add configuration support for signing duration.
Add CLUSTER_SIGNING_DURATION environment variable to cluster
configuration scripts to allow configuration of signing duration of
certificates issued via the Certificate Signing Request API.
2017-09-15 10:22:19 -07:00
Kubernetes Submit Queue 0c1dcb01c5 Merge pull request #52115 from jcbsmpsn/flag-enable-kubelet-certificate-rotation
Automatic merge from submit-queue (batch tested with PRs 52452, 52115, 52260, 52290)

Add env var to enable kubelet rotation in kube-up.sh.

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

```release-note
Adds ROTATE_CERTIFICATES environment variable to kube-up.sh script for GCE
clusters. When that var is set to true, the command line flag enabling kubelet
client certificate rotation will be added to the kubelet command line.
```
2017-09-15 01:59:59 -07:00
Kubernetes Submit Queue b3e641d7f3 Merge pull request #51824 from ihmccreery/oss-mdc
Automatic merge from submit-queue (batch tested with PRs 51824, 50476, 52451, 52009, 52237)

Allow metadata firewall & proxy on in GCE, off by default

**What this PR does / why we need it**: Add necessary variables in kube-env to allow a user to turn on metadata firewall and proxy for K8s on GCE.

Ref #8867.

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

**Special notes for your reviewer**:

**Release note**:

```release-note
GCE users can enable the metadata firewall and metadata proxy with KUBE_FIREWALL_METADATA_SERVER and ENABLE_METADATA_PROXY, respectively.
```
2017-09-15 01:07:58 -07:00
Jacob Simpson 0ac34781c8 Add env var to enable kubelet rotation in kube-up.sh. 2017-09-14 11:30:03 -07:00
Isaac Hollander McCreery 6930f5ac31 Allow metadata firewall & proxy on in GCE, off by default 2017-09-13 09:58:51 -07:00
Mik Vyatskov ccf40abd50 Make advanced audit policy on GCP configurable 2017-09-13 14:36:26 +02:00
Eric Chiang cd3c8770c5 Revert "Add cluster up configuration for certificate signing duration."
This reverts commit bd0c16cc8e.
2017-09-11 16:28:17 -07:00
Jacob Simpson bd0c16cc8e Add cluster up configuration for certificate signing duration. 2017-09-05 15:56:33 -07:00
Nick Sardo 8ac7bb5fb2 Use different project id for network ops & always set subnet 2017-09-04 09:55:56 -07:00
Kubernetes Submit Queue ffed1d3408 Merge pull request #51792 from piosz/metrics-server
Automatic merge from submit-queue (batch tested with PRs 49727, 51792)

Introducing metrics-server

ref https://github.com/kubernetes/features/issues/271

There is still some work blocked on problems with repo synchronization:
- migrate to `v1beta1` introduced in #51653 
- bump deps to HEAD
Will do it in a follow up PRs once the issue is resolved.

```release-note
Introduced Metrics Server
```
2017-09-04 03:37:59 -07:00
Piotr Szczesniak 55c21ac801 Introduced Metrics Server 2017-09-03 22:13:59 +02:00
Kubernetes Submit Queue 9637f46122 Merge pull request #51725 from nicksardo/gce-plumb-netvars
Automatic merge from submit-queue (batch tested with PRs 51805, 51725, 50925, 51474, 51638)

GCE: Plumb network & subnetwork to master

**Which issue this PR fixes** *
Fixes #51714

/assign @bowei 

**Release note**:
```release-note
NONE
```
2017-09-03 11:10:00 -07:00
Kubernetes Submit Queue 5632613c5b Merge pull request #51069 from MrHohn/kube-proxy-pod-priority
Automatic merge from submit-queue (batch tested with PRs 51553, 51538, 51663, 51069, 51737)

Allow enable pod priority feature gate for GCE and configure priority for kube-proxy

**What this PR does / why we need it**:
From #23225, this PR adds an option for user to enable pod priority feature gate using GCE startup scripts, and configure pod priority for kube-proxy when enabled.

The setup `priorityClassName: system` derives from: ce1485c626/staging/src/k8s.io/api/core/v1/types.go (L2536-L2542)

The plan is to configure pod priority for kube-proxy daemonset (https://github.com/kubernetes/kubernetes/pull/50705) in the same way.

**Special notes for your reviewer**:
cc @bsalamat @davidopp @thockin 

**Release note**:

```release-note
When using kube-up.sh on GCE, user could set env `ENABLE_POD_PRIORITY=true` to enable pod priority feature gate.
```
2017-09-02 21:58:04 -07:00
Kubernetes Submit Queue 28d0077688 Merge pull request #51649 from mml/sh-test
Automatic merge from submit-queue (batch tested with PRs 49971, 51357, 51616, 51649, 51372)

Add some initial shell parsing tests.

These just test to see if there is a bash syntax error in these shell
libraries.

For #51642

```release-note
NONE
```
2017-09-01 01:12:45 -07:00
Nick Sardo 506064376b Set NODE_NETWORK and NODE_SUBNETWORK in kube-up 2017-08-31 17:23:30 -07:00