Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation for enabling/configuring backups #325

Open
cmseal opened this issue Sep 25, 2019 · 2 comments
Open

Documentation for enabling/configuring backups #325

cmseal opened this issue Sep 25, 2019 · 2 comments

Comments

@cmseal
Copy link

cmseal commented Sep 25, 2019

Would it be possible to add to the documentation examples for enabling/configuring backups?

Thanks! :)

@LongLiveCHIEF
Copy link
Contributor

Yeah, now that Gitlab has more functionality built into the backup command, we should probably document exactly what the cron support we have does, and does not do.

@anarcat
Copy link

anarcat commented Jan 11, 2021

in particular, i have found it does not backup the configuration which seems.... problematic, at best. we do this instead:

  file { '/usr/local/sbin/tpo-gitlab-backup':
    mode    => '0555',
    content => @(EOF),
      #!/bin/sh
      set -e
      
      umask 0077
      
      /usr/bin/gitlab-rake gitlab:backup:create CRON=1
      
      NOW=$(date +"%Y%m%dT%H%M")
      SNAPSHOT="/srv/gitlab-backup/config_backup-$NOW.tar.gz"
      tar -C /var/opt/gitlab -czf "$SNAPSHOT" gitlab-rails/etc/
      
      find /srv/gitlab-backup/config_backup* -mtime +1 -delete;
      | EOF
  }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants