class VagrantPlugins::HostManager::Provisioner

Public Class Methods

new(machine, config) click to toggle source
Calls superclass method
# File lib/vagrant-hostmanager/provisioner.rb, line 7
def initialize(machine, config)
  super(machine, config)
  global_env = machine.env
  @config = Util.get_config(global_env)
  @updater = HostsFile::Updater.new(global_env, machine.provider_name)
end

Public Instance Methods

provision() click to toggle source
# File lib/vagrant-hostmanager/provisioner.rb, line 14
def provision
  if @config.hostmanager.manage_guest?
    @updater.update_guest(@machine)
  end
  if @config.hostmanager.manage_host?
    @updater.update_host
  end
end