mirror of
https://gitea.com/mcereda/oam.git
synced 2026-02-09 05:44:23 +00:00
fix(gitlab): complete set of commands for restore
This commit is contained in:
@@ -138,8 +138,20 @@ sudo gitlab-backup create … \
|
|||||||
SKIP='db,repositories,uploads,builds,artifacts,pages,lfs,terraform_state,registry,packages,ci_secure_files'
|
SKIP='db,repositories,uploads,builds,artifacts,pages,lfs,terraform_state,registry,packages,ci_secure_files'
|
||||||
|
|
||||||
# Restore backups.
|
# Restore backups.
|
||||||
sudo gitlab-ctl stop 'puma' \
|
sudo aws s3 cp 's3://backups/gitlab/gitlab-secrets.json' '/etc/gitlab/gitlab-secrets.json' \
|
||||||
&& sudo gitlab-ctl stop 'sidekiq'
|
&& sudo aws s3 cp 's3://backups/gitlab/gitlab.rb' '/etc/gitlab/gitlab.rb' \
|
||||||
|
&& sudo aws s3 cp \
|
||||||
|
's3://backups/gitlab/11493107454_2018_04_25_10.6.4-ce_gitlab_backup.tar' \
|
||||||
|
'/var/opt/gitlab/backups/' \
|
||||||
|
&& sudo gitlab-ctl stop 'puma' \
|
||||||
|
&& sudo gitlab-ctl stop 'sidekiq' \
|
||||||
|
&& sudo GITLAB_ASSUME_YES=1 gitlab-backup restore BACKUP='11493107454_2018_04_25_10.6.4-ce' \
|
||||||
|
&& sudo gitlab-ctl restart \
|
||||||
|
&& sudo gitlab-rake 'gitlab:check' SANITIZE=true \
|
||||||
|
&& sudo gitlab-rake 'gitlab:doctor:secrets' \
|
||||||
|
&& sudo gitlab-rake 'gitlab:artifacts:check' \
|
||||||
|
&& sudo gitlab-rake 'gitlab:lfs:check' \
|
||||||
|
&& sudo gitlab-rake 'gitlab:uploads:check'
|
||||||
|
|
||||||
# Upgrade the package.
|
# Upgrade the package.
|
||||||
sudo yum check-update
|
sudo yum check-update
|
||||||
|
|||||||
@@ -126,8 +126,13 @@ sudo aws s3 cp \
|
|||||||
'/var/opt/gitlab/backups/'
|
'/var/opt/gitlab/backups/'
|
||||||
sudo gitlab-ctl stop 'puma'
|
sudo gitlab-ctl stop 'puma'
|
||||||
sudo gitlab-ctl stop 'sidekiq'
|
sudo gitlab-ctl stop 'sidekiq'
|
||||||
sudo gitlab-backup restore BACKUP='11493107454_2018_04_25_10.6.4-ce'
|
sudo GITLAB_ASSUME_YES=1 gitlab-backup restore BACKUP='11493107454_2018_04_25_10.6.4-ce'
|
||||||
sudo gitlab-ctl start
|
sudo gitlab-ctl restart
|
||||||
|
sudo gitlab-rake 'gitlab:check' SANITIZE=true
|
||||||
|
sudo gitlab-rake 'gitlab:doctor:secrets'
|
||||||
|
sudo gitlab-rake 'gitlab:artifacts:check'
|
||||||
|
sudo gitlab-rake 'gitlab:lfs:check'
|
||||||
|
sudo gitlab-rake 'gitlab:uploads:check'
|
||||||
|
|
||||||
## Restore backups - end ------------- #
|
## Restore backups - end ------------- #
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user