Difference between revisions of "Process for moving repos to Bitbucket Server"

From GLMWiki
Jump to: navigation, search
(Created page with "== Create a new repo in Bitbucket Server == Goto the GlmAssociate project on https://bitbucket.gaslightmedia.com:8443 and add a new Repo. Clone the current repo with --bare f...")
 
(Create a new repo in Bitbucket Server)
Line 19: Line 19:
 
goto the home directory and use
 
goto the home directory and use
 
  gitolite writable (old-repo) off
 
  gitolite writable (old-repo) off
 +
 +
You'll need to update all remote url's for each website we have installed the old-repo on.
 +
I have a set of scripts that can do this.

Revision as of 11:39, 29 October 2019

Create a new repo in Bitbucket Server

Goto the GlmAssociate project on https://bitbucket.gaslightmedia.com:8443 and add a new Repo.

Clone the current repo with --bare flag

git clone --bare {old repo url}

Grab the clone url (ssh)

Add remote (bitbucket)

cd (old repo)
git remote add bitbucket (ssh url for bitbucket repo)
git push --all bitbucket
git push --tags bitbucket

Update your remote url for (origin)

git remote set-url origin (ssh url for bitbucket repo)

Block any new pushes to gitolite repo. Goto the cvs2 and change to the git user. goto the home directory and use

gitolite writable (old-repo) off

You'll need to update all remote url's for each website we have installed the old-repo on. I have a set of scripts that can do this.