location /firefox/ { rewrite ^/firefox/(.*) /$1 break; proxy_ignore_client_abort on; proxy_pass http://127.0.0.1:5800; proxy_redirect http://127.0.0.1:5800 /firefox; proxy_cookie_path / /firefox/; }