Class: Mist::LxcServer

Inherits:
Object
  • Object
show all
Defined in:
lib/mist/handlers/lxc.rb

Instance Method Summary collapse

Constructor Details

#initialize(config, id = 0) ⇒ LxcServer

Returns a new instance of LxcServer.



82
83
84
85
86
87
# File 'lib/mist/handlers/lxc.rb', line 82

def initialize(config, id = 0)
  port = 18_800 + id

  @server = MessagePack::RPC::Server.new
  @server.listen('0.0.0.0', port, LxcHandler.new(config))
end

Instance Method Details

#runObject



89
90
91
# File 'lib/mist/handlers/lxc.rb', line 89

def run
  @server.run
end