How to grab a value from a request

halfpastjohn nginx-forum at forum.nginx.org
Tue Oct 3 17:41:06 UTC 2017


Would this work?

location ~ ^/users/v2/ {
proxy_pass http://app.domain.com/api/$1/v2;
}

Would $1 resolve as users or does it need to be inside ()?

Posted at Nginx Forum: https://forum.nginx.org/read.php?2,276652,276664#msg-276664



More information about the nginx mailing list