大网数据广告活动
服务器运维问答

How do I make GitLab delete old backups?

· 52CE 我爱测

I use the rake task to create backups for GitLab 6.8.2. gitlab-rake gitlab:backup:create In /etc/gitlab/gitlab.rb I added the following line: gitlab_rails['backup_keep_time'] = 60 This is supposed to prune backups older than 60 s…

问题原文

原帖链接 · Jan Deinhard · CC BY-SA 3.0

I use the rake task to create backups for GitLab 6.8.2.

gitlab-rake gitlab:backup:create

In /etc/gitlab/gitlab.rb I added the following line:

gitlab_rails['backup_keep_time'] = 60

This is supposed to prune backups older than 60 seconds. My expectation was that a second run of gitlab:backup:create would remove the first backup if 60 seconds have passed. Though the last line in the output is

Deleting old backups ... skipping

How do I configure GitLab to actually remove old backups?

社区高分解答

原帖链接 · Tad M. · CC BY-SA 4.0

The option you want is gitlab_rails['backup_keep_time']. I had to

gitlab-ctl reconfigure

after setting it for it to have any effect. Note that it will only affect local backups, not Amazon-AWS S3 if you're using that.

There was an issue with them being ignored, but I'm not sure what versions it affects. Version 6 is pretty old. If you're on the omnibus, it might be worth an upgrade.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2016-07-25)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0 / CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。