- From: Thorsten Fischer <
>
- To:
- Subject: [chef] Berkshelf: dependency resolution via Berksfile does not seem to work
- Date: Thu, 23 Aug 2012 15:24:49 +0200
Hi all,
I have a question regarding the resolution of cookbook dependencies in
Berkshelf, using the "metadata" line in a Berksfile. Executive summary:
it does not work for me. Suggestion: I am misunderstanding something,
but I can't see what it is.
At berkshelf.com I read the following: "[...] This allows you to resolve
a Cookbook’s dependencies that you are currently working on just like
you would resolve the dependencies of a Gem that you are currently
working on with Bundle".
What I expected to work was therefore the following:
$ cd project/
$ cat Berksfile
cookbook "berkshelf-test-1", git:
"git://github.com/froschi/berkshelf-test-1.git"
At said URL, there is a cookbook (created using 'berks cookbook', as it
happens, though that probably does not matter). It contains the
following line in metadata.rb:
depends "berkshelf-test-2", ">= 0.0.1"
and in its Berksfile:
metadata
cookbook "berkshelf-test-2", git:
"git://github.com/froschi/berkshelf-test-2.git"
In the project folder above, I expected to run:
$ berks install
and watch Berkshelf pull in the berkshelf-test-1 cookbook, resolve the
dependency, then pull in the berkshelf-test-2 cookbook automatically
from the source specified. However, what I get is:
Installing berkshelf-test-1 (0.0.1) from git:
'git://github.com/froschi/berkshelf-test-1' with branch:
'58f043037e76b04e1096eed7b2c14941505c13fd'
FATAL: Cookbook 'berkshelf-test-2' not found at site:
'
http://cookbooks.opscode.com/api/v1/cookbooks'
So, it finds the dependency (if via metadata.rb or Berksfile, I do not
know), but it does not follow the specification in the Berksfile.
Is this a bug? Am I misunderstanding how it should work?
Cheers,
t
- [chef] Berkshelf: dependency resolution via Berksfile does not seem to work, Thorsten Fischer, 08/23/2012
Archive powered by MHonArc 2.6.16.