Class: DevLXC::CLI::Server

Inherits:
Thor
  • Object
show all
Defined in:
lib/dev-lxc/cli.rb

Instance Method Summary collapse

Instance Method Details

#abspath(name, rootfs_path) ⇒ Object



86
87
88
# File 'lib/dev-lxc/cli.rb', line 86

def abspath(name, rootfs_path)
  puts get_server(name, options[:config]).abspath(rootfs_path)
end

#destroy(name) ⇒ Object



111
112
113
114
115
# File 'lib/dev-lxc/cli.rb', line 111

def destroy(name)
  server = get_server(name, options[:config])
  server.destroy
  server.destroy_base_containers if options[:base]
end

#run_command(name, command) ⇒ Object



92
93
94
# File 'lib/dev-lxc/cli.rb', line 92

def run_command(name, command)
  get_server(name, options[:config]).run_command(command)
end

#start(name) ⇒ Object



98
99
100
# File 'lib/dev-lxc/cli.rb', line 98

def start(name)
  get_server(name, options[:config]).start
end

#status(name) ⇒ Object



80
81
82
# File 'lib/dev-lxc/cli.rb', line 80

def status(name)
  get_server(name, options[:config]).status
end

#stop(name) ⇒ Object



104
105
106
# File 'lib/dev-lxc/cli.rb', line 104

def stop(name)
  get_server(name, options[:config]).stop
end