Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
dac5188d
Commit
dac5188d
authored
Nov 12, 2017
by
digitalMoksha
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
make sure geo table exists before adding the cron jobs
parent
d01fa8d0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
lib/gitlab/geo.rb
lib/gitlab/geo.rb
+2
-2
lib/gitlab/mirror.rb
lib/gitlab/mirror.rb
+1
-1
No files found.
lib/gitlab/geo.rb
View file @
dac5188d
...
...
@@ -115,9 +115,9 @@ module Gitlab
end
def
self
.
configure_cron_jobs!
if
self
.
primary?
if
self
.
connected?
&&
self
.
primary?
self
.
configure_primary_jobs!
elsif
self
.
secondary?
elsif
self
.
connected?
&&
self
.
secondary?
self
.
configure_secondary_jobs!
else
self
.
enable_all_cron_jobs!
...
...
lib/gitlab/mirror.rb
View file @
dac5188d
...
...
@@ -18,7 +18,7 @@ module Gitlab
class
<<
self
def
configure_cron_job!
destroy_cron_job!
return
if
Gitlab
::
Geo
.
secondary?
return
if
Gitlab
::
Geo
.
connected?
&&
Gitlab
::
Geo
.
secondary?
Sidekiq
::
Cron
::
Job
.
create
(
name:
'update_all_mirrors_worker'
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment