Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/logging/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Chef infra 为什么要向Berksfile添加过渡依赖项?_Chef Infra_Berksfile - Fatal编程技术网

Chef infra 为什么要向Berksfile添加过渡依赖项?

Chef infra 为什么要向Berksfile添加过渡依赖项?,chef-infra,berksfile,Chef Infra,Berksfile,我正在开发一本食谱(我的食谱),它与另一本食谱有依赖关系(另一本食谱),它与另一本食谱有依赖关系(另一本食谱2)。 为什么我需要在my_cookbookBerksfile中指定过渡依赖项(意味着将另一个\u cookbook2依赖项添加到Berskfile)?如果已在另一个\u cookbook文件中指定了与另一个\u cookbook 2的依赖关系 $ berks install Resolving cookbook dependencies... ... Unable to satisfy

我正在开发一本食谱(
我的食谱
),它与另一本食谱有依赖关系(
另一本食谱
),它与另一本食谱有依赖关系(
另一本食谱2
)。 为什么我需要在
my_cookbook
Berksfile中指定过渡依赖项(意味着将
另一个\u cookbook2
依赖项添加到Berskfile)?如果已在
另一个\u cookbook
文件中指定了与
另一个\u cookbook 2
的依赖关系

$ berks install
Resolving cookbook dependencies...
...
Unable to satisfy constraints on package another_cookbook2, which does not exist, due to solution constraint (another_cookbook = 0.0.1). Solution constraints that may result in a constraint on another_cookbook2: [(another_cookbook = 0.0.1) -> (another_cookbook2 >= 0.0.0)]
Missing artifacts: another_cookbook2
...
在将我的食谱上传到厨师服务器之前,我正在尝试这样做。

你没有。
如果您共享您的
Berskfile
s,我们可以向您展示最新情况。
依赖项列在
metadata.rb
文件中,而不是
Berksfile
中。
Berksfile
只是告诉Berks在哪里可以找到这些依赖项

如果您的berksfile中没有像样的BerksAPI端点,比如supermarket.chef.io,那么您可能必须列出相关烹饪书的位置

metadata.rb
不同,Berksfile不是递归构建的,因此不会使用从属cookbook中的
Berksfile