Skip to content

Commit

Permalink
Add in a value to allow for the configuration of the termination grac…
Browse files Browse the repository at this point in the history
…e period of the stateful set
  • Loading branch information
udnay committed Sep 18, 2024
1 parent ca93e03 commit 61e0c17
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions cockroachdb/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,7 @@ For details see the [`values.yaml`](values.yaml) file.
| `serviceMonitor.scrapeTimeout` | ServiceMonitor scrape timeout | `nil` |
| `serviceMonitor.tlsConfig` | Additional TLS configuration of ServiceMonitor | `{}` |
| `serviceMonitor.namespaced` | Limit ServiceMonitor to current namespace | `false` |
| `statefulSets.terminationGracePeriodSeconds` | Sets the termination grace period for the CRDB container | `300` |
| `storage.hostPath` | Absolute path on host to store data | `""` |
| `storage.persistentVolume.enabled` | Whether to use PersistentVolume to store data | `yes` |
| `storage.persistentVolume.size` | PersistentVolume size | `100Gi` |
Expand Down
2 changes: 1 addition & 1 deletion cockroachdb/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ spec:
{{- end }}
# No pre-stop hook is required, a SIGTERM plus some time is all that's
# needed for graceful shutdown of a node.
terminationGracePeriodSeconds: 300
terminationGracePeriodSeconds: {{ .Values.statefulset.terminationGracePeriodSeconds }}
containers:
- name: db
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
Expand Down
1 change: 1 addition & 0 deletions cockroachdb/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ conf:
attrs:

statefulset:
terminationGracePeriodSeconds: 300 # Change the statefulset terminationGracePeriodSeconds (default is 5min)
replicas: 3
updateStrategy:
type: RollingUpdate
Expand Down

0 comments on commit 61e0c17

Please sign in to comment.