I have a lambda function which performs 301 redirect if it has uri that is generated using regex. On deploying the function and adding it to the cloudfront behaviors, when I go to to the url https:my-website/xyz/faq/max, eventhough I see the status of 301 for https:my-website/xyz/faq/max after correctly re-routing to https:my-website/contact, it shows 502 Error. It shows the same error
Tag: amazon-cloudfront
Getting the client request domain from Lambda@Edge function
I’m trying do something like below for HTTP 301 redirect, so that web users will redirect to different news pages. However, seems like this request.origin.domainName == “mydomain.com” part is not working in my function. Is this correct way to pick the domain name which client coming from? I think this request.origin.domainName method will not work as Origin Object support only
Nginx is trying open file instead of redirect to proxy
Hi I am using Nginx together with njs and have such location in my config Inside of njs file I am making POST request to API In this request I am getting body response as formdata converting it to JSON and making POST request to 3rd party with following error. *63 open() “/usr/share/nginx/html//tc/api/endpoint/book” failed (2: No such file or directory)