Class: VagrantPlugins::Itamae::Provisioner

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

Instance Method Summary collapse

Instance Method Details

#provisionObject



6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# File 'lib/vagrant-itamae/provisioner.rb', line 6

def provision
  options = {
    node_json: config.json,
    node_yaml: config.yaml,
    sudo: config.sudo,
    shell: config.shell,
    host: @machine.ssh_info[:host],
    port: @machine.ssh_info[:port],
    user: @machine.ssh_info[:username],
    key:  @machine.ssh_info[:private_key_path][0]
  }

  ::Itamae.logger.level = config.log_level
  ::Itamae::Runner.run(config.recipes, :ssh, options)
end