9951 explained code solutions for 126 technologies


nginxUsing proxy_redirect


server {
  location /new/ {
    proxy_pass http://localhost:81/old/;
    proxy_redirect http://localhost:81/old/ /new/;
  }
}ctrl + c
server {

virtual server configuration block

http://localhost:81/old/

sample backend to use to proxy

/new/

replace Location header from proxy backend by this URI (will use same server name and port)