Commit 13bba17fa4e49dc21ec956b94a0f141ed2d6f0a7
Exists in
master
and in
2 other branches
Merge branch 'backup_etc_gitlab' into 'master'
Add configuration backup/restore instructions See merge request !171
Showing
1 changed file
with
24 additions
and
0 deletions
Show diff stats
README.md
@@ -134,6 +134,30 @@ Note that you cannot use a Unicorn reload to update the Ruby runtime. | @@ -134,6 +134,30 @@ Note that you cannot use a Unicorn reload to update the Ruby runtime. | ||
134 | 134 | ||
135 | ## Configuration | 135 | ## Configuration |
136 | 136 | ||
137 | +### Backup and restore omnibus-gitlab configuration | ||
138 | + | ||
139 | +All configuration for omnibus-gitlab is stored in `/etc/gitlab`. To backup your | ||
140 | +configuration, just backup this directory. | ||
141 | + | ||
142 | +```shell | ||
143 | +# Example backup command for /etc/gitlab: | ||
144 | +# Create a time-stamped .tar file in the current directory. | ||
145 | +# The .tar file will be readable only to root. | ||
146 | +sudo sh -c 'umask 0077; tar -cf $(date "+etc-gitlab-%s.tar") -C / etc/gitlab' | ||
147 | +``` | ||
148 | + | ||
149 | +You can extract the .tar file as follows. | ||
150 | + | ||
151 | +```shell | ||
152 | +# Rename the existing /etc/gitlab, if any | ||
153 | +sudo mv /etc/gitlab /etc/gitlab.$(date +%s) | ||
154 | +# Change the example timestamp below for your configuration backup | ||
155 | +sudo tar -xf etc-gitlab-1399948539.tar -C / | ||
156 | +``` | ||
157 | + | ||
158 | +Remember to run `sudo gitlab-ctl reconfigure` after restoring a configuration | ||
159 | +backup. | ||
160 | + | ||
137 | ### Configuring the external URL for GitLab | 161 | ### Configuring the external URL for GitLab |
138 | 162 | ||
139 | In order for GitLab to display correct repository clone links to your users | 163 | In order for GitLab to display correct repository clone links to your users |