Skip to content

Commit 26f9b9c

Browse files
CLD-866: toplogySpreadConstraints feature changes commit (#154)
1 parent ee82ae1 commit 26f9b9c

File tree

3 files changed

+14
-0
lines changed

3 files changed

+14
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ Following table lists all the parameters supported by the latest MarkLogic Helm
115115
| `license.key` | Set MarkLogic license key installed | `""` |
116116
| `license.licensee` | Set MarkLogic licensee information | `""` |
117117
| `affinity` | Affinity for MarkLogic pods assignment | `{}` |
118+
| `topologySpreadConstraints` | POD Topology Spread Constraints to spread Pods across cluster | `[]` |
118119
| `nodeSelector` | Node labels for MarkLogic pods assignment | `{}` |
119120
| `persistence.enabled` | Parameter to enable MarkLogic data persistence using Persistence Volume Claim (PVC). If set to false, EmptyDir will be used. | `true` |
120121
| `persistence.storageClass` | Storage class for MarkLogic data volume, leave empty to use the default storage class | `""` |

charts/templates/statefulset.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,9 @@ spec:
2222
{{- with .Values.affinity }}
2323
affinity: {{- toYaml . | nindent 8}}
2424
{{- end }}
25+
{{- with .Values.topologySpreadConstraints }}
26+
topologySpreadConstraints: {{- toYaml . | nindent 6}}
27+
{{- end }}
2528
terminationGracePeriodSeconds: {{ .Values.terminationGracePeriod }}
2629
{{- if ne .Values.bootstrapHostName "" }}
2730
initContainers:

charts/values.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,16 @@ affinity:
9393
- marklogic
9494
topologyKey: kubernetes.io/hostname
9595

96+
## Configure POD Topology Spread Constraints to spread Pods across cluster
97+
## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/topology-spread-constraints/
98+
topologySpreadConstraints: []
99+
# - maxSkew: 1
100+
# topologyKey: topology.kubernetes.io/zone
101+
# whenUnsatisfiable: ScheduleAnyway
102+
# labelSelector:
103+
# matchLabels:
104+
# app.kubernetes.io/name: marklogic
105+
96106
## Configure NodeSelector property for scheduling pods to nodes
97107
## ref: https://kubernetes.io/docs/tasks/configure-pod-container/assign-pods-nodes/#create-a-pod-that-gets-scheduled-to-your-chosen-node
98108
nodeSelector: {}

0 commit comments

Comments
 (0)