chef / chef-apply

The ad-hoc execution tool for the Chef ecosystem.
https://www.chef.sh/
Apache License 2.0
14 stars 14 forks source link

Chef 13 on Windows does not find config or policyfile bundle #22

Closed tyler-ball closed 6 years ago

tyler-ball commented 6 years ago

Description

Trying to run chef-run against a Windows host with Chef 13.10 installed fails. It outputs an error like Cannot find config at C:\workstation.rb. It appears that when we invoke chef-client -z --config workstation.rb it things we are trying to reference the root dir instead of the local dir.

I actually found this bug in Linux as well and fixed it via https://github.com/chef/chef-apply/pull/9 but that same fix does not work for Windows.

This is because we need to reverse the order we check for policyfiles in chef to check for File.exist? first over URI.regexp.

We will need to bump our minimum supported version to 13.10.1 after releasing that hotfix.

Chef Apply Version

master

Platform Version

Mac host, Windows target