Commit be493bea11ea017ae6d60007892fa1d6d0c563e5

Authored by Job van der Voort
1 parent 4df3782d

daily backup in readme

Showing 1 changed file with 15 additions and 0 deletions   Show diff stats
@@ -86,6 +86,21 @@ sudo gitlab-rake gitlab:backup:create @@ -86,6 +86,21 @@ sudo gitlab-rake gitlab:backup:create
86 This will store a tar file in `/var/opt/gitlab/backups`. The filename will look like 86 This will store a tar file in `/var/opt/gitlab/backups`. The filename will look like
87 `1393513186_gitlab_backup.tar`, where 1393513186 is a timestamp. 87 `1393513186_gitlab_backup.tar`, where 1393513186 is a timestamp.
88 88
  89 +### Scheduling a backup
  90 +
  91 +To schedule a cron job that backs up your repositories and GitLab metadata, use the root user:
  92 +
  93 +```
  94 +sudo su -
  95 +crontab -e
  96 +```
  97 +
  98 +There, add the following line to schedule the backup for everyday at 2 AM:
  99 +
  100 +```
  101 +0 2 * * * gitlab-rake gitlab:backup:create
  102 +```
  103 +
89 ### Restoring an application backup 104 ### Restoring an application backup
90 105
91 We will assume that you have installed GitLab from an omnibus package and run 106 We will assume that you have installed GitLab from an omnibus package and run