Skip to content

Commit

Permalink
feat: Apply tolerations and nodeSelector to pods in the chart (#45)
Browse files Browse the repository at this point in the history
* Apply tolerations and nodeSelector to pod specs

* version bump to 0.7.6
  • Loading branch information
TheIrritainer authored Feb 4, 2022
1 parent 8cc9448 commit b374634
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.idea
2 changes: 1 addition & 1 deletion charts/chatwoot/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ sources:
- http://www.chatwoot.com

# This is the chart version.
version: 0.7.5
version: 0.7.6

# This is the application version.
appVersion: "v2.1.1"
7 changes: 7 additions & 0 deletions charts/chatwoot/templates/migrations-job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,13 @@ spec:
template:
spec:
restartPolicy: Never
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- if .Values.nodeSelector }}
nodeSelector: {{- include "common.tplvalues.render" (dict "value" .Values.nodeSelector "context" $) | nindent 8 }}
{{- end }}
initContainers:
- name: init-postgres
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
Expand Down
7 changes: 7 additions & 0 deletions charts/chatwoot/templates/tests/test-connection.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,13 @@ metadata:
"helm.sh/hook": test
"helm.sh/hook-delete-policy": hook-succeeded
spec:
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- if .Values.nodeSelector }}
nodeSelector: {{- include "common.tplvalues.render" (dict "value" .Values.nodeSelector "context" $) | nindent 4 }}
{{- end }}
containers:
- name: wget
image: busybox
Expand Down
7 changes: 7 additions & 0 deletions charts/chatwoot/templates/web-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,13 @@ spec:
release: "{{ .Release.Name }}"
role: web
spec:
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- if .Values.nodeSelector }}
nodeSelector: {{- include "common.tplvalues.render" (dict "value" .Values.nodeSelector "context" $) | nindent 8 }}
{{- end }}
containers:
- args:
- bundle
Expand Down
7 changes: 7 additions & 0 deletions charts/chatwoot/templates/worker-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,13 @@ spec:
release: "{{ .Release.Name }}"
role: worker
spec:
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- if .Values.nodeSelector }}
nodeSelector: {{- include "common.tplvalues.render" (dict "value" .Values.nodeSelector "context" $) | nindent 8 }}
{{- end }}
containers:
- args:
- bundle
Expand Down

0 comments on commit b374634

Please sign in to comment.