Browse Source

Merge pull request #3280 from wozniakjan/openstack/openstack_cacert

Check `openstack_cacert` for empty string
pull/3363/head
k8s-ci-robot 6 years ago
committed by GitHub
parent
commit
8512cc5cca
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 5 additions and 4 deletions
  1. 2
      roles/kubernetes/master/templates/kubeadm-config.v1alpha1.yaml.j2
  2. 2
      roles/kubernetes/master/templates/kubeadm-config.v1alpha2.yaml.j2
  3. 4
      roles/kubernetes/master/templates/manifests/kube-controller-manager.manifest.j2
  4. 1
      roles/kubernetes/node/tasks/main.yml

2
roles/kubernetes/master/templates/kubeadm-config.v1alpha1.yaml.j2

@ -118,7 +118,7 @@ controllerManagerExtraArgs:
{% for key in kube_kubeadm_controller_extra_args %}
{{ key }}: "{{ kube_kubeadm_controller_extra_args[key] }}"
{% endfor %}
{% if cloud_provider is defined and cloud_provider in ["openstack"] and openstack_cacert is defined %}
{% if cloud_provider is defined and cloud_provider in ["openstack"] and openstack_cacert is defined and openstack_cacert != "" %}
controllerManagerExtraVolumes:
- name: openstackcacert
hostPath: "{{ kube_config_dir }}/openstack-cacert.pem"

2
roles/kubernetes/master/templates/kubeadm-config.v1alpha2.yaml.j2

@ -117,7 +117,7 @@ controllerManagerExtraArgs:
{% for key in kube_kubeadm_controller_extra_args %}
{{ key }}: "{{ kube_kubeadm_controller_extra_args[key] }}"
{% endfor %}
{% if cloud_provider is defined and cloud_provider in ["openstack"] and openstack_cacert is defined %}
{% if cloud_provider is defined and cloud_provider in ["openstack"] and openstack_cacert is defined and openstack_cacert != "" %}
controllerManagerExtraVolumes:
- name: openstackcacert
hostPath: "{{ kube_config_dir }}/openstack-cacert.pem"

4
roles/kubernetes/master/templates/manifests/kube-controller-manager.manifest.j2

@ -97,7 +97,7 @@ spec:
name: cloudconfig
readOnly: true
{% endif %}
{% if cloud_provider is defined and cloud_provider in ["openstack"] and openstack_cacert is defined %}
{% if cloud_provider is defined and cloud_provider in ["openstack"] and openstack_cacert is defined and openstack_cacert != "" %}
- mountPath: "{{ kube_config_dir }}/openstack-cacert.pem"
name: openstackcacert
readOnly: true
@ -122,7 +122,7 @@ spec:
path: "{{ kube_config_dir }}/cloud_config"
name: cloudconfig
{% endif %}
{% if cloud_provider is defined and cloud_provider in ["openstack"] and openstack_cacert is defined %}
{% if cloud_provider is defined and cloud_provider in ["openstack"] and openstack_cacert is defined and openstack_cacert != "" %}
- hostPath:
path: "{{ kube_config_dir }}/openstack-cacert.pem"
name: openstackcacert

1
roles/kubernetes/node/tasks/main.yml

@ -177,6 +177,7 @@
- cloud_provider is defined
- cloud_provider == 'openstack'
- openstack_cacert is defined
- openstack_cacert != ""
tags:
- cloud-provider

Loading…
Cancel
Save