Class: DevLXC::CLI::Server
- Inherits:
-
Thor
- Object
- Thor
- DevLXC::CLI::Server
- Defined in:
- lib/dev-lxc/cli.rb
Instance Method Summary collapse
- #abspath(name, rootfs_path) ⇒ Object
- #destroy(name) ⇒ Object
- #run_command(name, command) ⇒ Object
- #start(name) ⇒ Object
- #status(name) ⇒ Object
- #stop(name) ⇒ Object
Instance Method Details
#abspath(name, rootfs_path) ⇒ Object
90 91 92 |
# File 'lib/dev-lxc/cli.rb', line 90 def abspath(name, rootfs_path) puts get_server(name, [:config]).abspath(rootfs_path) end |
#destroy(name) ⇒ Object
117 118 119 120 121 122 123 |
# File 'lib/dev-lxc/cli.rb', line 117 def destroy(name) server = get_server(name, [:config]) server.destroy server.destroy_base_container(:unique) if [:unique] server.destroy_base_container(:shared) if [:shared] server.destroy_base_container(:platform) if [:platform] end |
#run_command(name, command) ⇒ Object
96 97 98 |
# File 'lib/dev-lxc/cli.rb', line 96 def run_command(name, command) get_server(name, [:config]).run_command(command) end |
#start(name) ⇒ Object
102 103 104 |
# File 'lib/dev-lxc/cli.rb', line 102 def start(name) get_server(name, [:config]).start end |
#status(name) ⇒ Object
84 85 86 |
# File 'lib/dev-lxc/cli.rb', line 84 def status(name) get_server(name, [:config]).status end |
#stop(name) ⇒ Object
108 109 110 |
# File 'lib/dev-lxc/cli.rb', line 108 def stop(name) get_server(name, [:config]).stop end |