zalando / zalando/postgres-operator
pod_environment_secret for cronjob
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? ghcr.io/zalando/postgres-operator:v1.11.0
- Where do you run it - cloud or metal? Kubernetes
- Are you running Postgres Operator in production? yes
- Type of issue? Feature Request
We have set for our operator pod_environment_secret variable, so variables like AWS_ACCESS_KEY_ID are not hardcoded in the pod specification. The problem is that we have the logicalbackup enabled and the cronjob for that doesn't use it, but hardcodes the values of the envars. Is there any way to do that? Or does the possibility of implement that feature in the near future?
The code is here: https://github.com/zalando/postgres-operator/blob/68c4b496365f02afb57b9066492dfa319120622a/pkg/cluster/k8sres.go#L2512
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at pkg/cluster/k8sres.go around line 2512 and inspect how the logical-backup CronJob environment is built. Compare that handling with pod_environment_secret usage elsewhere in the operator. Done means the logical-backup CronJob receives the configured secret-based environment variables instead of hardcoded values.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, kubernetes, postgresql
- Domain
- databases, infrastructure
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100