Mirror repositories in Gitolite

I have my repositories in Gitolite and I want to keep them there. So I tried using the Mirror Hook in Stash, unsuccessfully. 

This is the URL: ssh://git@git.company.com/packages/myApp.git

I have no problem performing a git clone on this URL with the atlstash user on the command line. So the stash user has access both via SSH and to Gitolite, but nothing happens in Stash. I have even tried restarting Stash, and it still says "You have an empty repository".

Using Atlassian Stash 3.6.1

1 answer

I have tried cheating a bit: Created a Stash project as my own user. Created that user in Linux. Added my SSH keys from the same user Gitolite knows under myuser/.ssh/. I performed a git clone --mirror ssh://git@git.company.com/packages/myApp.git under ssh://git@git.company.com/packages/myApp.git. Removed the stash numbered repository and renamed myApp to that. Restarted Stash, and the repo is now visible. This procedure would be to much work for all repositories.

Suggest an answer

Log in or Join to answer
Community showcase
Piotr Plewa
Published Dec 27, 2017 in Bitbucket

Recipe: Deploying AWS Lambda functions with Bitbucket Pipelines

Bitbucket Pipelines helps me manage and automate a number of serverless deployments to AWS Lambda and this is how I do it. I'm building Node.js Lambda functions using node-lambda&nbsp...

658 views 0 4
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
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot