Page 1 of 1

reverse proxy url redirect not working

Posted: 06 May 2017, 21:57
by mad1993max
I cant get madsonic to stop redirecting me to the ip address of the madsonic instance if i use a reverse proxy. I specified my domain name in Netowrk settings but it doesnt work.

If i type the url for the reverse proxy i get to the madsonic instance, but it redirects me to the ip of the madsonic:
name.domain.com --> (madonic) --> 192.168.0.122:4040

but the IP address is only accessible from the local network, so it makes no sense for the masonic server to rewrite the URL to the IP

Re: reverse proxy url redirect not working

Posted: 09 May 2017, 10:13
by mad1993max
anyone? this is really bad, because i can't use the web ui because of this

Re: reverse proxy url redirect not working

Posted: 19 May 2017, 07:33
by ripley
I had the same issue. Below is my MadSonic config snippet from nginx. I had to add the proxy_redirect bit to make it work correctly.

Code: Select all

server {
        listen 443 ssl;
        listen [::]:443 ssl;
        server_name music.mydomain.org;
        include snippets/ssl-mydomain.org.conf;
        ssl_dhparam /etc/ssl/certs/dhparam.pem;
        location / {
                proxy_pass http://madsonic.localdomain.local:4040;
                proxy_redirect https://madsonic.localdomain.local:4040/ https://music.mydomain.org/;
        }
}

Re: reverse proxy url redirect not working

Posted: 20 May 2017, 14:10
by mad1993max
that is not an option for me, beacause i use a reverse proxy built into my firewall, where i cant edit the proxy parameters.

there mus be an option for madsonic to not rewrite the url to the localhost ip