如何指定一个python builderpack?

Ivar_PredixCN 2017-08-28 09:45:11
PROBLEM
You want to write your app in Python but are unsure how it will be handled by Predix and Cloud Foundry buildpacks or you want to specify a different buildpack than what is discovered from your application source code.

STEPS
(1) You can view the available buildpacks with cf buildpacks.

You will see output such as the name and version of the buildpacks pre-installed on the platform:

python_buildpack 5 true false python_buildpack-cached-v1.5.9.zip ... python_minconda_buildpack 17 false false python_minconda_buildpack.zip
(2) Specify the buildpack you want either on the command line when you push or specify it in your manifest. It can either be the name of the buildpack pre-installed or you can get the latest directly from Github

Examples

Get version that is pre-installed in Predix (1.5.9)

cf push -b python_buildpack
Get the latest release directly from Github (1.5.20)

cf push -b https://github.com/cloudfoundry/python-buildpack.git#v1.5.20
Specify it in your manifest:

 ---
applications:
- name: latest-buildpack-demo
buildpack: https://github.com/cloudfoundry/buildpack-python.git#v1.5.20

If you are trying to use a different version of Python, see How-To: Specify a Python Version.

DEPENDENCIES
Cloud Foundry CLI

You can also optionally use the Predix CLI.

RESOURCES
Github Repository for Python Buildpack
https://github.com/cloudfoundry/python-buildpack
Cloud Foundry Documentation on Python Buildpack
http://docs.cloudfoundry.org/buildpacks/python/
cloud-foundry-cli
...全文
41 回复 打赏 收藏 转发到动态 举报
写回复
用AI写文章
回复
切换为时间正序
请发表友善的回复…
发表回复

163

社区成员

发帖
与我相关
我的任务
社区描述
GE的Predix平台整合云计算可扩展性、大数据管理和高级分析技术来助力新一代的数字化企业。结合GE自己作为全球工业界领导者的经验,Predix云平台为开发高级工业应用程序提供可连接性、安全和高性能。
云计算大数据 技术论坛(原bbs)
社区管理员
  • GE Predix工业互联网开发社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧