For some time now I’ve been using reverse proxy for all my web applications, the only one that wasn’t playing ball was HomeAssistant, it just simply wouldn’t let me login. Now the below has fixed the issue!
Configuration fix for Synology DSM 6 reverse proxy to handle websocket
portal.mustache BEFORE MODIFYING IT!
You need to edit the file
/usr/syno/share/nginx/Portal.mustache to add the followings in the
proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; proxy_read_timeout 86400;
Then restart the httpd with:
sudo synoservicecfg --restart nginx
This will restart ALL http service running, not only reverse proxy, as a single instance of NGinX runs everything.
Portal.mustache is provided in this repo (warning: based on DSM 6.1.6-15266).