Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] S3 storageprovider doesn't support path style access #8867

Closed
leonliao opened this issue Jan 24, 2025 · 2 comments · Fixed by #8868
Closed

[BUG] S3 storageprovider doesn't support path style access #8867

leonliao opened this issue Jan 24, 2025 · 2 comments · Fixed by #8868
Assignees
Labels
kind/bug Something isn't working
Milestone

Comments

@leonliao
Copy link
Contributor

Describe the bug
Tried to use s3/oss storageprovider to create backuprepo to store backup into own-made S3 compatible object storage service, which only supports the path-style access. But the backuprepo failed to pass the pre-check, because of the pre-check always uses virtual hosted style to access S3 service.

To Reproduce
Steps to reproduce the behavior:
1.

kubectl create secret generic s3-credential-for-backuprepo \
  -n default \
  --from-literal=accessKeyId=xxxPLE \
  --from-literal=secretAccessKey=wJyyyyyyyyyyPLEKEY

create backup repo

apiVersion: dataprotection.kubeblocks.io/v1alpha1
kind: BackupRepo
metadata:
  name: my-repo
  annotations:
    dataprotection.kubeblocks.io/is-default-repo: "true"
spec:
  storageProviderRef: s3
  accessMethod: Tool
  pvReclaimPolicy: Retain
  volumeCapacity: 100Gi
  config:
    bucket: backupbucket
    endpoint: "http://s3-compatible.internal.objectstorage.com"
    region: Useless
  credential:
    name: s3-credential-for-backuprepo
    namespace: default
  1. failure
Error: push to "/precheck.txt": RequestError: send request failed
caused by: Put "http://backupbucket.s3-compatible.internal.objectstorage.com/": dial tcp: lookup backupbucket.s3-compatible.internal.objectstorage.com  on 10.96.0.10:53: no such host

Desktop (please complete the following information):

  • OS: Linux
  • Version 0.9.2
@leonliao leonliao added the kind/bug Something isn't working label Jan 24, 2025
@zjx20
Copy link
Contributor

zjx20 commented Jan 24, 2025

The s3 StorageProvider is for the AWS S3 service. For self-hosted S3-compatible services, use the minio StorageProvider instead.

leonliao added a commit to leonliao/kubeblocks that referenced this issue Jan 24, 2025
leonliao added a commit to leonliao/kubeblocks that referenced this issue Jan 24, 2025
@leonliao
Copy link
Contributor Author

The s3 StorageProvider is for the AWS S3 service. For self-hosted S3-compatible services, use the minio StorageProvider instead.

OK. Will try. I thought adding force_path_style to enable the path-style

leonliao added a commit to leonliao/kubeblocks that referenced this issue Jan 24, 2025
leonliao added a commit to leonliao/kubeblocks that referenced this issue Jan 24, 2025
@github-actions github-actions bot added this to the Release 0.9.3 milestone Jan 24, 2025
apecloud-bot pushed a commit that referenced this issue Jan 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants