Closed karmi closed 12 years ago
Hi @karmi, thanks for reporting this.
I see that you're using Chef 0.10.10. Other user already reported a similar behavior where Chef set the file's owner to nil
in that version, which made me change the resources logic a little bit. You can check the thread in #23.
Could you do me a favor and verify that the issue is not in Chef using a test case like the one that I suggest there?
https://github.com/calavera/minitest-chef-handler/issues/23#issuecomment-6536543
@calavera (I'm a user that reported this bug to karmi). Switching to chef 0.10.8 did result in tests passing.
Hi! Confirmed the file owner is returned as nil
... I too was bitten by Chef 0.10.10, currently trying to run the provisioning on Chef 10.12 (as suggested in http://stackoverflow.com/questions/11325479/how-to-control-the-version-of-chef-that-vagrant-uses-to-provision-vms/11485516#11485516), but so far no luck.
cool, I'm closing this ticket then. I was wondering if I should add a warning or something similar when this happen, even though it's not an issue here.
@calavera It's clearly an underlying system fault, not passing the owner properly -- maybe print a warning when Chef 10.10 is detected :)
Just a note, tried it with the precise64
box, which has Chef 0.10.10 as well, and the whole run fails with another link related error...
DEBUG: NoMethodError: ruby_block[update-java-alternatives] (java::openjdk line 43) had an error: NoMethodError: undefined method `to_str' for nil:NilClass
/opt/vagrant_ruby/lib/ruby/1.8/fileutils.rb:1414:in `fu_each_src_dest0'
/opt/vagrant_ruby/lib/ruby/1.8/fileutils.rb:336:in `ln_s'
/opt/vagrant_ruby/lib/ruby/1.8/fileutils.rb:359:in `ln_sf'
On the
lucid32
Vagrant box, the tests for the cookbook-elasticsearch are failing with:However, when SSH-ing to the box, the file in question has correct user:
The tests in question is here: https://github.com/karmi/cookbook-elasticsearch/blob/master/files/default/tests/minitest/installation_test.rb#L17-23
Reported first as karmi/cookbook-elasticsearch#22 and confirmed by @karmi.
Environment info: