Class: Krane::CLI::Krane
- Inherits:
-
Thor
- Object
- Thor
- Krane::CLI::Krane
- Defined in:
- lib/krane/cli/krane.rb
Constant Summary collapse
- TIMEOUT_EXIT_CODE =
70
- FAILURE_EXIT_CODE =
1
Class Method Summary collapse
Instance Method Summary collapse
- #deploy(namespace, context) ⇒ Object
- #global_deploy(context) ⇒ Object
- #render ⇒ Object
- #restart(namespace, context) ⇒ Object
- #run_command(namespace, context) ⇒ Object
- #version ⇒ Object
Class Method Details
.exit_on_failure? ⇒ Boolean
70 71 72 |
# File 'lib/krane/cli/krane.rb', line 70 def self.exit_on_failure? true end |
.expand_options(task_options) ⇒ Object
20 21 22 |
# File 'lib/krane/cli/krane.rb', line 20 def self.() .each { |option_name, config| method_option(option_name, config) } end |
Instance Method Details
#deploy(namespace, context) ⇒ Object
56 57 58 59 60 |
# File 'lib/krane/cli/krane.rb', line 56 def deploy(namespace, context) rescue_and_exit do DeployCommand.(namespace, context, ) end end |
#global_deploy(context) ⇒ Object
64 65 66 67 68 |
# File 'lib/krane/cli/krane.rb', line 64 def global_deploy(context) rescue_and_exit do GlobalDeployCommand.(context, ) end end |
#render ⇒ Object
26 27 28 29 30 |
# File 'lib/krane/cli/krane.rb', line 26 def render rescue_and_exit do RenderCommand.() end end |
#restart(namespace, context) ⇒ Object
40 41 42 43 44 |
# File 'lib/krane/cli/krane.rb', line 40 def restart(namespace, context) rescue_and_exit do RestartCommand.(namespace, context, ) end end |
#run_command(namespace, context) ⇒ Object
48 49 50 51 52 |
# File 'lib/krane/cli/krane.rb', line 48 def run_command(namespace, context) rescue_and_exit do RunCommand.(namespace, context, ) end end |
#version ⇒ Object
34 35 36 |
# File 'lib/krane/cli/krane.rb', line 34 def version VersionCommand.() end |