IBM Bluemix上的Python应用程序/推送命令中的清单中的依赖项丢失
问题描述:
如何修改清单以便使用默认生成包(2.7.11)支持的最新2.7 Python版本并将我的应用程序推送到Bluemix托管服务器以及为什么它解决了旧版本2.7.6?IBM Bluemix上的Python应用程序/推送命令中的清单中的依赖项丢失
我的命令是:
CF推MYAPP -m 128 -c “蟒server.py”
见下面所产生的误差:
C:\Python\myprojects\ABC>cf push myapp -m 128M -c "python server.py"
-----> Downloaded app package (6.2M)
-------> Buildpack version 1.5.5
! Warning: Your application is missing a Procfile. This file tells Heroku how to run your application.
! Learn more: https://devcenter.heroku.com/articles/procfile
-----> Installing python-2.7.6
DEPENDENCY MISSING IN MANIFEST: python 2.7.6
It looks like you're trying to use python 2.7.6.
Unfortunately, that version of python is not supported by this buildpack.
The versions of python supported in this buildpack are:
- 3.5.1
- 3.5.0
- 3.4.4
- 3.4.3
- 3.3.6
- 3.3.5
- 2.7.11
- 2.7.10
If you need further help, start by reading: http://github.com/cloudfoundry/python-buildpack/releases.
Staging failed: Buildpack compilation step failed
答
得到一个类似的问题与python3,从文档你不处理清单文件,但在你的应用程序的根目录的runtime.txt,它只包含python-3.5.1
对我来说,所以它必须是python-2.7.11
为你。
这是正确的,buildpack使用runtime.txt来指定应该安装哪个python版本,并且只有在buildpack支持该文件中指定的版本时才会起作用。或者,您可以省略runtime.txt以始终使用buildpack的默认版本(目前在1.5.12 buildpack版本中为2.7.12)。 –
感谢您的快速支持。更新runtime.txt文件解决了问题。 –