Skip to content

Commit

Permalink
Chore: use auto bucket lookup type
Browse files Browse the repository at this point in the history
Signed-off-by: Zhiyu Wang <[email protected]>
(cherry picked from commit 1ab089e)
  • Loading branch information
zhiyu0729 authored and github-actions[bot] committed Aug 31, 2023
1 parent 961eb5c commit 0785672
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions pkg/minio/minio.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,11 @@ type MinioClient struct {
// NewClient creates a new Minio storage client.
func NewClient(bucket *sourcev1.Bucket, secret *corev1.Secret) (*MinioClient, error) {
opt := minio.Options{
Region: bucket.Spec.Region,
Secure: !bucket.Spec.Insecure,
BucketLookup: minio.BucketLookupPath,
Region: bucket.Spec.Region,
Secure: !bucket.Spec.Insecure,
// About BucketLookup, it should be noted that not all S3 providers support
// path-type access (e.g., Ali OSS). Hence, we revert to using the default
// auto access, which we believe can cover most use cases.
}

if secret != nil {
Expand Down

0 comments on commit 0785672

Please sign in to comment.