cloudnative-pg / cloudnative-pg/plugin-barman-cloud
[Feature] Support env expansion in `configuration.{destinationPath,endpointURL}`
- 主要言語
- Go
- スター
- 191
- フォーク
- 72
- 平均マージ
- 1日 16時間
- マージ済み PR(30日)
- 18
説明
When pointing to a Bucket created by another system (like Ceph), the name/endpoint of the bucket is often stored in a `ConfigMap` rather than being known ahead of time. I'm able to use `instanceSidecarConfiguration.env` to pass the values through to the side car, but it doesn't seem to support expanding these values.
```
{"level":"info","ts":"2025-09-27T15:54:46.914931355Z","logger":"barman-cloud-wal-restore","msg":"2025-09-27 15:54:46,914 [51] ERROR: Barman cloud WAL restore exception: Invalid endpoint: https://$BUCKET_HOST","pipe":"stderr","logging_pod":"pg-foobar"}
```
```yaml
apiVersion: barmancloud.cnpg.io/v1
kind: ObjectStore
metadata:
name: db-backup
spec:
instanceSidecarConfiguration:
env:
- name: BUCKET_NAME
valueFrom:
configMapKeyRef:
name: db-backup-data-bucket
key: BUCKET_NAME
- name: BUCKET_HOST
valueFrom:
configMapKeyRef:
name: db-backup-data-bucket
key: BUCKET_HOST
retentionPolicy: "7d"
configuration:
destinationPath: s3://$BUCKET_NAME/
endpointURL: https://$BUCKET_HOST
s3Credentials:
accessKeyId:
name: db-backup-data-bucket
key: AWS_ACCESS_KEY_ID
secretAccessKey:
name: db-backup-data-bucket
key: AWS_SECRET_ACCESS_KEY
wal:
compression: gzip
data:
compression: gzip
```
コントリビューションガイド
調査の方向性
まず、configuration.destinationPath と configuration.endpointURL が instanceSidecarConfiguration.env および Kubernetes ConfigMap の値と併せてどのように処理されるかを追跡してください。ObjectStore の例で動作を確認してください。sidecar が Barman Cloud を呼び出す前に、BUCKET_NAME と BUCKET_HOST が両方のフィールドで展開される必要があります。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- go, kubernetes
- 領域
- backend, cloud
- issue の種類
- 機能追加
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 45/100