Description
Please, answer some short questions which should help us to understand your problem / question better?
- Which image of the operator are you using? registry.opensource.zalan.do/acid/postgres-operator:v1.11.0
- Where do you run it - cloud or metal? Kubernetes or OpenShift? Azure AKS
- Are you running Postgres Operator in production? yes
- Type of issue? Enhancement request
So this is based on hashicorp/terraform-provider-kubernetes#1841 (comment)
Anyway any change to the manifests in Terraform will replace the postgresql crd causing the data to be wiped and the server to be empty.
This seems to be used in a couple of places like (6 total in that file):
and
Both of these should have known specs and it would be very useful if they could be fully specced, which would resolve any problems with programs like terraform or pulumi that require fully specified schema's to do their job and use in-place updates.
An alternative would be to make the operator tolerant to replacement of CRD resources of course, but that feels a bit less clean.