Apache proxy Follow
Youtrack is running as standalone app on port 8112.
I`m trying to create url that points to it using Apache Web Server.
The url is https://dev.site.com/youtrack. I`ve installed mod_proxy, mod_proxy_http and configured them like this:
ProxyRequests Off
ProxyPass /youtrack http://localhost:8112
ProxyPassReverse /youtrack http://localhost:8112
But when I`m trying to open https://dev.site.com/youtrack in my browser, I`m redirected to http://dev.site.com/rootGo with error 404.
Is there some way telling youtrack on what domain it`s running or how should I change my config to make it work?
Please sign in to leave a comment.
Are you using a rather standard Apache 2 setup with sites-available and sites-enabled?
In your /etc/apache2/sites-available/youtrack file you should have:
ProxyPass /YouTrack http://localhost:8080/YouTrack
That should do it really... Don't forget to link to /etc/apache2/sites-available/youtrack from /etc/apache2/sites-enabled/
Greeting,
Jeroen.
Yeah, I`ve already done all that.
Hello Paul,
Here's working config from Apache which is working perfectly for us:
NOTE: We're mapping ROOT uri of Apache to the ROOT uri of Youtrack. I'm not sure that it works with different uri between Apache and Youtrack.
Thanks,
Sergey
The root URI works for me, but I`d like to make it work in non-root URIs also.
I think it should work for same URIs, so if you deploy Youtrack under /youtrack uri, you can proxy it under Apache's /youtrack uri. But as I know it's possible only in WAR version of Youtrack, not standalone.
Maybe developers of Youtrack corrects me.
Thanks,
Sergey
I have the same problem but in my case even proxy / (ROOT) does not work. I use apache2 and have setup an SSL enabled virtual host.
In the host config I have:
ProxyPass / http://192.168.11.49:8112
ProxyPassReverse / http://192.168.11.49:8112
After calling the ssl enabled host with https://<ip-address-of-ssl-host> the browser wants to call http://<ip-address-of-ssl-host>/rootGo
I have found this: http://youtrack.jetbrains.net/issue/JT-3377
Does this solve the problem?
Thanks Roland
The way telling youtrack on what domain it`s running is "Base URL" in settings. Seems that you have to change your Base URL from http://dev.site.com/ to https://dev.site.com/youtrack
For future references, if you hit the same problem like me, put the rewrite directive as below
<VirtualHost *:80>
ServerName (virtualhost.example.com)
RewriteEngine on
RewriteRule ^(.+)$ https://(virtualhost.example.com)/$1 [L]
</VirtualHost>