1

我一直在尝试在 vagrant 中使用https://github.com/poise/application_python/blob/master/examples/recipes-packaginator.rb 但由于某种原因,第一次部署总是失败,例如

Chef::Exceptions::EnclosingDirectoryDoesNotExist: directory[/srv/packaginator/shared/env] (/tmp/vagrant-chef-1/chef-solo-1/cookbooks/python/providers/virtualenv.rb line 31) had an error: Chef::Exceptions::EnclosingDirectoryDoesNotExist: Parent directory /srv/packaginator/shared does not exist, cannot create /srv/packaginator/shared/env

但是,如果我在食谱中用 gunicorn 注释掉部分

gunicorn do
    app_module :django
    port 8080
end

部署成功。如果我之后启用它并重新运行部署,它会成功运行并创建 gunicorn 和主管相关文件。

食谱似乎出现了问题。我正在使用最新版本的 Vagrant 和 Chef 10.14.2,使用精确的 32.box

application_python 是 2.0.4 版本(与 chef 10 兼容的最新版本)

编辑:即使升级到 Chef 11.8(使用 vagrant-omnibus),问题仍然存在。

4

1 回答 1

0

“你的配方代码应该创建所需的目录。”

@coderanger:https ://github.com/poise/python/issues/86

于 2014-02-22T02:13:11.683 回答