@@ -169,6 +169,9 @@ type PostgresSpec struct {
169169
170170 // +optional
171171 Replication * PostgresReplication `json:"replication,omitempty"`
172+
173+ // +optional
174+ ReadReaplicas []ReadReplicaSpec `json:"readReaplicas,omitempty"`
172175}
173176
174177type PostgresConfiguration struct {
@@ -219,6 +222,29 @@ type ArbiterSpec struct {
219222 Tolerations []core.Toleration `json:"tolerations,omitempty"`
220223}
221224
225+ type ReadReplicaSpec struct {
226+ // Name specifies the name of the read replica
227+ Name string `json:"name"`
228+ // Number of instances to deploy for a Postgres database.
229+ Replicas * int32 `json:"replicas,omitempty"`
230+ // Compute Resources required by the sidecar container.
231+ // +optional
232+ Resources core.ResourceRequirements `json:"resources,omitempty"`
233+ // NodeSelector is a selector which must be true for the pod to fit on a node.
234+ // Selector which must match a node's labels for the pod to be scheduled on that node.
235+ // More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/
236+ // +optional
237+ // +mapType=atomic
238+ NodeSelector map [string ]string `json:"nodeSelector,omitempty"`
239+ // If specified, the pod's tolerations.
240+ // +optional
241+ Tolerations []core.Toleration `json:"tolerations,omitempty"`
242+ // StorageType can be durable (default) or ephemeral
243+ StorageType StorageType `json:"storageType,omitempty"`
244+ // Storage to specify how storage shall be used.
245+ Storage * core.PersistentVolumeClaimSpec `json:"storage,omitempty"`
246+ }
247+
222248// PostgreLeaderElectionConfig contains essential attributes of leader election.
223249type PostgreLeaderElectionConfig struct {
224250 // LeaseDuration is the duration in second that non-leader candidates will
0 commit comments