class Rubear

init info

class Rubear(container_name)

To use

y = Rubear.new("container_name")
y.lxc_start
y.lxc_stop
Created by itsabear <itsabear@cpan.org>

Public Class Methods

new(container_name) click to toggle source
# File lib/rubear.rb, line 18
def initialize(container_name)
        @container_name = container_name

end

Public Instance Methods

start_lxc() click to toggle source
  • instance.start_lxc

# File lib/rubear.rb, line 24
def start_lxc
        `sudo lxc-start -n #{@container_name}`
end
stop_lxc() click to toggle source
  • instance.stop_lxc

# File lib/rubear.rb, line 29
def stop_lxc
        `sudo lxc-stop -n #{@container_name}`
end