Setup DVCS Force Sync as a Service

I have jira setup on a server inside our firewall and we are linking to several private github repos. Force sync works but nothing happens automatically. My guess is we don't have the jira server available from github and truthfully we don't really want it available from the outside.

So ideally I'd like to cron the running of the sync to happen periodically. My guess is I'd do this with a "service" and a jelly script.

Or if anyone has information on how to open up the jira server to callbacks from github securely. I'm kinda familiar with portforwarding and 1:1 nats but I don't know enough about jira or github to start locking these down.

edit: tcpdump shows the force sync hitting and there's a dns record for so perhaps portforwarding could be alittle more secure

4 answers

We have exactly the same situation and problem.

@Norman yes we are using DVCS version .26

Doing a force sync is probably not a good idea since it updates everything each time it runs. This could force Jira to be logically offline when the re-index is done.

I would have to guess you did not setup your private githubs with the service to push out changes as defined in the DVCS connector documentation.

So can you add code to your github or not? If you can, then I would try to use an ssh or https connection between Jira and your private githubs.

Another idea

Maybe you could also setup a shadow github for each your repositories behind your firewall. You can then install DVCS github service there. You can then create a small background script that just updates your shadow respository through cron every 5 to 10 minutes. I am hoping the DVCS connector github software would then see the update and push out the changes to the DVCS Jira Service.

Is the DVCS connector periodically polling Github for changes (aka jira initiates the connection) or is github trying to push changes back when specific hooks trigger to jira and the DVCS connector interprets commit messages (aka github initiating the connection)?

regarding the codeslower link, we've been able to use github just fine as our code repository, nothing is mucking with outbound ssh connections to github. Are you suggesting that having that open tunnel would allow the DVCS connector to open/receive connections from github?

re: another idea
WOuldn't I need to worry about the oauth stuff pointed at a regular git repo?

The github DVCS connector code pushes out changes on specific hook triggers to Jira and the github initiates the connection to Jira. It is not a polling mechanism as I understand it.

Yes, I was looking at the ssh connection(codeslower) as a way to initiate a connection from github back to Jira. That is required to take full advantage the DVCS connector plugin features. Yes, I was hoping an ssh tunnel from github to Jira may be allowed since it is secured. It would be similar to creating an ssh from your home to your offfice. It something you need to find out if that is possible.

The shadow github concept would have all the same setup issues as your local github. The only difference would be DVCS connector code would be installed behind your firewall. In this case, you be polling your remote github to bring in your changes which we already know works for you. The shadow github would only be used by Jira. The user's oauth used in this case could have restricted access since it only needs to be able update and read logs.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Nov 27, 2018 in Portfolio for Jira

Introducing a new planning experience in Portfolio for Jira (Server/DC)

In the past, Portfolio for Jira required a high degree of detail–foresight that was unrealistic for many businesses to   have–in   order to produce a reliable long-term roadmap. We're tur...

2,946 views 19 22
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you