Skip to content

Commit

Permalink
Fixes #25541 - Trigger singleton actions in post init hook
Browse files Browse the repository at this point in the history
  • Loading branch information
adamruzicka authored and jlsherrill committed Dec 3, 2018
1 parent 34d3d13 commit c23ae22
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions katello.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ Gem::Specification.new do |gem|

gem.add_dependency "rabl"
gem.add_dependency "foreman-tasks", "~> 0.13", ">= 0.14.1"
gem.add_dependency "dynflow", ">= 1.1.3"
gem.add_dependency "foreman_docker", ">= 0.2.0"

gem.add_dependency "qpid_messaging"
Expand Down
4 changes: 2 additions & 2 deletions lib/katello/engine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ class Engine < ::Rails::Engine
end

initializer "katello.initialize_cp_listener", :before => :finisher_hook do
unless ForemanTasks.dynflow.config.remote? || File.basename($PROGRAM_NAME) == 'rake' || Rails.env.test?
ForemanTasks.dynflow.config.on_init do |world|
unless Rails.env.test?
ForemanTasks.dynflow.config.post_executor_init do |world|
::Actions::Candlepin::ListenOnCandlepinEvents.ensure_running(world)
::Actions::Katello::EventQueue::Monitor.ensure_running(world)
end
Expand Down

0 comments on commit c23ae22

Please sign in to comment.