aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/github.com/minio/minio-go/v7/s3-endpoints.go
diff options
context:
space:
mode:
authorLibravatar Rutger Broekhoff2024-01-02 18:56:31 +0100
committerLibravatar Rutger Broekhoff2024-01-02 18:56:31 +0100
commit8db41da676ac8368ef7c2549d56239a5ff5eedde (patch)
tree09c427fd66de2ec1ebffc8342f5fdbb84b0701b5 /vendor/github.com/minio/minio-go/v7/s3-endpoints.go
parentd4f75fb6db22e57577867445a022227e70958931 (diff)
downloadgitolfs3-8db41da676ac8368ef7c2549d56239a5ff5eedde.tar.gz
gitolfs3-8db41da676ac8368ef7c2549d56239a5ff5eedde.zip
Delete vendor directory
Diffstat (limited to 'vendor/github.com/minio/minio-go/v7/s3-endpoints.go')
-rw-r--r--vendor/github.com/minio/minio-go/v7/s3-endpoints.go64
1 files changed, 0 insertions, 64 deletions
diff --git a/vendor/github.com/minio/minio-go/v7/s3-endpoints.go b/vendor/github.com/minio/minio-go/v7/s3-endpoints.go
deleted file mode 100644
index b1de7b6..0000000
--- a/vendor/github.com/minio/minio-go/v7/s3-endpoints.go
+++ /dev/null
@@ -1,64 +0,0 @@
1/*
2 * MinIO Go Library for Amazon S3 Compatible Cloud Storage
3 * Copyright 2015-2017 MinIO, Inc.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17
18package minio
19
20// awsS3EndpointMap Amazon S3 endpoint map.
21var awsS3EndpointMap = map[string]string{
22 "us-east-1": "s3.dualstack.us-east-1.amazonaws.com",
23 "us-east-2": "s3.dualstack.us-east-2.amazonaws.com",
24 "us-west-2": "s3.dualstack.us-west-2.amazonaws.com",
25 "us-west-1": "s3.dualstack.us-west-1.amazonaws.com",
26 "ca-central-1": "s3.dualstack.ca-central-1.amazonaws.com",
27 "eu-west-1": "s3.dualstack.eu-west-1.amazonaws.com",
28 "eu-west-2": "s3.dualstack.eu-west-2.amazonaws.com",
29 "eu-west-3": "s3.dualstack.eu-west-3.amazonaws.com",
30 "eu-central-1": "s3.dualstack.eu-central-1.amazonaws.com",
31 "eu-central-2": "s3.dualstack.eu-central-2.amazonaws.com",
32 "eu-north-1": "s3.dualstack.eu-north-1.amazonaws.com",
33 "eu-south-1": "s3.dualstack.eu-south-1.amazonaws.com",
34 "eu-south-2": "s3.dualstack.eu-south-2.amazonaws.com",
35 "ap-east-1": "s3.dualstack.ap-east-1.amazonaws.com",
36 "ap-south-1": "s3.dualstack.ap-south-1.amazonaws.com",
37 "ap-south-2": "s3.dualstack.ap-south-2.amazonaws.com",
38 "ap-southeast-1": "s3.dualstack.ap-southeast-1.amazonaws.com",
39 "ap-southeast-2": "s3.dualstack.ap-southeast-2.amazonaws.com",
40 "ap-northeast-1": "s3.dualstack.ap-northeast-1.amazonaws.com",
41 "ap-northeast-2": "s3.dualstack.ap-northeast-2.amazonaws.com",
42 "ap-northeast-3": "s3.dualstack.ap-northeast-3.amazonaws.com",
43 "af-south-1": "s3.dualstack.af-south-1.amazonaws.com",
44 "me-central-1": "s3.dualstack.me-central-1.amazonaws.com",
45 "me-south-1": "s3.dualstack.me-south-1.amazonaws.com",
46 "sa-east-1": "s3.dualstack.sa-east-1.amazonaws.com",
47 "us-gov-west-1": "s3.dualstack.us-gov-west-1.amazonaws.com",
48 "us-gov-east-1": "s3.dualstack.us-gov-east-1.amazonaws.com",
49 "cn-north-1": "s3.dualstack.cn-north-1.amazonaws.com.cn",
50 "cn-northwest-1": "s3.dualstack.cn-northwest-1.amazonaws.com.cn",
51 "ap-southeast-3": "s3.dualstack.ap-southeast-3.amazonaws.com",
52 "ap-southeast-4": "s3.dualstack.ap-southeast-4.amazonaws.com",
53 "il-central-1": "s3.dualstack.il-central-1.amazonaws.com",
54}
55
56// getS3Endpoint get Amazon S3 endpoint based on the bucket location.
57func getS3Endpoint(bucketLocation string) (s3Endpoint string) {
58 s3Endpoint, ok := awsS3EndpointMap[bucketLocation]
59 if !ok {
60 // Default to 's3.dualstack.us-east-1.amazonaws.com' endpoint.
61 s3Endpoint = "s3.dualstack.us-east-1.amazonaws.com"
62 }
63 return s3Endpoint
64}