Hello. I'm using the test-kitchen GitHub Action and am running into trouble with chef-cli not using my local Chef config.
When I run knife config show in a step before the Test Kitchen action, it correctly finds my config at .chef/config.rb. However, when Test Kitchen runs, chef-cli ignores this config, causing it to look for my client key at /etc/chef/client.pem instead of the location specified in my config.
This results in the following error
Failed to read the private key /etc/chef/client.pem: #<Errno::ENOENT: No such file or directory @ rb_sysopen - /etc/chef/client.pem>
We've tried symlinking the config.rb file to ~/.chef/config.rb :
mkdir -p ~/.chef && ln -svf .chef/config.rb ~/.chef/config.rb
but got the same results.
Has anyone had a similar issue or does anyone know how to make the Test Kitchen action use the local chef config? Thank you!