Problem with HTTP relative path after enabling proxy redirec

Need help? Post your questions here.

Moderator: moderators

Problem with HTTP relative path after enabling proxy redirec

Postby nickss » Sat May 10, 2014 1:31 pm

Hi,

I have Subsonic running on Debian on port 4040. But now I want to be able to listen to my music from work, so I have enabled proxy_http for Apache2,
then added the following to my virtual host running on port 80:


<Proxy http://127.0.0.1:8080>
Allow from all
</Proxy>
ProxyPreserveHost on
ProxyPass /subsonic/ http://127.0.0.1:4040/
ProxyPassReverse /subsonic/ http://127.0.0.1:4040/


I then restarted apache2 service and accessed my web page using http://127.0.0.1... Works well so far,
I then tested http://127.0.0.1/subsonic/ and it takes me to the Subsonic page, but a lot of images etc are broken.

I've identified it to be because Subsonic is not looking in the subfolder "subsonic" (http://127.0.0.1/subsonic), but directly under the root still.


Now, where does Subsonic store these settings? I need it to run under /subsonic/ directory.



Thanks!
nickss
 
Posts: 5
Joined: Sat May 10, 2014 1:26 pm

Re: Problem with HTTP relative path after enabling proxy red

Postby daily-freak » Tue May 13, 2014 9:24 am

Try switching ProxyPreserveHost to off. This solved my similar problem.

Good Luck!
daily-freak
 
Posts: 10
Joined: Mon May 12, 2014 10:03 am

Re: Problem with HTTP relative path after enabling proxy red

Postby nickss » Tue May 13, 2014 12:29 pm

Sorry but no difference.

This is a very annoying issue. Are there any other sources where one can get support for Subsonic? This forum is pretty dead.


Thanks.
nickss
 
Posts: 5
Joined: Sat May 10, 2014 1:26 pm

Re: Problem with HTTP relative path after enabling proxy red

Postby daily-freak » Tue May 13, 2014 1:00 pm

Yeah, seems like, but I know no other ressource. Maybe Stackoverflow?

But you may look at my config in this thread: viewtopic.php?f=2&t=14370

Maybe you find something helpful.

Greetings.
daily-freak
 
Posts: 10
Joined: Mon May 12, 2014 10:03 am

Re: Problem with HTTP relative path after enabling proxy red

Postby nickss » Tue May 13, 2014 1:47 pm

OK so I solved it!

Partially thanks to looking at your configuration thread!


What I saw was this particular line in the "subsonic.sh" file:
Code: Select all
SUBSONIC_CONTEXT_PATH=/subsonic


So I did a Google on it and found this thread:
viewtopic.php?f=6&t=1569&start=15

So, what I had to do was:

1. Change SUBSONIC_CONTEXT_PATH to:
Code: Select all
SUBSONIC_CONTEXT_PATH=/subsonic


2. Change my virtual host configuration for Apache2 host to:
Code: Select all
       <Proxy http://127.0.0.1:4040>
                Allow from all
        </Proxy>
        ProxyPreserveHost Off
        ProxyPass /subsonic/ http://127.0.0.1:4040/subsonic/
        ProxyPassReverse /subsonic/ http://127.0.0.1:4040/subsonic/


3. Restart subsonic and Apache



Thank you very much for pointing me in the right direction!
nickss
 
Posts: 5
Joined: Sat May 10, 2014 1:26 pm


Return to Help

Who is online

Users browsing this forum: No registered users and 24 guests