metrics-server: Unconditional control-plane tolerations

There is no harm on having unneeded toleration when control-plane node
are not tainted, so simplify the template to always use the toleration.
This commit is contained in:
Max Gautier
2024-09-23 15:30:48 +02:00
parent 9f45552201
commit dba00f2d85
2 changed files with 0 additions and 9 deletions

View File

@@ -85,15 +85,11 @@ spec:
volumes:
- name: tmp
emptyDir: {}
{% if not control_plane_nodes_are_not_tainted or metrics_server_extra_tolerations is defined %}
tolerations:
{% if not control_plane_nodes_are_not_tainted %}
- key: node-role.kubernetes.io/control-plane
effect: NoSchedule
{% endif %}
{% if metrics_server_extra_tolerations is defined %}
{{ metrics_server_extra_tolerations | list | to_nice_yaml(indent=2) | indent(8) }}
{% endif %}
{% endif %}
affinity:
podAntiAffinity: