setup-filesystem init container resources are never updated
Summary
The init container setup-filesystem's resources are only set on cluster creation. Any subsequent changes won't get applied.
Current Behaviour
- The
setup-filesystemresources are set to thepatroniresources when creating the instance - Changing the
patroniresources isn't reflected insetup-filesystem
This creates issues when trying to downscale due to k8s cluster resource usage. Because the init container is stuck with the initial values, the k8s scheduler and quota handling require the setup-filesystem container requests, even if patroni is lower.
Steps to reproduce
- Create a cluster with high resources
- Lower the
patroniresources after creation - Observe that
setup-filesystemis still the initial value
Expected Behaviour
setup-filesystem init container resources should either be:
- Always the same as
patroni - Be independendent as other init and sidecar containers
Possible Solution
See expected behaviour.
Environment
- StackGres version: 1.17.x
- Kubernetes version: 1.31.x
- Cloud provider or hardware configuration:
Relevant logs and/or screenshots
N/A