Skip to content

Commit

Permalink
Use binDir in DHCP ds and add tolerations
Browse files Browse the repository at this point in the history
Signed-off-by: Manuel Buil <mbuil@suse.com>
  • Loading branch information
manuelbuil committed Apr 2, 2024
1 parent 893bce4 commit b6d1d4d
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 8 deletions.
7 changes: 3 additions & 4 deletions packages/rke2-multus/charts/templates/daemonSet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,10 @@ spec:
{{- toYaml . | nindent 8 }}
{{- end }}
nodeSelector: {{- toYaml .Values.labels.nodeSelector | nindent 8 }}
{{- with .Values.tolerations }}
tolerations:
- operator: Exists
effect: NoSchedule
- operator: Exists
effect: NoExecute
{{- toYaml . | trim | nindent 8 }}
{{- end }}
serviceAccountName: {{ .Values.serviceAccount.name }}
initContainers:
- name: cni-plugins
Expand Down
8 changes: 6 additions & 2 deletions packages/rke2-multus/charts/templates/dhcp-daemonSet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ spec:
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | trim | nindent 8 }}
{{- end }}
nodeSelector: {{- toYaml .Values.labels.nodeSelector | nindent 8 }}
initContainers:
- name: kube-{{ .Chart.Name }}-dhcp-cleanup
Expand All @@ -42,7 +46,7 @@ spec:
privileged: true
volumeMounts:
- name: binpath
mountPath: /opt/cni
mountPath: /opt/cni/bin
- name: socketpath
mountPath: /run/cni
- name: netnspath
Expand All @@ -51,7 +55,7 @@ spec:
volumes:
- name: binpath
hostPath:
path: /opt/cni
path: {{ .Values.config.cni_conf.binDir }}
- name: socketpath
hostPath:
path: /run/cni
Expand Down
6 changes: 5 additions & 1 deletion packages/rke2-multus/charts/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,11 @@ manifests:
customResourceDefinition: true
dhcpDaemonSet: false

#tolerations: []
tolerations:
- operator: Exists
effect: NoSchedule
- operator: Exists
effect: NoExecute

#affinity: {}

Expand Down
2 changes: 1 addition & 1 deletion packages/rke2-multus/package.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
url: local
workingDir: charts
packageVersion: 03
packageVersion: 04

0 comments on commit b6d1d4d

Please sign in to comment.