Skip to content
This repository has been archived by the owner on Jan 18, 2024. It is now read-only.

Assigning backup jobs to specific nodes #632

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
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
2 changes: 1 addition & 1 deletion charts/timescaledb-single/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
apiVersion: v1
name: timescaledb-single
description: 'TimescaleDB HA Deployment.'
version: 0.33.2
version: 0.33.3
icon: https://cdn.iconscout.com/icon/free/png-256/timescaledb-1958407-1651618.png

# appVersion specifies the version of the software, which can vary wildly,
Expand Down
12 changes: 12 additions & 0 deletions charts/timescaledb-single/templates/pgbackrest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,18 @@ spec:
- |
{"type": {{ quote .type }}}
- "http://{{ template "timescaledb.fullname" $ }}-backup:8081/backups/"
{{- with $.Values.backup.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with $.Values.backup.tolerations }}
tolerations:
{{- toYaml . | nindent 12 }}
{{- end }}
{{- if $.Values.backup.affinity }}
affinity:
{{- $.Values.backup.affinity | toYaml | nindent 12 }}
{{- end }}
...
{{- end }}
{{ end }}
10 changes: 10 additions & 0 deletions charts/timescaledb-single/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,16 @@
"null"
]
},
"affinity": {
"additionalProperties": true,
"type": "object"
},
"tolerations": {
"type": "array"
},
"nodeSelector": {
"type": "object"
},
"jobs": {
"type": "array"
},
Expand Down
7 changes: 7 additions & 0 deletions charts/timescaledb-single/values.schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -472,6 +472,13 @@ properties:
type:
- object
- "null"
nodeSelector:
type: object
tolerations:
type: array
affinity:
type: object
additionalProperties: true
secrets:
type: object
additionalProperties: false
Expand Down
21 changes: 21 additions & 0 deletions charts/timescaledb-single/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,27 @@ backup:
# requests:
# cpu: 100m
# memory: 128Mi
# https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
# tolerations:
# - key: node-group
# operator: Equal
# value: spot-job
tolerations: []
# https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity
# affinity:
# nodeAffinity:
# requiredDuringSchedulingIgnoredDuringExecution:
# nodeSelectorTerms:
# - matchExpressions:
# - key: node-group
# operator: In
# values:
# - spot-job
affinity: {}
# https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#nodeselector
# nodeSelector:
# node-group: spot-job
nodeSelector: {}

# When creating a *new* deployment, the default is to initialize (using initdb) the database.
# If however, you want to initialize the database using an existing backup, you can do so by
Expand Down
Loading