Class: Specinfra::Command::Linux::Base::LxcContainer

Inherits:
Base::LxcContainer show all
Defined in:
lib/specinfra/command/linux/base/lxc_container.rb

Class Method Summary collapse

Methods inherited from Base

create, escape

Class Method Details

.check_exists(container) ⇒ Object



3
4
5
# File 'lib/specinfra/command/linux/base/lxc_container.rb', line 3

def check_exists(container)
  "lxc-ls -1 | grep -w #{escape(container)}"
end

.check_is_running(container) ⇒ Object



7
8
9
# File 'lib/specinfra/command/linux/base/lxc_container.rb', line 7

def check_is_running(container)
  "lxc-info -n #{escape(container)} -s | grep -w RUNNING"
end