percona / percona-xtradb-cluster-operator

Percona Operator for MySQL based on Percona XtraDB Cluster
https://www.percona.com/doc/kubernetes-operator-for-pxc/index.html
Apache License 2.0
511 stars 187 forks source link

Allow users to set the size of pxc equals to 1 through percona-xtradb-cluster-operator/deploy/cr.yaml #1733

Open kevin-baas opened 3 months ago

kevin-baas commented 3 months ago

Proposal

When I set pxc to equal 1 through percona-xtradb-cluster-operator/deploy/cr.yaml, it doesn't work

Use-Case

No response

Is this a feature you are interested in implementing yourself?

No

Anything else?

No response

tombojer commented 3 months ago

Deploying the cluster with only one node is working for me. Because running the cluster with only one node is seen as an unsafe configuration you have to set allowUnsafeConfigurations to true.

From the docs:

allowUnsafeConfigurations Prevents users from configuring a cluster with unsafe parameters such as starting the cluster with the number of Percona XtraDB Cluster instances which is less than 3, more than 5, or is an even number, with less than 2 ProxySQL or HAProxy Pods, or without TLS/SSL certificates (if false, unsafe parameters will be automatically changed to safe defaults)