- Newest
- Most votes
- Most comments
Hello.
Additionally, the "launch" need to be removed from the request so it routes correctly. so the request should go from this: Protocol://URL_OF_LOAD_BALANCER_/launch/createNewPost/* To the correct ECS instant without the user seeing the URL change. BUT I need this url to path to change to ../api/createNewPost/* - when it goes to the ECS because thats how the server work.
It is operationally possible to redirect the URL with ALB, but I don't think it is possible to prevent the user from seeing the URL change.
is this possible? and how do I do this with AWS?
How about introducing CloudFront before ALB and rewriting the URL with CloudFront Functions?
However, even with CloudFront Functions, I don't think it is possible to prevent users from seeing URL changes.
CloudFront Functions performs processing before requests are made to the ALB.
So, I thought it might be possible to achieve your requirements by rewriting the URL before the request reaches ECS.
https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/example-function-redirect-url.html
If I have a Application Load balance at the front and then route traffic to my ECS, will this actually allow for auto scaling by deploying more containers when the ALB is hitting heavily requested or am I missing more components?
As you know, ALB distributes the load to the running ECS containers.
To anyone who is looking for an answer to this problem, I unfortunately did not find a solution that is provided by AWS. However, I changed my server so it accepts the "/launch/" and "/marketplace/" prefixes so it functions well. This is the easiest option to simplify the aws implementation and reduce costs as introducing more services will only increase the cost.
Going to leave this post active for few days in case the AWS geniuses see it and help us out and help any wondering souls of the future.
Relevant content
- AWS OFFICIALUpdated 12 days ago
- AWS OFFICIALUpdated 2 months ago
Unfortunately that wouldn't be a solution as its still exposes the IP. After doing some digging, I found out that this can be a little difficult to implement and I might need to add additionally services to fix this issue.
So I decided to change my server functionality so it can accept the url with "/launch/" or "/marketplace" and all I have to do it is point it to the correct target. This way it saves me from adding more complicated services to this.
This is the easiest solution and fastest but I wanted to check experiment with AWS before going back to my code and solving it from there. Just trying improving my AWS skills!