Class: ForemanMaintain::Cli::Procedure::AbstractProcedureCommand
- Inherits:
-
Base
- Object
- Clamp::Command
- Base
- ForemanMaintain::Cli::Procedure::AbstractProcedureCommand
- Includes:
- TransformClampOptions
- Defined in:
- lib/foreman_maintain/cli/advanced/procedure/abstract_procedure_command.rb
Direct Known Subclasses
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
Methods included from TransformClampOptions
Methods inherited from Base
#available_checks, #available_procedures, #available_tags, available_tags, completion_map, completion_types, dashize, #dashize, delete_duplicate_assumeyes_if_any, interactive_option, label_option, #label_string, option, #option_wrapper, parameter, #print_check_info, #reporter, #run_scenario, #run_scenarios_and_exit, service_options, subcommand, #tag_string, tags_option, #underscorize
Methods included from ForemanMaintain::Concerns::Logger
Methods included from ForemanMaintain::Concerns::Finders
#check, #detector, #feature, #find_all_scenarios, #find_procedures, #find_scenarios, #procedure
Instance Method Details
#execute ⇒ Object
7 8 9 10 11 12 13 14 |
# File 'lib/foreman_maintain/cli/advanced/procedure/abstract_procedure_command.rb', line 7 def execute label = underscorize(invocation_path.split.last) procedure = procedure(label.to_sym) scenario = ForemanMaintain::Scenario.new scenario.add_step(procedure.new(get_params_for(procedure))) run_scenario(scenario) exit runner.exit_code end |