diff --git a/cmd/acb-index-builder/s3.go b/cmd/acb-index-builder/s3.go index 1084bcb..a3b5311 100644 --- a/cmd/acb-index-builder/s3.go +++ b/cmd/acb-index-builder/s3.go @@ -26,7 +26,7 @@ func NewS3Client(endpoint, accessKey, secretKey, bucket string) (*S3Client, erro config.WithCredentialsProvider(credentials.NewStaticCredentialsProvider( accessKey, secretKey, "", )), - config.WithRegion("auto"), + config.WithRegion("us-east-1"), ) if err != nil { return nil, fmt.Errorf("failed to load AWS config: %w", err) diff --git a/cmd/acb-worker/b2.go b/cmd/acb-worker/b2.go index 543ab4d..60349c5 100644 --- a/cmd/acb-worker/b2.go +++ b/cmd/acb-worker/b2.go @@ -22,14 +22,15 @@ type B2Client struct { // NewB2Client creates a new B2 client. func NewB2Client(cfg *Config) *B2Client { // Load AWS config with B2 credentials - // Use region "auto" for custom S3-compatible endpoints (ARMOR/B2) + // For S3-compatible endpoints (ARMOR/B2), use us-east-1 as a placeholder region + // The actual endpoint is overridden via BaseEndpoint in the S3 client awsCfg, err := config.LoadDefaultConfig(context.TODO(), config.WithCredentialsProvider(credentials.NewStaticCredentialsProvider( cfg.B2AccessKey, cfg.B2SecretKey, "", )), - config.WithRegion("auto"), + config.WithRegion("us-east-1"), ) if err != nil { panic(fmt.Sprintf("failed to load AWS config: %v", err))