I am having a strange issue when approving gadgets between linked confluence and JIRA.
The TL:DR -
Oauth tokens at https://{baseurl}/plugins/servlet/oauth/users/access-tokens for jira and confluence are referencing old BaseURLs and cause linked gadgets to require repeated reauthorization.
The long version
So I have Jira and Confluence on One server. They are hosted on separate NICS and IP addresses, but still the same server.
When I first set it up, it was one NIC and one IP address just different hostnames, those hostnames are now DNS aliases that redirect to the new SSL versions of the base url.
Originally I did mod_proxy through apache. But now I just run each application on tomcat through SSL utilizing authbind to allow them to run on port 443.
I updated the base urls many moons ago. The original ones were
Confluence: http://arrowdoc
JIRA: http://arrowproject
There were a few other names and port variations along the way to get to the current
Confluence: https://kb.mydomain.com
JIRA: https://arrowJira.mydomain.com
The base URL health checks all check out and all that.
So now I'm wanting to play more with the gadgets for integrating jira and confluence together, especially for agile boards and sprint burndown reports in meeting notes.
I setup a subscription to each baseurl in the jira and confluence settings with the http link.
When I add a gadet to a dashboard or a gadget macro to a page I can look at the Urls before hitting the Login & Approve button and they are the correct URLS, so I login and approve and it does work, but it constantly requires re-approving on every refresh of the page. So I clicked the link on the login page to show current Oauth approvals. The urls to view that being
https://{baseurl}/plugins/servlet/oauth/users/access-tokens
That page on jira shows an access token referencing the baseURL on confluence of http://arrowdoc:8090 which was the original default baseurl from when I first installed it.
That page on confluence shows a token connecting to http://arrowhelpdesk:8888 which is a hostname that is an alias (via dns and a httpd/apache redirect) to go to the jira service desk, but that's on port 80, and it was never purposefully set to the Base URL. The 8888 port is a remnant of my transition to SSL when I tried to use two different ports on one ip address, but it didn't work as I wanted and I threw that idea out. So if that url ever was set to the baseURL in jira, it was for no more than maybe an hour.
I would also note that niether of those urls go anywhere anymore, both hostnames are dns aliases that will redirect to the proper base url when hit on port 80, but the ports the oauth tokens reference are not in use any more, which I figure is why the authentication doesn't stick.
I have tried deleting and recreating the application links. And I've gone through and removed any settings that contain the old urls in any way. I've also revoked all the oauth tokens and started fresh to no avail. I've also on occasion seen references to the old arrowproject base url, only its on https which the ssl cert does allow, so that url loads jira but with the wrong baseurl and therefore errors, I believe fixing that in the application manager links has fixed that, but it may be related to this issue. Any guidance would be greatly appreciated.
Thanks,
-JJ
p.s. In case it's need to be known they are running on a CentOS 7 server and all applications are the latest versions as of yesterday.
Confluence - 6.4.0
Jira - 7.5.0
Jira Software -7.5.0
Jira Service Desk - 3.8.1
Java - Oracle JDK 1.8.0.144