From 01c0ab4f06d6ad50a64bd499fc5591e6ce4d6ce1 Mon Sep 17 00:00:00 2001 From: Spencer Smith Date: Wed, 31 May 2017 08:24:24 -0400 Subject: [PATCH] check if cloud_provider is defined --- .../master/templates/manifests/kube-apiserver.manifest.j2 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 b/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 index 982184764..851cca060 100644 --- a/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 +++ b/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 @@ -105,7 +105,7 @@ spec: - mountPath: {{ etcd_cert_dir }} name: etcd-certs readOnly: true -{% if cloud_provider == 'aws' and ansible_os_family == 'RedHat' %} +{% if cloud_provider is defined and cloud_provider == 'aws' and ansible_os_family == 'RedHat' %} - mountPath: /etc/ssl/certs/ca-bundle.crt name: rhel-ca-bundle readOnly: true @@ -120,7 +120,7 @@ spec: - hostPath: path: {{ etcd_cert_dir }} name: etcd-certs -{% if cloud_provider == 'aws' and ansible_os_family == 'RedHat' %} +{% if cloud_provider is defined and cloud_provider == 'aws' and ansible_os_family == 'RedHat' %} - hostPath: path: /etc/ssl/certs/ca-bundle.crt name: rhel-ca-bundle