You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/administrator.md
+30
Original file line number
Diff line number
Diff line change
@@ -151,6 +151,36 @@ Postgres pods by default receive tolerations for `unreachable` and `noExecute` t
151
151
Depending on your setup, you may want to adjust these parameters to prevent master pods from being evicted by the Kubernetes runtime.
152
152
To prevent eviction completely, specify the toleration by leaving out the `tolerationSeconds` value (similar to how Kubernetes' own DaemonSets are configured)
153
153
154
+
### Enable pod anti affinity
155
+
156
+
To ensure Postgres pods are running on different topologies, you can use [pod anti affinity](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/)
157
+
and configure the required topology in the operator ConfigMap.
158
+
159
+
Enable pod anti affinity by adding following line to the operator ConfigMap:
160
+
161
+
```yaml
162
+
apiVersion: v1
163
+
kind: ConfigMap
164
+
metadata:
165
+
name: postgres-operator
166
+
data:
167
+
enable_pod_antiaffinity: "true"
168
+
```
169
+
170
+
By default the topology key for the pod anti affinity is set to `kubernetes.io/hostname`,
171
+
you can set another topology key e.g. `failure-domain.beta.kubernetes.io/zone` by adding following line
172
+
to the operator ConfigMap, see [built-in node labels](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#interlude-built-in-node-labels) for available topology keys:
0 commit comments