mirror of
https://github.com/Evolix/chexpire.git
synced 2024-06-25 18:42:53 +02:00
Add a logger to check processors
Currently it is unused.
This commit is contained in:
parent
815471da76
commit
5326dcc7aa
2
Gemfile
2
Gemfile
|
@ -48,6 +48,8 @@ gem 'octicons'
|
||||||
gem 'kaminari'
|
gem 'kaminari'
|
||||||
gem 'has_scope'
|
gem 'has_scope'
|
||||||
|
|
||||||
|
gem 'logging'
|
||||||
|
|
||||||
# Reduces boot times through caching; required in config/boot.rb
|
# Reduces boot times through caching; required in config/boot.rb
|
||||||
gem 'bootsnap', '>= 1.1.0', require: false
|
gem 'bootsnap', '>= 1.1.0', require: false
|
||||||
|
|
||||||
|
|
|
@ -166,6 +166,10 @@ GEM
|
||||||
rb-fsevent (~> 0.9, >= 0.9.4)
|
rb-fsevent (~> 0.9, >= 0.9.4)
|
||||||
rb-inotify (~> 0.9, >= 0.9.7)
|
rb-inotify (~> 0.9, >= 0.9.7)
|
||||||
ruby_dep (~> 1.2)
|
ruby_dep (~> 1.2)
|
||||||
|
little-plugger (1.1.4)
|
||||||
|
logging (2.2.2)
|
||||||
|
little-plugger (~> 1.1)
|
||||||
|
multi_json (~> 1.10)
|
||||||
loofah (2.2.2)
|
loofah (2.2.2)
|
||||||
crass (~> 1.0.2)
|
crass (~> 1.0.2)
|
||||||
nokogiri (>= 1.5.9)
|
nokogiri (>= 1.5.9)
|
||||||
|
@ -363,6 +367,7 @@ DEPENDENCIES
|
||||||
launchy
|
launchy
|
||||||
letter_opener_web
|
letter_opener_web
|
||||||
listen (>= 3.0.5, < 3.2)
|
listen (>= 3.0.5, < 3.2)
|
||||||
|
logging
|
||||||
mysql2 (>= 0.4.4, < 0.6.0)
|
mysql2 (>= 0.4.4, < 0.6.0)
|
||||||
naught
|
naught
|
||||||
octicons
|
octicons
|
||||||
|
|
|
@ -7,17 +7,21 @@ namespace :checks do
|
||||||
|
|
||||||
desc "Refresh domains expiry dates"
|
desc "Refresh domains expiry dates"
|
||||||
task domain: :environment do
|
task domain: :environment do
|
||||||
|
logger = Logging.logger(STDOUT)
|
||||||
|
logger.level = :warn
|
||||||
configuration = Rails.configuration.chexpire.fetch("checks_domain")
|
configuration = Rails.configuration.chexpire.fetch("checks_domain")
|
||||||
|
|
||||||
process = CheckDomainProcessor.new(configuration: configuration)
|
process = CheckDomainProcessor.new(logger: logger, configuration: configuration)
|
||||||
process.sync_dates
|
process.sync_dates
|
||||||
end
|
end
|
||||||
|
|
||||||
desc "Refresh SSL expiry dates"
|
desc "Refresh SSL expiry dates"
|
||||||
task ssl: :environment do
|
task ssl: :environment do
|
||||||
|
logger = Logging.logger(STDOUT)
|
||||||
|
logger.level = :warn
|
||||||
configuration = Rails.configuration.chexpire.fetch("checks_ssl")
|
configuration = Rails.configuration.chexpire.fetch("checks_ssl")
|
||||||
|
|
||||||
process = CheckSSLProcessor.new(configuration: configuration)
|
process = CheckSSLProcessor.new(logger: logger, configuration: configuration)
|
||||||
process.sync_dates
|
process.sync_dates
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue