Securing youtrack with SSL at mydomain/youtrack

So I found the online documentation suggesting to either modify the internal webserver, or using mod_proxy with Apache, and I have the mod_proxy working on a unique port. So I can go to and have it proxied to the youtrack server. That works fine. But what I want to do is to go to When I implement the same functionality on port 443 (no other servers running on this port yet), like this:

ProxyRequests Off
ProxyPass / ws://

            Alias /youtrack /opt/youtrack
            <Location /youtrack>
                    Header edit Location ^http: https:


                    RequestHeader set X-Forwarded-Proto "https"

It doesn't work. I end up at

The proxy seems to be failing to modify the url correctly. I have also tried
ProxyPass /youtrack/
ProxyPassReverse /youtrack/


  ProxyPass /youtrack/
  ProxyPassReverse /youtrack/

The first one does the same as the original. I end up at rootGo, the second tries to go to the /youtrack/ path on the youtrack server, which gives me a page not found error. It really should be possible to set this up. I need multiple ssl sites on this machine, and would really like to be able to go to mydomain/path for each of them.

Can anyone shed some light on this?

I'm running Ubuntu 14.04, Apache 2.4.7, and Youtrack 6.5

1 comment

Of course I have been looking at this for 24 hours or more now and as soon as I post the question I find the answer.

It seems bizarre to me that you can't proxy from /youtrack to /domain:###/ successfully. I just knew there had to be a way.

In the end though, I had seen where someone modified the web root of youtrack, though it took me time to find it. In linux, I modified the base-url field in youtrack-home/conf/internal/ I changed it from http://mydomain:port/ to http://mydomain:port/youtrack

Then the proxy pass worked correctly.


Please sign in to leave a comment.