[ 
https://issues.jenkins-ci.org/browse/JENKINS-12730?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=159446#comment-159446
 ] 

Mandeep Rai commented on JENKINS-12730:
---------------------------------------

Reading the Javadoc, it seems like getRootUrlFromRequest ignores the manually 
configured public url, which is why it would redirect from the nice configured 
url (ie: http://builds.mydomain.com/builds) to the proxy'd address instead (ie: 
http://builds-pc-1249:8001/builds)

May I suggest to using getRootUrl() instead, which does use the configured url, 
instead of trying to glean it from the request, which may pass through a proxy 
server?
                
> Going to pages via global shortcuts doesn't use the current url/url set in 
> config
> ---------------------------------------------------------------------------------
>
>                 Key: JENKINS-12730
>                 URL: https://issues.jenkins-ci.org/browse/JENKINS-12730
>             Project: Jenkins
>          Issue Type: Bug
>          Components: keyboard-shortcuts
>    Affects Versions: current
>            Reporter: Mandeep Rai
>            Assignee: jieryn
>
> I have my jenkins running on port 8001 (ie: http://builds:8001) using a 
> prefix of "builds" (ie: http://builds:8001/builds).
> I also have an Apache instance that is forwarding from port 80 to jenkins 
> (ie: http://builds.mydomain.com/builds).
> In the jenkins main config, I have the "Jenkins URL" in the system config set 
> to the proper apache forwarded address (ie: 
> http://builds.mydomain.com/builds), as is the JENKINS_URL.
> If I use the keyboard shortcut to go to a job, instead of 
> http://builds.mydomain.com/builds/job/<job>, it goes to 
> http://builds:8001/builds/job/<job>, and as a result of the url change, I am 
> no longer logged in, unless I manually change the host in the location bar 
> from builds:8001 to builds.mydomain.com

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.jenkins-ci.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to