From 552a791ef4350609a277344e3263c9f8fcc4e126 Mon Sep 17 00:00:00 2001 From: Paulo Bittencourt Date: Mon, 17 Mar 2014 21:11:02 -0400 Subject: [PATCH] fix provisioner issue in vagrant 1.5 relates to #80 --- lib/vagrant-hostmanager/plugin.rb | 6 ++++++ test/Vagrantfile | 8 +++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/lib/vagrant-hostmanager/plugin.rb b/lib/vagrant-hostmanager/plugin.rb index 8369d19..86dab08 100644 --- a/lib/vagrant-hostmanager/plugin.rb +++ b/lib/vagrant-hostmanager/plugin.rb @@ -29,6 +29,12 @@ module VagrantPlugins Provisioner end + # Work-around for vagrant >= 1.5 + # It breaks without a provisioner config, so we provide a dummy one + config(:hostmanager, :provisioner) do + ::Vagrant::Config::V2::DummyConfig.new + end + command(:hostmanager) do require_relative 'command' Command diff --git a/test/Vagrantfile b/test/Vagrantfile index 4c624d1..ecaa38c 100644 --- a/test/Vagrantfile +++ b/test/Vagrantfile @@ -22,4 +22,10 @@ Vagrant.configure('2') do |config| server.vm.hostname = 'bender' server.vm.network :private_network, :ip => '10.0.5.3' end -end + + config.vm.define :server3 do |server| + server.vm.hostname = 'leena' + server.vm.network :private_network, :ip => '10.0.5.4' + server.vm.provision :hostmanager + end +end \ No newline at end of file