【发布时间】:2019-02-09 16:18:53
【问题描述】:
我正在尝试让 python 模块 python3-saml 在使用标准 python buildpack 和 cflinuxfs2 堆栈的云铸造应用程序上工作。该模块依赖于 python xmlsec 模块作为依赖项,但不幸的是我遇到了让它工作的问题。
我已经整理了一个需求文件并提供了所有 python 依赖项,但是当我运行“cf push”命令时,我不断收到以下错误。
Running setup.py install for xmlsec: started
Running setup.py install for xmlsec: finished with status 'error'
Complete output from command /tmp/contents998689849/deps/0/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-lwwtrplp/xmlsec/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-qwoda574-record/install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_ext
*********************************************************************************
Could not find xmlsec1 config. Are libxmlsec1-dev and pkg-config installed?
*********************************************************************************
----------------------------------------
Command "/tmp/contents998689849/deps/0/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-lwwtrplp/xmlsec/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-qwoda574-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-lwwtrplp/xmlsec/
pip install has failed. You have a vendor directory, it must contain all of your dependencies.
**ERROR** Could not install pip packages: Couldn't run pip: exit status 1
Failed to compile droplet: Failed to run all supply scripts: exit status 14
Exit status 223
我尝试手动上传适当的 libxmlsec1-dev 和 libxmlsec1 并设置一个环境变量来引用它们,但暂存过程似乎只是在设置软件包时忽略了这些。
我可以做些什么来让这个过程正常进行吗?我想在某个地方有一个自定义的 buildpack 可以解决问题,但我不确定是否有办法使用标准的 python buildpack 来代替。
【问题讨论】:
标签: python linux python-3.x cloud-foundry