2016-06-24 12:29:23 -04:00
|
|
|
desc 'Checks if migrations in a branch require downtime'
|
|
|
|
task downtime_check: :environment do
|
2016-08-02 05:56:47 -04:00
|
|
|
if defined?(Gitlab::License)
|
|
|
|
repo = 'gitlab-ee'
|
2016-06-24 12:29:23 -04:00
|
|
|
else
|
2016-08-02 05:56:47 -04:00
|
|
|
repo = 'gitlab-ce'
|
2016-06-24 12:29:23 -04:00
|
|
|
end
|
|
|
|
|
2016-08-02 05:56:47 -04:00
|
|
|
`git fetch https://gitlab.com/gitlab-org/#{repo}.git --depth 1`
|
|
|
|
|
|
|
|
Rake::Task['gitlab:db:downtime_check'].invoke('FETCH_HEAD')
|
2016-06-24 12:29:23 -04:00
|
|
|
end
|