diff options
author | Robert Speicher <robert@gitlab.com> | 2016-04-14 17:15:58 +0000 |
---|---|---|
committer | Robert Speicher <robert@gitlab.com> | 2016-04-14 17:15:58 +0000 |
commit | 95a867e0af51370371cbe623b8851c2a3848f12f (patch) | |
tree | 9d933cf855b04f9a8f6a4f39292114165d0e1761 /config | |
parent | 58ca84908c89435ab0389523c769e39f1076113f (diff) | |
parent | cce21e7490d8684fb8fbaa6c9d5a8ce76c36d975 (diff) | |
download | gitlab-ce-95a867e0af51370371cbe623b8851c2a3848f12f.tar.gz |
Merge branch 'auto-fsck' into 'master'
Auto git fsck
Closes https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/3232
See merge request !3232
Diffstat (limited to 'config')
-rw-r--r-- | config/gitlab.yml.example | 7 | ||||
-rw-r--r-- | config/initializers/1_settings.rb | 7 | ||||
-rw-r--r-- | config/routes.rb | 2 |
3 files changed, 15 insertions, 1 deletions
diff --git a/config/gitlab.yml.example b/config/gitlab.yml.example index b28fc5c8e01..d9c15f81404 100644 --- a/config/gitlab.yml.example +++ b/config/gitlab.yml.example @@ -164,6 +164,13 @@ production: &base # Flag stuck CI builds as failed stuck_ci_builds_worker: cron: "0 0 * * *" + # Periodically run 'git fsck' on all repositories. If started more than + # once per hour you will have concurrent 'git fsck' jobs. + repository_check_worker: + cron: "20 * * * *" + # Send admin emails once a day + admin_email_worker: + cron: "0 0 * * *" # Remove outdated repository archives repository_archive_cache_worker: diff --git a/config/initializers/1_settings.rb b/config/initializers/1_settings.rb index 287f99c724d..10c25044b75 100644 --- a/config/initializers/1_settings.rb +++ b/config/initializers/1_settings.rb @@ -241,11 +241,16 @@ Settings['cron_jobs'] ||= Settingslogic.new({}) Settings.cron_jobs['stuck_ci_builds_worker'] ||= Settingslogic.new({}) Settings.cron_jobs['stuck_ci_builds_worker']['cron'] ||= '0 0 * * *' Settings.cron_jobs['stuck_ci_builds_worker']['job_class'] = 'StuckCiBuildsWorker' +Settings.cron_jobs['repository_check_worker'] ||= Settingslogic.new({}) +Settings.cron_jobs['repository_check_worker']['cron'] ||= '20 * * * *' +Settings.cron_jobs['repository_check_worker']['job_class'] = 'RepositoryCheck::BatchWorker' +Settings.cron_jobs['admin_email_worker'] ||= Settingslogic.new({}) +Settings.cron_jobs['admin_email_worker']['cron'] ||= '0 0 * * *' +Settings.cron_jobs['admin_email_worker']['job_class'] = 'AdminEmailWorker' Settings.cron_jobs['repository_archive_cache_worker'] ||= Settingslogic.new({}) Settings.cron_jobs['repository_archive_cache_worker']['cron'] ||= '0 * * * *' Settings.cron_jobs['repository_archive_cache_worker']['job_class'] = 'RepositoryArchiveCacheWorker' - # # GitLab Shell # diff --git a/config/routes.rb b/config/routes.rb index 688b83d2c95..408132f4217 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -264,6 +264,7 @@ Rails.application.routes.draw do member do put :transfer + post :repository_check end resources :runner_projects @@ -281,6 +282,7 @@ Rails.application.routes.draw do resource :application_settings, only: [:show, :update] do resources :services put :reset_runners_token + put :clear_repository_check_states end resources :labels |