there are several URLwww.example.com/abc/1.html
www.example.com/bdc/3.html
www.example.com/utf/2.html
in this form. You want to redirect to the corresponding
test.example.com/abc/1.html
test.example.com/bdc/3.html
test.example.com/utf/2.html
abc,bdc,utf are known to have a fixed number.
how should I write the rewrite of nginx directly without root mapping?
this is my way of writing:
location ^~/(abc|bdc|utf)/(*.html) {
rewrite ^~/*/(*.html) https://test.example.com/$! permanent;
}
is it wrong ~