Skip to content
Snippets Groups Projects
Commit 13e3e867 authored by Chad Swenson's avatar Chad Swenson
Browse files

Fix kubeadm config extra volumes

I found a potential use case where `writable` could be null and therfore
not treated like a boolean, so this adds an extra default statement to
avoid negating a non-boolean as boolean which would lead to undefined. refs #4020
parent fce8712b
No related branches found
No related tags found
No related merge requests found
...@@ -158,7 +158,7 @@ apiServer: ...@@ -158,7 +158,7 @@ apiServer:
- name: {{ volume.name }} - name: {{ volume.name }}
hostPath: {{ volume.hostPath }} hostPath: {{ volume.hostPath }}
mountPath: {{ volume.mountPath }} mountPath: {{ volume.mountPath }}
readOnly: {{ volume.readOnly | d(not volume.writable) }} readOnly: {{ volume.readOnly | d(not (volume.writable | d(false))) }}
{% endfor %} {% endfor %}
{% endif %} {% endif %}
certSANs: certSANs:
...@@ -201,7 +201,7 @@ controllerManager: ...@@ -201,7 +201,7 @@ controllerManager:
- name: {{ volume.name }} - name: {{ volume.name }}
hostPath: {{ volume.hostPath }} hostPath: {{ volume.hostPath }}
mountPath: {{ volume.mountPath }} mountPath: {{ volume.mountPath }}
readOnly: {{ volume.readOnly | d(not volume.writable) }} readOnly: {{ volume.readOnly | d(not (volume.writable | d(false))) }}
{% endfor %} {% endfor %}
{% endif %} {% endif %}
scheduler: scheduler:
...@@ -222,7 +222,7 @@ scheduler: ...@@ -222,7 +222,7 @@ scheduler:
- name: {{ volume.name }} - name: {{ volume.name }}
hostPath: {{ volume.hostPath }} hostPath: {{ volume.hostPath }}
mountPath: {{ volume.mountPath }} mountPath: {{ volume.mountPath }}
readOnly: {{ volume.readOnly | d(not volume.writable) }} readOnly: {{ volume.readOnly | d(not (volume.writable | d(false))) }}
{% endfor %} {% endfor %}
{% endif %} {% endif %}
--- ---
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment