我有一个本地gitlab安装,在这两个文件中,production.log和sidekiq.log占用了太多空间。 只是想知道删除它们是否安全
答案 0 :(得分:1)
是的,但最好是:
gitlab/log
您还可以激活添加logrotate的 between 6.1 and 6.2 设置,以帮助管理这些日志的压缩和轮换。
# Add support for lograte for better log file handling
sudo apt-get install logrotate
最新的6.2 GitLab包括:
# GitLab logrotate settings
# based on: http://stackoverflow.com/a/4883967
/home/git/gitlab/log/*.log {
weekly
missingok
rotate 52
compress
delaycompress
notifempty
copytruncate
}
/home/git/gitlab-shell/gitlab-shell.log {
weekly
missingok
rotate 52
compress
delaycompress
notifempty
copytruncate
}