How to configure Umbrel BTCPay Server with NGINX reverse proxy

Hi Tobi,

My guide contains configuration to circumvent that. You should instruct NGINX to return Connection: upgrade on some occasions to make the websocket work. See the manual for more information but it comes down to including this part somewhere in your NGINX config;

proxy_buffer_size          128k;
proxy_buffers              4 256k;
proxy_busy_buffers_size    256k;
client_header_buffer_size 500k;
large_client_header_buffers 4 500k;
http2_max_field_size       500k;
http2_max_header_size      500k;

map $http_upgrade $connection_upgrade {
    default upgrade;
    ''      close;
}

Then, in the vhost, include these lines:

        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection $connection_upgrade;

Source: https://docs.btcpayserver.org/FAQ/FAQ-Deployment/#can-i-use-an-existing-nginx-server-as-a-reverse-proxy-with-ssl-termination

Let me know if this worked :slight_smile:

Jorijn

2 Likes