Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion charts/libretranslate/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -301,9 +301,17 @@ spec:
claimName: models-volume
{{- end }}
{{- end }}
{{- if .Values.affinity }}
affinity:
{{- toYaml .Values.affinity | nindent 8 }}
{{- end }}
{{- if .Values.nodeSelector }}
nodeSelector:
{{- toYaml .Values.nodeSelector | nindent 8 }}
{{- end }}
{{- if .Values.tolerations }}
tolerations:
{{- toYaml .Values.tolerations | nindent 6 }}
{{- toYaml .Values.tolerations | nindent 6 }}
{{- end }}
{{- if and .Values.persistence.enabled (or (eq .Values.persistence.models.accessMode "ReadWriteOnce") (eq .Values.persistence.db.accessMode "ReadWriteOnce")) }}
# still in beta, but this will allow us to delete the volumes when the statefulset is scaled down
Expand Down
6 changes: 6 additions & 0 deletions charts/libretranslate/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ annotations: {}
# Extra tolerations for pods
tolerations: []

# Node selectors for pods
affinity: {}

# Pod affinities
nodeSelector: {}

# Chart name override
nameOverride: ""

Expand Down