From 974a8b4e9e1e94bb410ebfb43b4ad20ec93009b6 Mon Sep 17 00:00:00 2001 From: Maho Takara Date: Thu, 30 May 2024 08:02:06 +0000 Subject: [PATCH] Remove config.WithRegion() --- pkg/bucket/s3.go | 2 +- pkg/bucket/s3_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/bucket/s3.go b/pkg/bucket/s3.go index 67624c00f..bfe38869b 100644 --- a/pkg/bucket/s3.go +++ b/pkg/bucket/s3.go @@ -62,7 +62,7 @@ type s3Bucket struct { // NewS3Bucket creates a Bucket that manage object in S3. func NewS3Bucket(name string, optFns ...func(*s3.Options)) (Bucket, error) { - cfg, err := config.LoadDefaultConfig(context.Background(), config.WithRegion("us-west-2")) + cfg, err := config.LoadDefaultConfig(context.Background()) if err != nil { return nil, err } diff --git a/pkg/bucket/s3_test.go b/pkg/bucket/s3_test.go index fbaa14e87..414b90fad 100644 --- a/pkg/bucket/s3_test.go +++ b/pkg/bucket/s3_test.go @@ -45,7 +45,7 @@ var _ = Describe("S3Bucket", func() { AccessKeyID: "minioadmin", SecretAccessKey: "minioadmin", Source: "minio default credentials", - }}), config.WithRegion("us-west-2")) + }}), config.WithRegion("us-west-1")) Expect(err).NotTo(HaveOccurred()) client := s3.NewFromConfig(cfg, WithEndpointURL("http://localhost:9000"),