From 30ef4842f127967b8811ccf2121962e93705eac7 Mon Sep 17 00:00:00 2001 From: Smana Date: Wed, 24 Aug 2016 14:32:54 +0200 Subject: [PATCH] Revert "pass cloud provider flag in all cases, not just openstack" This reverts commit f35e5e864fe4b6f3cdd0400eff0721a8c231ed1d. --- .../master/templates/manifests/kube-apiserver.manifest.j2 | 2 -- .../templates/manifests/kube-controller-manager.manifest.j2 | 6 ++---- roles/kubernetes/node/templates/kubelet.j2 | 3 +-- 3 files changed, 3 insertions(+), 8 deletions(-) diff --git a/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 b/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 index 1df850dbf..7961ac36f 100644 --- a/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 +++ b/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 @@ -35,8 +35,6 @@ spec: {% if cloud_provider is defined and cloud_provider == "openstack" %} - --cloud-provider={{ cloud_provider }} - --cloud-config={{ kube_config_dir }}/cloud_config -{% elif cloud_provider is defined %} - - --cloud-provider={{ cloud_provider }} {% endif %} - 2>&1 >> {{ kube_log_dir }}/kube-apiserver.log volumeMounts: diff --git a/roles/kubernetes/master/templates/manifests/kube-controller-manager.manifest.j2 b/roles/kubernetes/master/templates/manifests/kube-controller-manager.manifest.j2 index 0195e5eab..32eeca0b4 100644 --- a/roles/kubernetes/master/templates/manifests/kube-controller-manager.manifest.j2 +++ b/roles/kubernetes/master/templates/manifests/kube-controller-manager.manifest.j2 @@ -17,11 +17,9 @@ spec: - --root-ca-file={{ kube_cert_dir }}/ca.pem - --enable-hostpath-provisioner={{ kube_hostpath_dynamic_provisioner }} - --v={{ kube_log_level | default('2') }} -{% if cloud_provider is defined and cloud_provider == "openstack"%} - - --cloud-provider={{cloud_provider}} +{% if cloud_provider is defined and cloud_provider == "openstack" %} + - --cloud-provider=openstack - --cloud-config={{ kube_config_dir }}/cloud_config -{% elif cloud_provider is defined %} - - --cloud-provider={{cloud_provider}} {% endif %} livenessProbe: httpGet: diff --git a/roles/kubernetes/node/templates/kubelet.j2 b/roles/kubernetes/node/templates/kubelet.j2 index 7eb76de2d..bab27305e 100644 --- a/roles/kubernetes/node/templates/kubelet.j2 +++ b/roles/kubernetes/node/templates/kubelet.j2 @@ -33,9 +33,8 @@ DOCKER_SOCKET="--docker-endpoint=unix:/var/run/weave/weave.sock" KUBE_ALLOW_PRIV="--allow-privileged=true" {% if cloud_provider is defined and cloud_provider == "openstack" %} KUBELET_CLOUDPROVIDER="--cloud-provider={{ cloud_provider }} --cloud-config={{ kube_config_dir }}/cloud_config" -{% elif cloud_provider is defined %} -KUBELET_CLOUDPROVIDER="--cloud-provider={{ cloud_provider }}" {% else %} +{# TODO: gce and aws don't need the cloud provider to be set? #} KUBELET_CLOUDPROVIDER="" {% endif %} {% if ansible_service_mgr in ["sysvinit","upstart"] %}