0

I have an app hosted and deployed on AWS Amplify. I created a separate cloudfront distribution that has a lambda@edge function to detect certain user-agents (for rich social sharing).

In the "Rewrites and Redirects" section in Amplify App Settings, I added a rule for when a user hits a url path (/profile/<*>) as the source address, I would like it to redirect it to the target address which is the Cloudfront Distribution (https://<distributionId>.cloudfront.net/profile/<*>).

I confirmed that my lambda edge function is working, but when I test the URL it doesn't get redirected. I used a Redirect Checker for confirmation.

Is there something I'm missing to redirect the traffic? Or how can I even access the generated Cloudfront Distribution when the app gets deployed?

smcg
  • 135
  • 1
  • 8

0 Answers0