Closed vvchik closed 9 years ago
+1
My cookbooks that use the windows cookbook broke with this ^ same error. Berkshelf for some reason is using HEAD instead of the version 1.37.0
....
depends 'windows', '~> 1.37.0'
To work around it, I had to pin my cookbook to a specific commit.
before
source "https://supermarket.chef.io"
metadata
cookbook 'windows', git: 'https://github.com/opscode-cookbooks/windows.git'
cookbook 'iis', git: 'https://github.com/opscode-cookbooks/iis.git'
after
source "https://supermarket.chef.io"
metadata
cookbook 'windows', git: 'https://github.com/opscode-cookbooks/windows.git', ref: 'c4fe4db505c0f184ee34fb0165f451f4c545634a'
cookbook 'iis', git: 'https://github.com/opscode-cookbooks/iis.git'
Update
According to the berkshelf documentation, if you have a git url, then it will always pull from HEAD.
Instead, I'm now pulling 1.37.0 from the supermarket.
I would think removing the git link would also do the trick. It would then fetch the release from supermarket instead of from git. When fetching from git, it picks master by default. If you don't want to pin to a ref, but insist on fetching from git, you can also use branch: name
or tag: name
to increase readability.
Thanks, though it looks like the cookbook still is broken when using chef 11. Do you need a separate issue for that?
Sorry about that - itchy trigger fingers. Fixed in 198d97e7feef038dff7cdb3b0c067052123e60d5
Super, thank you for info, and for fix.
we have a error with chef 11.18.12 on windows 2012r2 This is a problem with berkshelf using the latest git commit of the windows cookbook, instead of the metadata. This commit broke windows. opscode-cookbooks/windows@a8e8d3d
metadata
berksfile
powershell output
stack trace