Class: VagrantPlugins::Blockwart::Provisioner

Inherits:
Object
  • Object
show all
Defined in:
lib/vagrant-blockwart/provisioner.rb

Instance Method Summary collapse

Constructor Details

#initialize(machine, config) ⇒ Provisioner

Returns a new instance of Provisioner.



9
10
11
12
# File 'lib/vagrant-blockwart/provisioner.rb', line 9

def initialize(machine, config)
	super(machine, config)
	@logger = Log4r::Logger.new("vagrant::provisioners::blockwart")
end

Instance Method Details

#cleanupObject



24
25
26
27
28
# File 'lib/vagrant-blockwart/provisioner.rb', line 24

def cleanup
	bw = BwManage.new(config.repo_path)
	ssh = SshConf.new
	ssh.remove_hosts(bw.node_hosts)
end

#configure(root_config) ⇒ Object



14
15
# File 'lib/vagrant-blockwart/provisioner.rb', line 14

def configure(root_config)
end

#provisionObject



17
18
19
20
21
22
# File 'lib/vagrant-blockwart/provisioner.rb', line 17

def provision
	ssh = SshConf.new
	ssh.update(config.node_host, @machine.ssh_info)
	bw = BwManage.new(config.repo_path)
	bw.apply(config.node_name, config.interactive)
end