21
1
Fork 0
mirror of https://github.com/Evolix/chexpire.git synced 2024-05-03 17:25:09 +02:00

Upgrade Task for setting manual mode for domain non supported

This commit is contained in:
Colin Darie 2018-08-29 17:42:27 +02:00
parent 3cbf0e2656
commit 6ccddc6afc
No known key found for this signature in database
GPG key ID: 4FB865FDBCA4BCC4

14
lib/tasks/one_shot.rake Normal file
View file

@ -0,0 +1,14 @@
namespace :one_shot do
desc "Set manual mode for unsupported checks"
task reset_checks_modes: :environment do
Check.domain.find_each do |check|
check.mode = if check.supported?
:auto
else
:manual
end
check.save(validate: false)
end
end
end