Class: Nginxtra::CLI
- Inherits:
-
Thor
- Object
- Thor
- Nginxtra::CLI
- Includes:
- Thor::Actions
- Defined in:
- lib/nginxtra/cli.rb
Class Method Summary collapse
Instance Method Summary collapse
- #compile ⇒ Object
- #convert ⇒ Object
- #install ⇒ Object
- #print ⇒ Object
- #reload ⇒ Object
- #restart ⇒ Object
- #start ⇒ Object
- #status ⇒ Object
- #stop ⇒ Object
- #version ⇒ Object
Class Method Details
.source_root ⇒ Object
157 158 159 |
# File 'lib/nginxtra/cli.rb', line 157 def source_root File.absolute_path File.("../../..", __FILE__) end |
Instance Method Details
#compile ⇒ Object
62 63 64 65 66 67 |
# File 'lib/nginxtra/cli.rb', line 62 def compile Nginxtra::Error.protect self do set_working_dir! Nginxtra::Actions::Compile.new(self, prepare_config!).compile end end |
#convert ⇒ Object
33 34 35 36 37 |
# File 'lib/nginxtra/cli.rb', line 33 def convert Nginxtra::Error.protect self do Nginxtra::Actions::Convert.new(self, nil).convert end end |
#install ⇒ Object
75 76 77 78 79 |
# File 'lib/nginxtra/cli.rb', line 75 def install Nginxtra::Error.protect self do Nginxtra::Actions::Install.new(self, prepare_config!).install end end |
#print ⇒ Object
48 49 50 51 52 53 |
# File 'lib/nginxtra/cli.rb', line 48 def print Nginxtra::Error.protect self do set_working_dir! Nginxtra::Actions::Print.new(self, prepare_config!).print end end |
#reload ⇒ Object
119 120 121 122 123 124 |
# File 'lib/nginxtra/cli.rb', line 119 def reload Nginxtra::Error.protect self do set_working_dir! Nginxtra::Actions::Reload.new(self, prepare_config!).reload end end |
#restart ⇒ Object
110 111 112 113 114 115 |
# File 'lib/nginxtra/cli.rb', line 110 def restart Nginxtra::Error.protect self do set_working_dir! Nginxtra::Actions::Restart.new(self, prepare_config!).restart end end |
#start ⇒ Object
90 91 92 93 94 95 |
# File 'lib/nginxtra/cli.rb', line 90 def start Nginxtra::Error.protect self do set_working_dir! Nginxtra::Actions::Start.new(self, prepare_config!).start end end |
#status ⇒ Object
127 128 129 130 131 132 |
# File 'lib/nginxtra/cli.rb', line 127 def status Nginxtra::Error.protect self do set_working_dir! Nginxtra::Actions::Status.new(self, prepare_config!).status end end |
#stop ⇒ Object
102 103 104 105 106 107 |
# File 'lib/nginxtra/cli.rb', line 102 def stop Nginxtra::Error.protect self do set_working_dir! Nginxtra::Actions::Stop.new(self, prepare_config!).stop end end |
#version ⇒ Object
137 138 139 140 141 |
# File 'lib/nginxtra/cli.rb', line 137 def version Nginxtra::Error.protect self do say Nginxtra::Version end end |