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

Inconsistent methods to access an S3-compatible endpoint #182

Open
tgquan67 opened this issue Sep 11, 2024 · 1 comment
Open

Inconsistent methods to access an S3-compatible endpoint #182

tgquan67 opened this issue Sep 11, 2024 · 1 comment

Comments

@tgquan67
Copy link

Describe the bug

When I configure a MinIO bucket as backend storage for BaGetter, if I use IP address for the endpoint, it works normally as expected. However if I use the FQDN instead of IP address, it seems BaGetter will try to prepend the bucket name to the endpoint's FQDN and expect the DNS server to be able to resolve that, as well as the storage server to support that. However in my case it's not desirable. Since this behavior was not described in the documentation, is there any clear flag/instruction to clearly define this behavior?

To Reproduce

Steps to reproduce the behavior:

  1. Using this version of BaGetter '1.4.8'
  2. Define storage as follow
"Storage": {
    "Type": "AwsS3",
    "Endpoint": "http://minio.minio-storage-tenant-1.svc.cluster.local",
    "Bucket": "testbucket",
    "AccessKey": "something",
    "SecretKey": "something"
},
  1. BaGetter will try to access testbucket.minio.minio-storage-tenant-1.svc.cluster.local, which is not defined or resolved.

Expected behavior

Interact with the endpoint in the same way as when Endpoint is defined as "Endpoint": "http://10.0.9.106"

@viceice
Copy link

viceice commented Oct 8, 2024

This probably needs a new PathStyle=true config option

? new AmazonS3Config { ServiceURL = options.Endpoint.AbsoluteUri }

https://github.com/aws/aws-sdk-net/blob/b5c10d5d48299f6c68286ee48039bc4ecbc21019/sdk/src/Services/S3/Custom/AmazonS3Config.cs#L67

So the aws sdk is using path style urls.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants