2023-11-13 10:52:45 +01:00
|
|
|
sidekiq_enabled = ENV.has_key?('REDIS_SIDEKIQ_SENTINELS') || ENV.has_key?('REDIS_URL')
|
|
|
|
|
|
|
|
if Rails.env.production? && sidekiq_enabled
|
|
|
|
ActiveSupport.on_load(:after_initialize) do
|
|
|
|
class ActiveStorage::PurgeJob < ActiveStorage::BaseJob
|
|
|
|
self.queue_adapter = :sidekiq
|
|
|
|
end
|
2023-11-21 16:13:32 +01:00
|
|
|
|
|
|
|
class VirusScannerJob
|
|
|
|
self.queue_adapter = :sidekiq
|
|
|
|
end
|
2023-12-07 15:47:47 +01:00
|
|
|
|
|
|
|
class DossierRebaseJob < ApplicationJob
|
|
|
|
self.queue_adapter = :sidekiq
|
|
|
|
end
|
2024-01-29 15:42:55 +01:00
|
|
|
|
|
|
|
class ProcedureExternalURLCheckJob < ApplicationJob
|
|
|
|
self.queue_adapter = :sidekiq
|
|
|
|
end
|
2023-11-13 10:52:45 +01:00
|
|
|
end
|
|
|
|
end
|