[Feature]: support changing plugin-barman-cloud-sidecar image for air-gap envionment
Is there an existing issue already for this feature request/idea?
- [x] I have searched for an existing issue, and could not find anything. I believe this is a new feature request to be evaluated.
What problem is this feature going to solve? Why should it be added?
My environment to deploy cnpg is in air-gap so cannot use ghcr.io container registry with below error messages
Events:
Type Reason Age From Message
Warning Failed 43m (x257 over 23h) kubelet Failed to pull image "ghcr.io/cloudnative-pg/plugin-barman-cloud-sidecar:v0.5.0": initializing source docker://ghcr.io/cloudnative-pg/plugin-barman-cloud-sidecar:v0.5.0: pinging container registry ghcr.io: Get "https://ghcr.io/v2/": dial tcp 20.200.245.241:443: connect: connection timed out
Normal BackOff 3m42s (x5865 over 23h) kubelet Back-off pulling image "ghcr.io/cloudnative-pg/plugin-barman-cloud-sidecar:v0.5.0"
But there's no way to override sidecar image url to use private image registry.
Describe the solution you'd like
It needs to override sidecar image in cluster crd.
Describe alternatives you've considered
Cluster CRD like this
plugins:
- name: barman-cloud.cloudnative-pg.io
isWALArchiver: true
parameters:
barmanObjectName: my-backup
image: my-private-registry/my-repo/my-custom-barman-cloud-sidecar:TAG
Additional context
No response
Backport?
Yes
Are you willing to actively contribute to this feature?
No
Code of Conduct
- [x] I agree to follow this project's Code of Conduct
@cloudinfrasolution
I'm also interested in a solution for this as we have China deployments, as such cannot reliably access any popular container registry & need to replicate all required images onto ECR private registry.
Quick question, in this PR title you mention the sidecar only. Is there an existing solution to be able to specify the barman cloud image, as I actually need to override the following:
ghcr.io/cloudnative-pg/plugin-barman-cloud:v0.4.0ghcr.io/cloudnative-pg/plugin-barman-cloud-sidecar:v0.4.0
https://github.com/cloudnative-pg/plugin-barman-cloud/issues/391#issuecomment-2943098794
as the issue https://github.com/cloudnative-pg/plugin-barman-cloud/issues/391#issuecomment-2943098794, SIDEDCAR_IMAGE secret can change the sidecar image registry but it's workaround. manifest is the better way to change it from a configuration management perspective.
The name of the sidecar image can be changed with the SIDECAR_IMAGE environment variable in the plugin deployment.
After changing it, restart the Pod of the plugin to make sure the plugin got the new setting.
Covered by #1147, which adds the sidecarImage plugin parameter. Closing.