[Feature Request] barman-cloud plugin should support virtual-hosted style addressing for S3-compatible storage
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 55/100
Línea de trabajo
Empieza localizando la configuración de barman-cloud ObjectStore y la construcción del cliente boto3 descritas en la issue. Sigue cómo se pasa endpointURL al cliente y, después, verifica que un estilo de direccionamiento configurable admita tanto solicitudes virtual-hosted como path-style para almacenamiento compatible con S3.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Description:
I'm using CloudNativePG with the barman-cloud plugin (version 0.9.0) for PostgreSQL backups to Alibaba Cloud OSS. However, I've encountered a critical issue: the plugin only supports path-style addressing, while Alibaba Cloud OSS (and many other S3-compatible services) now require virtual-hosted style addressing.
Problem Details:
AWS has deprecated path-style addressing since September 30, 2023
Many cloud providers (Alibaba Cloud OSS, Google Cloud Storage, etc.) require or strongly recommend virtual-hosted style
The barman-cloud plugin doesn't provide any configuration parameter for addressing_style
When endpointURL is specified, it defaults to path-style addressing
Current Workaround:
Currently, users have to:
Use custom backup solutions instead of the official plugin
Or use unsupported path-style endpoints (if available)
Expected Behavior:
The barman-cloud plugin should support both addressing styles with a configuration parameter like:
configuration:
destinationPath: "s3://bucket-name/"
endpointURL: "https://bucket-name.oss-cn-region.aliyuncs.com"
s3AddressingStyle: "virtual" # or "path"
Or automatically detect the appropriate style based on the endpoint URL format.
Technical Background:
-
AWS SDK (boto3) already supports addressing_style parameter in boto3.session.Config
-
Virtual-hosted style is now the standard for S3-compatible services
-
Path-style addressing has been deprecated by AWS
Impact:
This limitation prevents users from using the official plugin with:
-
Alibaba Cloud OSS
-
Google Cloud Storage
-
DigitalOcean Spaces
-
And other S3-compatible services that enforce virtual-hosted style
Proposed Solution:
Add a new parameter s3AddressingStyle to the ObjectStore configuration that gets passed to the underlying boto3 client configuration.
Code Reference:
In barman-cloud implementation, it should configure boto3 like:
config = boto3.session.Config(
s3={'addressing_style': addressing_style}
)
s3_client = boto3.client(
's3',
endpoint_url=endpoint,
config=config
)
Environment:
-
CloudNativePG: 1.28.0
-
barman-cloud plugin: 0.9.0
-
Kubernetes: 1.32.7
-
Storage: Alibaba Cloud OSS
Additional Context:
- Attempted Solutions:
[ ] I have tried setting the environment variable AWS_S3_ADDRESSING_STYLE=virtual in the pod configuration, but it has no effect
-
Tested various endpointURL formats including:
-
https://bucket-name.oss-cn-region.aliyuncs.com (virtual-hosted style)
-
https://oss-cn-region.aliyuncs.com (path-style)
-
-
The plugin consistently uses path-style addressing regardless of the endpoint URL format
- Current Status:
-
Alibaba Cloud OSS strictly enforces virtual-hosted style addressing
-
AWS has completely phased out path-style support
-
This issue is becoming critical as more S3-compatible services adopt virtual-hosted style
- Reproduction Steps:
-
Configure barman-cloud plugin with Alibaba Cloud OSS endpoint
-
Set endpointURL to virtual-hosted style format
-
Observe that the plugin still attempts path-style requests
-
Receive errors from OSS indicating path-style is not supported
- Workaround Limitations:
-
Custom backup scripts lack the integration and reliability of the official plugin
-
Alternative S3-compatible endpoints may not be available in all regions
-
This forces users to choose between functionality and using the official tooling
- Lenguaje dominante
- Go
- Estrellas
- 196
- Forks
- 76
- Merge medio
- 5 d 17 h
- PR fusionados (30 d)
- 22
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de cloudnative-pg/plugin-barman-cloud
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
cloudnative-pg/plugin-barman-cloud#1117 · 1 reacción ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 86/100
cloudnative-pg/plugin-barman-cloud#1104 · 4 reacciones ·
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 82/100
cloudnative-pg/plugin-barman-cloud#1102 ·
Los mantenedores suelen responder en 1 día
-
Catalog maintenance deletes completed Backup objects after a short barman-cloud-backup-list resultAbierto
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
cloudnative-pg/plugin-barman-cloud#1115 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 3/5 1-2 días Aptitud para principiantes 68/100
cloudnative-pg/plugin-barman-cloud#1100 ·
Los mantenedores suelen responder en 1 día
Todos los issues de cloudnative-pg/plugin-barman-cloud
Issues similares
-
cvss-severity:high devguard l3montree-cybersecurity/devguard/devguard pkg:golang/github.com/l3montree-dev/devguard risk:low state:open
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
l3montree-dev/devguard#3146 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
CLI
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
databricks/cli#6910 ·
Los mantenedores suelen responder en 1 día
-
Table presenter appends a spurious ", ..." to the FIX column when all fix versions are already shownAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
canonical/microceph#900 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
vulncheck or vulndb
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día