Vagrant: Vagrant 1.8.7 breaks Salt Provisioner Plugin

Created on 14 Nov 2016  ยท  4Comments  ยท  Source: hashicorp/vagrant

This appears to just be broken, due to changes in the 1.8.7 version of vagrant and it didn't include those changes in the Salt provisioner. Reproduced on two different employee laptops with the same configuration, only difference is one is using VirtualBox the other VMware Fusion 8. Both error out with the same exact issue.

Vagrant file doesn't seem to matter either, just needs to be a box that uses Salt for provisioning to cause the error.

Vagrant version

1.8.7

Host operating system

10.12.1 (16B2555)

Guest operating system

bento/debian-7.11

Vagrantfile

# -*- mode: ruby -*-
# vi: set ft=ruby tabstop=2 shiftwidth=2 softtabstop=2 expandtab :
root = File.dirname(__FILE__)
VAGRANT_ROOT = root unless defined? VAGRANT_ROOT

Vagrant.configure(2) do |config|
  config.vm.define "mlish" do |mlish|
    mlish.vm.network "private_network", ip: "172.28.1.6"
    mlish.vm.box = "bento/debian-7.11"

    mlish.vm.synced_folder "#{root}/saltstack/salt", "/srv/salt"
    mlish.vm.synced_folder "#{root}/saltstack/pillar", "/srv/pillar"
    mlish.vm.synced_folder "#{root}/saltstack/formulas", "/srv/formulas"

    mlish.ssh.forward_agent = true

    mlish.vm.provision :salt do |salt|
      salt.run_highstate = true
      salt.verbose = true
      salt.colorize = true
      salt.masterless = true
      salt.log_level = "warning"
      salt.minion_config = "#{root}/saltstack/minion"
    end
  end
end

Backtrace output showing the issue

https://gist.github.com/RobertDeRose/976a6d997cb5f5f7e37cc7813556af33

Expected behavior

For it not to blow up.

Actual behavior

/opt/vagrant/embedded/gems/gems/vagrant-1.8.7/plugins/provisioners/salt/provisioner.rb:43:in `initialize': no implicit conversion of Object into String (TypeError)

Steps to reproduce

  1. bring up a box that uses salt for provisioning

Most helpful comment

@RobertDeRose you can manually patch vagrant/plugins/provisioners/salt/provisioner.rb which in osx lives in /opt/vagrant/embedded/gems/gems/vagrant-1.8.7/plugins/provisioners/salt/provisioner.rb

in vagrant 1.8.7 line number 9 is:

      OPTIMISTIC_PATH_DEFAULTS = Hash[[

change it to :

      OPTIMISTIC_PATH_DEFAULTS = Hash[*[

Seem like it's fix on master

All 4 comments

@RobertDeRose you can manually patch vagrant/plugins/provisioners/salt/provisioner.rb which in osx lives in /opt/vagrant/embedded/gems/gems/vagrant-1.8.7/plugins/provisioners/salt/provisioner.rb

in vagrant 1.8.7 line number 9 is:

      OPTIMISTIC_PATH_DEFAULTS = Hash[[

change it to :

      OPTIMISTIC_PATH_DEFAULTS = Hash[*[

Seem like it's fix on master

@jespada Thanks for the workaround, but it appears 1.8.7 just didn't do enough QA before going out, there are too many issues and I've rolled back to 1.8.6 for a stable experience. Hopefully, 1.8.8 will be out soon and will have gone through better QA.

Fixed via #7986

I'm going to lock this issue because it has been closed for _30 days_ โณ. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

luispabon picture luispabon  ยท  3Comments

jsirex picture jsirex  ยท  3Comments

janw-me picture janw-me  ยท  3Comments

rrzaripov picture rrzaripov  ยท  3Comments

mpontillo picture mpontillo  ยท  3Comments