hashicorp / vagrant

Vagrant is a tool for building and distributing development environments.
https://www.vagrantup.com
Other
26.27k stars 4.43k forks source link

Vagrant 2.0.1 returns Path specified for `nodes_path` does not exist: ["~/chef/nodes"] #9383

Closed onknows closed 6 years ago

onknows commented 6 years ago

Please note that the Vagrant issue tracker is reserved for bug reports and enhancements. For general usage questions, please use the Vagrant mailing list: https://groups.google.com/forum/#!forum/vagrant-up. Thank you!

Vagrant version

2.0.1

Host operating system

Ubuntu 16.04

Guest operating system

Ubuntu 16.04

Vagrantfile

  # Revproxy
  config.vm.define 'tecra' do |tec|
    tec.vm.network 'private_network', ip: '192.168.2.3'    
    tec.vm.hostname = 'tecra.local'
    tec.vm.network 'forwarded_port', guest: 8443, host: 8443
    tec.vm.provider 'virtualbox' do |vb|
      vb.gui = false
      vb.memory = 512
      vb.cpus = 1
    end
    tec.vm.provision 'chef_zero' do |chef|
      chef.environment = 'devinfra_staging'
      chef.cookbooks_path = '~/chef/cookbooks'
      chef.add_recipe 'ok-vagrant'
      chef.roles_path = '~/chef/roles'
      chef.data_bags_path = '~/chef/data_bags'
      chef.encrypted_data_bag_secret_key_path = '~/chef/chef_key'
      chef.environments_path = '~/chef/.environments/ok-staging'
      chef.nodes_path = '~/chef/nodes'
      chef.version = '12.14.89'
      chef.add_recipe 'motd'
    end
  end

Debug output

https://gist.github.com/onknows/305dfe8a2b6a3517ac2a3879961ebe40

Expected behavior

vagrant up with Chef provisioning works similar to 1.8.7

Actual behavior

vagrant up does not work and returns Path specified for nodes_path does not exist: ["~/chef/nodes"]

Steps to reproduce

  1. upgrade vagrant from 1.8.7 to 2.0.1
  2. Vagrant file with nodes_path with for example ~/chef/nodes
  3. v up

References

briancain commented 6 years ago

@onknows Hmm, does this work if you use a full path rather than a relative path?

onknows commented 6 years ago

Yes it works with full path. This is the workaround I'm using now.

ghost commented 4 years ago

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.