From f59a6d8ee675607b6a2e31715c137915174260eb Mon Sep 17 00:00:00 2001 From: Jacob Vosmaer Date: Fri, 25 Jul 2014 10:46:44 +0200 Subject: [PATCH] Add configuration backup/restore instructions --- README.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+), 0 deletions(-) diff --git a/README.md b/README.md index 003323b..aae5a4f 100644 --- a/README.md +++ b/README.md @@ -134,6 +134,30 @@ Note that you cannot use a Unicorn reload to update the Ruby runtime. ## Configuration +### Backup and restore omnibus-gitlab configuration + +All configuration for omnibus-gitlab is stored in `/etc/gitlab`. To backup your +configuration, just backup this directory. + +```shell +# Example backup command for /etc/gitlab: +# Create a time-stamped .tar file in the current directory. +# The .tar file will be readable only to root. +sudo sh -c 'umask 0077; tar -cf $(date "+etc-gitlab-%s.tar") -C / etc/gitlab' +``` + +You can extract the .tar file as follows. + +```shell +# Rename the existing /etc/gitlab, if any +sudo mv /etc/gitlab /etc/gitlab.$(date +%s) +# Change the example timestamp below for your configuration backup +sudo tar -xf etc-gitlab-1399948539.tar -C / +``` + +Remember to run `sudo gitlab-ctl reconfigure` after restoring a configuration +backup. + ### Configuring the external URL for GitLab In order for GitLab to display correct repository clone links to your users -- libgit2 0.21.2