File tree Expand file tree Collapse file tree 3 files changed +7
-4
lines changed
src/main/java/cloud/localstack Expand file tree Collapse file tree 3 files changed +7
-4
lines changed Original file line number Diff line number Diff line change 66public class Constants {
77 public static final Map <String , Integer > DEFAULT_PORTS = new HashMap <>();
88
9+ public static final String LOCALHOST_DOMAIN_NAME = "localhost.localstack.cloud" ;
10+
911 static {
1012 DEFAULT_PORTS .put ("apigateway" , 4567 );
1113 DEFAULT_PORTS .put ("kinesis" , 4568 );
Original file line number Diff line number Diff line change 11package cloud .localstack ;
22
3+ import cloud .localstack .Constants ;
34import cloud .localstack .ServiceName ;
45import cloud .localstack .docker .*;
56import cloud .localstack .docker .command .*;
@@ -110,12 +111,12 @@ private void loadServiceToPortMap() {
110111 public String getEndpointS3 () {
111112 String s3Endpoint = endpointForService (ServiceName .S3 );
112113 /*
113- * Use the domain name wildcard *.localhost.atlassian.io which maps to 127.0.0.1
114+ * Use the domain name wildcard *.localhost.localstack.cloud which maps to 127.0.0.1
114115 * We need to do this because S3 SDKs attempt to access a domain <bucket-name>.<service-host-name>
115116 * which by default would result in <bucket-name>.localhost, but that name cannot be resolved
116117 * (unless hardcoded in /etc/hosts)
117118 */
118- s3Endpoint = s3Endpoint .replace ("localhost" , "test.localhost.atlassian.io" );
119+ s3Endpoint = s3Endpoint .replace ("localhost" , Constants . LOCALHOST_DOMAIN_NAME );
119120 return s3Endpoint ;
120121 }
121122
Original file line number Diff line number Diff line change @@ -125,12 +125,12 @@ public static String getEndpointS3() {
125125 public static String getEndpointS3 (boolean overrideSSL ) {
126126 String s3Endpoint = ensureInstallationAndGetEndpoint (ServiceName .S3 , overrideSSL );
127127 /*
128- * Use the domain name wildcard *.localhost.atlassian.io which maps to 127.0.0.1
128+ * Use the domain name wildcard *.localhost.localstack.cloud which maps to 127.0.0.1
129129 * We need to do this because S3 SDKs attempt to access a domain <bucket-name>.<service-host-name>
130130 * which by default would result in <bucket-name>.localhost, but that name cannot be resolved
131131 * (unless hardcoded in /etc/hosts)
132132 */
133- s3Endpoint = s3Endpoint .replace ("localhost" , "test.localhost.atlassian.io" );
133+ s3Endpoint = s3Endpoint .replace ("localhost" , Constants . LOCALHOST_DOMAIN_NAME );
134134 return s3Endpoint ;
135135 }
136136
You can’t perform that action at this time.
0 commit comments