I am trying to migrate an GitLab setup from 7.8.2 to 7.12.2. I am not really sure how to go about this. I have installed a new box, on Ubuntu 14.04.2.
Now I would really like to just export the old user/group database and import it on the new server, then copy all the repositories from the old server to the new one. And tell the users to start using the new one.
I do not know which database my new gitlab installation uses, neither the old one.
I have been up and down the gitlab documentation, but cannot find sufficient information on how to migrate from one server to another.
I followed the instructions on https://about.gitlab.com/downloads/ for ubuntu, and all seems to work fine. I am looking for a way to export the users/groups from the old gitlab box and import it on the new gitlab box. and then just copy all the repositories from the old box to the new one.
Any assistance? I know next to nothing about gitlab :(
I would take the following steps
Find out if gitlab is installed by hand or with gitlab-omnibus. This you need to know for the exact backup and update steps.
Do a backup of the old version just to be safe
Update the current 7.8.2 instance to 7.12.2 instance by following the update guideline
Back up the newly updated gitlab system
Restore the backup on the new system
Backup & restore documentation can be found here
Related
I want to change theme in magento 2.The problem is that the client dont want the website to go down for 3 days so i have time to fix the new design and add clients images and information. If i build the site in subdomain how can i move it to root folder and after that connect the database of the old site without losing any data or do something wrong.
If you can suggest me something else i am all ears.
I didnt try something.I am new to magento so i cant figure out what to do
Thank you
I suggest you to setup git on your project.
Here is an explanation of how to setup git in an existing project
Add Magento Existing project to Github repository
When you are finished and the project is in a repo.
Clone the repo to your local environment, also take a database dump from the server and setup the project in the local environment.
And finally you can work and test your code independently without affecting production and when you have finished, with the help of git you can easily transfer to the production instance
I'm looking for a good way to export 100+ projects from one Gitlab repo on one server and import them into another existing Gitlab repo on another server. I need to be able to export/import:
projects
gitlab code (master and all branches and all prior commits)
tickets (and comments and previous status')
gitlab variables/secrets
Can someone please point me in the right direction?
As long as they are the same version of gitlab you can backup and restore using bundled rake tasks.
The details can be found here: https://gitlab.com/gitlab-org/gitlab-foss/-/blob/master/doc/raketasks/backup_restore.md
The backup will produce a tarball you can move from the initial server to the target and then restore.
I am using ubuntu server running gitlab server.
I need to perform daily backup/restore of my gitlab.
Which method should I prefer: omnibus or from source?
How can I check weather GitLab is installed via omnibus or from source?
Source or Omnibus, you will have access to the same backup procedure, which will create an archive file that contains the database, all repositories and all attachments.
That means you are saving the data itself, not the all system.
For the system, note the version of the omnibus package you are installing, and you will be able to re-install it in minutes.
How can I check weather GitLab is installed via omnibus or from source?
See if your gitlab root folder has a .git in it: that would mean it represents a clone from the sources.
I have successfully installed older versions of gitlab and hosted them at a location like this:
mydomain/gitlab
with the new version of gitlab doing all of the config though the gitlab-ctl and via me editing the /etc/gitlab/gitlab.rb I'm not sure how to achieve this set-up.
I find lots of documentation on stackexchange for older versions of gitlab that did not use gitlab-ctl for configuration but not for the new version. Presently I have gitlab installed and running fine at:
mydomain
I want to move it to:
mydomain/gitlab
Anybody know how to do this for version 7.4.3?
Thanks :)
Serving from a relative URL root seems to be simply not implemented on Omnibus GitLab: https://gitlab.com/gitlab-org/omnibus-gitlab/blob/ed51ec97401bba955c93e61f8ef860520f745837/files/gitlab-cookbooks/gitlab/templates/default/gitlab.yml.erb#L24 (since no template variable is inserted there)
You could work around that by modifying all the required configuration files manually as explained in the comment on gitlab.yml, but that would really be a lot of manual work and those configs would get overwritten if you reconfigure, so I recommend you request the feature at: http://feedback.gitlab.com/forums/176466-general and send a pull request implementing that.
This problem was also raised at: Omnibus GitLab on IP without a domain-name and with custom relative_url_root
I ran across this same issue this week and set out to find a solution. I'm not all that familiar with RoR so I ended up creating a Bash script to automate the process instead.
Now it'd be a lot nicer if we could just automate all this through /etc/gitlab/gitlab.rb and hopefully somebody sets that up at some point (maybe someone has that I just can't find?), but in the meantime feel free to use this script as needed. Run as root on a system with a GitLab Omnibus-package installation. Tested on GitLab CE 7.9.0 with Bash 4.2.
GitLab Relative URL Setter
I have some projects set up on GitLab Cloud, complete with issues, wiki pages, etc. I've recently set up an internally hosted gitlab instance. I'd like to bring these projects over from GitLab Cloud to the internal GitLab instance.
Bringing over the git repos seems easy enough (change the remote and push), but I don't see how to bring over the wikis and issues.
In general it seems like this isn't possible. (There's a GitLab Feedback for it here.)
However, the project wiki's seem to be their own git repos, which you can see on the Git Access tab. While that doesn't solve issues/snippets, it gets you part of the way there.
I don't know how to transfer over issues as I have not had to do that yet, but passing over the wiki is not that difficult.
On your old gitlab instance you will notice two repositories for your project (let's pretend your wiki is oldproject), one will say something like oldproject.git and oldproject.wiki.git.
The general path to the repositories where you can see the names I am talking about (let's assume user-name is "myaccount") can be found here:
/home/git/repositories/myaccount/
or (if using the omnibus installer):
/var/opt/gitlab/git-data/repositories/myaccount/
I presume you already know how to transfer over oldproject.git. You do the exact same thing with the wiki, only you create a bundle file out of oldproject.wiki.git:
git clone http://gitlab-instance-ip/user-name/oldproject.wiki.git
cd oldproject.wiki
git bundle create oldproject-wiki.bundle --all
Now initialize your new project in gitlab...I presume you already know how to do that as you suggested in your question that you know how to import the files from your project over to the new instance without problem. Now repeat for the wiki:
git clone http://new-gitlab-ip/user-name/newproject.wiki.git
cd newproject.wiki
git pull /path/to/oldproject-wiki.bundle
git push -u origin master
I had a very similar problem to yours where I didn't see that anything was actually "pushed". When I went back to the gitlab project I noticed that it was in fact updated with the wiki. See here if you think it will help: Importing Gitlab Wiki to a new Gitlab Instance
Good luck!