From 0e895b517b600aff48d4c5f4925edd3075fa7a57 Mon Sep 17 00:00:00 2001 From: Noah Treuhaft Date: Mon, 14 Sep 2026 14:12:02 -0400 Subject: [PATCH] change AWS_S3_ENDPOINT to AWS_ENDPOINT_URL_S3 AWS_ENDPOINT_URL_S3 follows the convention for service-specific endpoints described at https://docs.aws.amazon.com/sdkref/latest/guide/feature-ss-endpoints.html. --- book/src/dev/integrations/s3.md | 2 +- pkg/s3io/s3io.go | 4 ++-- testdata/s3.sh | 1 - 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/book/src/dev/integrations/s3.md b/book/src/dev/integrations/s3.md index 834bdbf825..6eef4a8add 100644 --- a/book/src/dev/integrations/s3.md +++ b/book/src/dev/integrations/s3.md @@ -30,7 +30,7 @@ You can create `~/.aws/credentials` by installing the ## Endpoint -To use S3-compatible storage not provided by AWS, set the `AWS_S3_ENDPOINT` +To use S3-compatible storage not provided by AWS, set the `AWS_ENDPOINT_URL_S3` environment variable to the hostname or URI of the provider. ## Wildcard Support diff --git a/pkg/s3io/s3io.go b/pkg/s3io/s3io.go index f741cd1185..ca04a16622 100644 --- a/pkg/s3io/s3io.go +++ b/pkg/s3io/s3io.go @@ -27,8 +27,8 @@ func NewClient(cfg *aws.Config) *s3.S3 { cfg = &aws.Config{} } // Add ability to override s3 endpoint via env variable (the aws sdk doesn't - // support this). This is mostly for system tests w/ minio. - if endpoint := os.Getenv("AWS_S3_ENDPOINT"); cfg.Endpoint == nil && endpoint != "" { + // support this). This is mostly for system tests. + if endpoint := os.Getenv("AWS_ENDPOINT_URL_S3"); cfg.Endpoint == nil && endpoint != "" { cfg.Endpoint = new(endpoint) cfg.S3ForcePathStyle = new(true) // https://github.com/minio/minio/tree/master/docs/config#domain } diff --git a/testdata/s3.sh b/testdata/s3.sh index 965833cc8f..7c45e5a28b 100644 --- a/testdata/s3.sh +++ b/testdata/s3.sh @@ -29,4 +29,3 @@ EOF export AWS_ENDPOINT_URL_S3=http://localhost:$port export AWS_REGION=does-not-matter -export AWS_S3_ENDPOINT=$AWS_ENDPOINT_URL_S3