zalando / zalando/postgres-operator

CRDS managed with Terraform always want a recreate

Open
#2,021 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
5.2k
Forks
1.1k
Avg merge
2d 16h
Merged PRs (30d)
3

Description

Which image of the operator are you using? e.g. registry.opensource.zalan.do/acid/postgres-operator:v1.8.2
Where do you run it - cloud or metal? Kubernetes or OpenShift? [Bare Metal K8s]
Are you running Postgres Operator in production? [not yet]
Type of issue? [feature requrest]

When managing your CRDS with Terraform via kubernetes_manifest resource, any change to postgresql resource after it has been created results in recreate action, which involves deletion and creation, which is obviously unnecessary and bad. Could you please fix this? I'm using many other CRDS (istio, cert-manager, rmq, redis) and all of them don't have this issue.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the behavior with Terraform's kubernetes_manifest resource and a managed postgresql resource, comparing an initial apply with a subsequent change. Trace the operator's CRD handling and Terraform's resource diff to identify why updates become recreates. Done means changing the postgresql resource updates it without deletion and recreation.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, kubernetes, postgresql, terraform
Domain
database, devops, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.