Class: ForemanTasksCore::BatchRunnerAction

Inherits:
Runner::Action show all
Defined in:
lib/foreman_tasks_core/batch_runner_action.rb

Instance Method Summary collapse

Methods inherited from Runner::Action

#failed_run?, #finalize, #finish_run, #init_run, #kill_run, #process_external_event, #process_update, #rescue_strategy_for_self, #run, #runner_dispatcher

Instance Method Details

#initiate_runnerObject



9
10
11
12
# File 'lib/foreman_tasks_core/batch_runner_action.rb', line 9

def initiate_runner
  launcher = SmartProxyDynflowCore::TaskLauncherRegistry.fetch(input[:operation])
  launcher.runner_class.new(input[:targets], suspended_action: suspended_action)
end

#plan(launcher, input) ⇒ Object



5
6
7
# File 'lib/foreman_tasks_core/batch_runner_action.rb', line 5

def plan(launcher, input)
  plan_self :targets => launcher.runner_input(input), :operation => launcher.operation
end