Skip to content

Commit

Permalink
BC-5423 - add pod affinity ruls to deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
mamutmk5 authored Nov 30, 2023
1 parent b3dec47 commit 8d37380
Showing 1 changed file with 33 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -78,3 +78,36 @@ spec:
requests:
cpu: {{ H5P_STATICFIILES_SERVER_CPU_REQUESTS|default("100m", true) }}
memory: {{ H5P_STATICFIILES_SERVER_MEMORY_REQUESTS|default("128Mi", true) }}
affinity:
podAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 100
podAffinityTerm:
labelSelector:
matchExpressions:
- key: app.kubernetes.io/part-of
operator: In
values:
- schulcloud-verbund
topologyKey: "kubernetes.io/hostname"
namespaceSelector: {}
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 10
podAffinityTerm:
labelSelector:
matchExpressions:
- key: app.kubernetes.io/name
operator: In
values:
- h5p-staticfiles-server
topologyKey: "cloud.ionos.com/nodepool-name"
- weight: 10
podAffinityTerm:
labelSelector:
matchExpressions:
- key: app.kubernetes.io/name
operator: In
values:
- h5p-staticfiles-server
topologyKey: "topology.kubernetes.io/zone"

0 comments on commit 8d37380

Please sign in to comment.