Skip to content
Closed
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
3 changes: 3 additions & 0 deletions chart/templates/scheduler/scheduler-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,9 @@ spec:
{{- if and $stateful .Values.scheduler.updateStrategy }}
updateStrategy: {{- toYaml .Values.scheduler.updateStrategy | nindent 4 }}
{{- end }}
{{- if and $stateful .Values.workers.persistence.persistentVolumeClaimRetentionPolicy -}}
persistentVolumeClaimRetentionPolicy: {{ .Values.workers.persistence.persistentVolumeClaimRetentionPolicy | nindent 4 }}
{{- end }}
{{- if and (not $stateful) .Values.scheduler.strategy }}
strategy: {{- toYaml .Values.scheduler.strategy | nindent 4 }}
{{- end }}
Expand Down
3 changes: 3 additions & 0 deletions chart/templates/triggerer/triggerer-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,9 @@ spec:
{{- if and (not $persistence) (.Values.triggerer.strategy) }}
strategy: {{- toYaml .Values.triggerer.strategy | nindent 4 }}
{{- end }}
{{- if and $persistence .Values.triggerer.persistence.persistentVolumeClaimRetentionPolicy -}}
persistentVolumeClaimRetentionPolicy: {{ .Values.triggerer.persistence.persistentVolumeClaimRetentionPolicy | nindent 4 }}
{{- end }}
template:
metadata:
labels:
Expand Down
3 changes: 3 additions & 0 deletions chart/templates/workers/worker-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ spec:
{{- if $revisionHistoryLimit }}
revisionHistoryLimit: {{ $revisionHistoryLimit }}
{{- end }}
{{- if and $persistence .Values.workers.persistence.persistentVolumeClaimRetentionPolicy -}}
persistentVolumeClaimRetentionPolicy: {{ .Values.workers.persistence.persistentVolumeClaimRetentionPolicy | nindent 4 }}
{{- end }}
selector:
matchLabels:
tier: airflow
Expand Down
38 changes: 38 additions & 0 deletions chart/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1588,6 +1588,25 @@
"type": "boolean",
"default": true
},
"persistentVolumeClaimRetentionPolicy": {
"type": [
"object",
"null"
],
"additionalProperties": false,
"properties": {
"whenDeleted": {
"description": "Whether to retain the PVC when the StatefulSet is deleted.",
"type": "string",
"default": "Retain"
},
"whenScaled": {
"description": "Whether to retain the PVC when the StatefulSet is scaled.",
"type": "string",
"default": "Retain"
}
}
},
"size": {
"description": "Volume size for worker StatefulSet.",
"type": "string",
Expand Down Expand Up @@ -2861,6 +2880,25 @@
"type": "string",
"default": "100Gi"
},
"persistentVolumeClaimRetentionPolicy": {
"type": [
"object",
"null"
],
"additionalProperties": false,
"properties": {
"whenDeleted": {
"description": "Whether to retain the PVC when the StatefulSet is deleted.",
"type": "string",
"default": "Retain"
},
"whenScaled": {
"description": "Whether to retain the PVC when the StatefulSet is scaled.",
"type": "string",
"default": "Retain"
}
}
},
"storageClassName": {
"description": "If using a custom StorageClass, pass name ref to all StatefulSets here.",
"type": [
Expand Down
7 changes: 7 additions & 0 deletions chart/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -617,6 +617,11 @@ workers:
persistence:
# Enable persistent volumes
enabled: true
# persistentVolumeClaimRetentionPolicy if statefulset is used, to determine delete when scaled\removed
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit:

Suggested change
# persistentVolumeClaimRetentionPolicy if statefulset is used, to determine delete when scaled\removed
# persistentVolumeClaimRetentionPolicy if statefulset is used, to determine delete when scaled/removed

persistentVolumeClaimRetentionPolicy: ~
# persistentVolumeClaimRetentionPolicy:
# whenDeleted: Delete
# whenScaled: Delete
# Volume size for worker StatefulSet
size: 100Gi
# If using a custom storageClass, pass name ref to all statefulSets here
Expand Down Expand Up @@ -1426,6 +1431,8 @@ triggerer:
persistence:
# Enable persistent volumes
enabled: true
# persistentVolumeClaimRetentionPolicy if statefulset is used, to determine delete when scaled\removed
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# persistentVolumeClaimRetentionPolicy if statefulset is used, to determine delete when scaled\removed
# persistentVolumeClaimRetentionPolicy if statefulset is used, to determine delete when scaled/removed

persistentVolumeClaimRetentionPolicy: ~
# Volume size for triggerer StatefulSet
size: 100Gi
# If using a custom storageClass, pass name ref to all statefulSets here
Expand Down