Skip to content

Commit

Permalink
BC-5423 - Make pod anti affinity rule configurable and optional
Browse files Browse the repository at this point in the history
  • Loading branch information
mamutmk5 authored Dec 1, 2023
1 parent 880ca28 commit f59448c
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ spec:
namespaceSelector: {}
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
{% if ANIT_AFFINITY_NODEPOOL_ENABLE is defined and ANIT_AFFINITY_NODEPOOL_ENABLE|bool %}
- weight: 10
podAffinityTerm:
labelSelector:
Expand All @@ -104,7 +105,8 @@ spec:
operator: In
values:
- calendar
topologyKey: "cloud.ionos.com/nodepool-name"
topologyKey: {{ ANIT_AFFINITY_NODEPOOL_TOPOLOGY_KEY }}
{% endif %}
- weight: 20
podAffinityTerm:
labelSelector:
Expand Down

0 comments on commit f59448c

Please sign in to comment.