AWS Load Balancer Rules: Forward path with query parameters to Target Group

Viewed 45

I'm using CloudFront and ALB to forward a path from my main domain to a target group with a registered instance. Everything is working fine, but I need to forward query parameters in the URL.

Right now https://mymaindomain.com/my_registered_rule/ is correctly being forwarded to the corresponding container

But when doing https://mymaindomain.com/my_registered_rule/?query=1234 The query is ignored.

Is there any way around this?

this is how I'm doing the forwarding: enter image description here

1 Answers

The problem wasn't at the Load Balancer level but on the cloudfront distribution behavior cache side. I had to enable the queries on the legacy cache setting like this:

enter image description here

Related