diff --git a/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 b/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 index b0f1a2f53..e8cd82508 100644 --- a/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 +++ b/roles/kubernetes/master/templates/manifests/kube-apiserver.manifest.j2 @@ -60,8 +60,15 @@ spec: {% endif %} {% endif %} - --secure-port={{ kube_apiserver_port }} - - --insecure-port={{ kube_apiserver_insecure_port }} - --storage-backend={{ kube_apiserver_storage_backend }} +{% if kube_api_insecure %} + - --insecure-port={{ kube_apiserver_insecure_port }} +{% endif %} +{% if kube_api_custum_config is defined %} +{% for conf in kube_api_custom_config %} + - {{ conf }} +{% endfor %} +{% endif %} {% if kube_api_runtime_config is defined %} {% for conf in kube_api_runtime_config %} - --runtime-config={{ conf }}