From 92d367880f47b48b48eec7dee0e7140a3b39c565 Mon Sep 17 00:00:00 2001 From: Simon Walker Date: Wed, 18 Dec 2024 22:10:54 +0000 Subject: [PATCH] ELB: add alternative URL structure (#1603) --- content/en/user-guide/aws/elb/index.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/content/en/user-guide/aws/elb/index.md b/content/en/user-guide/aws/elb/index.md index e8243b9664..b811c22e47 100644 --- a/content/en/user-guide/aws/elb/index.md +++ b/content/en/user-guide/aws/elb/index.md @@ -148,6 +148,27 @@ The following output will be retrieved: } ``` +#### Alternative URL structure + +If a request cannot be made to a subdomain of `localhost.localstack.cloud`, an alternative URL structure is available, however it is not returned by AWS management API methods. +To make a request against an ELB with id ``, use the URL: + +```bash +http(s)://localhost.localstack.cloud:4566/_aws/elb// +``` + +Here's an example of how you would access the load balancer with a name of `example-lb` with the subdomain-based URL format: + +```bash +http(s)://example-lb.elb.localhost.localstack.cloud:4566/test/path +``` + +With the alternative URL structure: + +```bash +http(s)://localhost.localstack.cloud:4566/_aws/elb/example-lb/test/path +``` + ## Examples The following code snippets and sample applications provide practical examples of how to use ELB in LocalStack for various use cases: