nginx redirect old URL to new URL
Try to put rewrite ^/parent(.*) http://$server_name/new-parent$1 permanent;
into server
directive, not into /parent
location.
Try to put rewrite ^/parent(.*) http://$server_name/new-parent$1 permanent;
into server
directive, not into /parent
location.