location ~ ^/h5/search_v7/ { if ( $http_user_agent ~* "abc" ){ rewrite ^(.*) http://abcdef/h5/search_mi permanent; } }
我们需要将path为
h5/search_v7/替换为h5/search_mi,上面部署生效