Skip to content

Commit 80ad7cc

Browse files
committed
feature(helm): Add support for affinities
Signed-off-by: Dhouti <[email protected]>
1 parent ac2c8b7 commit 80ad7cc

File tree

7 files changed

+38
-0
lines changed

7 files changed

+38
-0
lines changed

helm/kagent/templates/controller-deployment.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,10 @@ spec:
3939
tolerations:
4040
{{- toYaml . | nindent 8 }}
4141
{{- end }}
42+
{{- with .Values.controller.affinity }}
43+
affinity:
44+
{{- toYaml . | nindent 8 }}
45+
{{- end }}
4246
containers:
4347
- name: controller
4448
args:

helm/kagent/templates/ui-deployment.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,10 @@ spec:
3434
tolerations:
3535
{{- toYaml . | nindent 8 }}
3636
{{- end }}
37+
{{- with .Values.ui.affinity }}
38+
affinity:
39+
{{- toYaml . | nindent 8 }}
40+
{{- end }}
3741
containers:
3842
- name: ui
3943
securityContext:

helm/kagent/values.yaml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@ tolerations: []
4646
# -- Node labels to match for `Pod` [scheduling](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/).
4747
nodeSelector: {}
4848

49+
# Affinities for `Pod` https://kubernetes.io/docs/tasks/configure-pod-container/assign-pods-nodes-using-node-affinity/
50+
affinity: {}
51+
4952
# ==============================================================================
5053
# DATABASE CONFIGURATION
5154
# ==============================================================================
@@ -85,6 +88,9 @@ controller:
8588

8689
# -- Node labels to match for `Pod` [scheduling](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/).
8790
nodeSelector: {}
91+
92+
# Affintities for `Pod` https://kubernetes.io/docs/tasks/configure-pod-container/assign-pods-nodes-using-node-affinity/
93+
affinity: {}
8894

8995
image:
9096
registry: ""
@@ -136,6 +142,9 @@ ui:
136142
# -- Node labels to match for `Pod` [scheduling](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/).
137143
nodeSelector: {}
138144

145+
# Affintities for `Pod` https://kubernetes.io/docs/tasks/configure-pod-container/assign-pods-nodes-using-node-affinity/
146+
affinity: {}
147+
139148
# ==============================================================================
140149
# LLM PROVIDERS CONFIGURATION
141150
# ==============================================================================
@@ -208,6 +217,15 @@ kagent-tools:
208217
memory: 1Gi
209218
tools:
210219
loglevel: "debug"
220+
221+
# -- Node taints which will be tolerated for `Pod` [scheduling](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/).
222+
tolerations: []
223+
224+
# -- Node labels to match for `Pod` [scheduling](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/).
225+
nodeSelector: {}
226+
227+
# Affintities for `Pod` https://kubernetes.io/docs/tasks/configure-pod-container/assign-pods-nodes-using-node-affinity/
228+
affinity: {}
211229

212230
# ==============================================================================
213231
# AGENTS

helm/tools/grafana-mcp/templates/deployment.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ spec:
2727
tolerations:
2828
{{- toYaml . | nindent 8 }}
2929
{{- end }}
30+
{{- with .Values.affinity }}
31+
affinity:
32+
{{- toYaml . | nindent 8 }}
33+
{{- end }}
3034
containers:
3135
- name: grafana-mcp
3236
securityContext:

helm/tools/grafana-mcp/values.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ tolerations: []
2424

2525
nodeSelector: {}
2626

27+
affinity: {}
28+
2729
service:
2830
type: ClusterIP
2931
port: 8000

helm/tools/querydoc/templates/deployment.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@ spec:
2929
tolerations:
3030
{{- toYaml . | nindent 8 }}
3131
{{- end }}
32+
{{- with .Values.affinity }}
33+
affinity:
34+
{{- toYaml . | nindent 8 }}
35+
{{- end }}
3236
containers:
3337
- name: querydoc
3438
securityContext:

helm/tools/querydoc/values.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ tolerations: []
2020

2121
nodeSelector: {}
2222

23+
affinity: {}
24+
2325
service:
2426
type: ClusterIP
2527
port: 8080

0 commit comments

Comments
 (0)