Method: ContainerManager#initialize
- Defined in:
- lib/wf_node_api/container_manager.rb
#initialize(container_type) ⇒ ContainerManager
Initializes the manager with the matching adapter
149 150 151 152 153 154 155 156 157 |
# File 'lib/wf_node_api/container_manager.rb', line 149 def initialize(container_type) if container_type == 'lxc' @adapter = ContainerManagerAdapter::Lxc.new elsif container_type == 'vserver' @adapter = ContainerManagerAdapter::Vserver.new else raise ArgumentError, 'invalid container type' end end |