How to distribute Stash Git repositories to improve push/pull performance from different geo location?

The thing is we are a small team but from different physical locations: europe, asia, america etc.

Currently we setup our only Stash server in Hong Kong to compromise accessibility and network speed.

But sometime the push/pull performance is not so idea (only 10-50k/s while we have over 1Gb data to push).

I've checked out Stash Data Center solution but it seems not quite suitable for a tiny team like us.

So I'm wondering if it's possible to setup a simple distributed stash repositories to let our developer push/pull code from local server while the local servers will synchronise repository data with a single master server in Hong Kong.

(Stash management website access don't need to be distributed as it's not performance critical, so does the database which only need to store permissions / meta data if I'm right)

1 answer

1 accepted

5 votes
Answer accepted
Roger Barnes Atlassian Team Jun 14, 2015

This is something we'd like to help solve at some point. In the meantime, you can refer to this answer which has some suggestions:

In short, you can use a mirroring add-on to keep a remote copy up to date. Those users can set their fetch URL to the local mirror, and the push URL to point back to the central Stash server. 

Thanks a lot. This plugin seems very interesting: I'll investigate if it is suitable for my situation as we probably need bi-directional synchronisation instead of a readonly copy.

Roger Barnes Atlassian Team Jun 14, 2015

Are you really _pushing_ lots of data? If so I'd love to hear more about what you're using git for. It seems very strange to be pushing 1Gb (which your question hinted at), as no one writes that much code in one go ;)

Roger Barnes Atlassian Team Jun 14, 2015

If you're not pushing lots of data, you can have separate fetch and push URLs (fast local fetch for big clones, slow remote push for small pushes), which is what I'd recommend.

Pushing 1gb data is probably a rare case. Anyway, I'll try the plugin to see how it works. Thanks again.

Roger, what are the Stash licensing considerations if you deploy a second stash instance acting only as a mirror? Can that count as a "development" instance or does it require its own license?

Roger Barnes Atlassian Team Jul 21, 2015

Sorry I missed your question earlier. Currently you'd need a full license as it's considered a production instance also, but you could add fewer users to it.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Thursday in Bitbucket Pipelines

Building a Bitbucket Pipe as a casual coder :  #!/bin/bash source "$(dirname "$0")/" enable_debug extra_args="" if [[ "${DEBUG}" == "true" ]]; then extra_args="--verbose" fi # mandatory variables ROLLBAR_ACCESS_TOKEN...

190 views 0 12
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