【问题标题】:App Engine Flexible - requirements.txt include GCP repositoryApp Engine Flexible - requirements.txt 包含 GCP 代码库
【发布时间】:2017-12-06 16:13:42
【问题描述】:

我正在尝试设置在 python 3 App Engine 柔性环境中运行的应用程序。我有一个 app.yaml 文件:

runtime: python
env: flex
entrypoint: gunicorn -b :$PORT application:app

runtime_config:
  python_version: 3

我有一个 requirements.txt 列出了我的应用需要的一些包:

Flask==0.12
gunicorn==19.7.1
...

我还有一个通用函数包,它位于 GCP 源存储库 (git) 中。我不想在 PyPi 上公开托管它。是否仍然可以将其作为要求包含在内?比如:

git+https://source.developers.google.com/p/app/r/common

当我在本地机器上尝试时,使用上述要求输入用户名和密码,即使我设置了帮助程序:

git config credential.helper gcloud.sh

【问题讨论】:

  • git+ssh:// 总是挂起,有或没有 git@,有或没有可编辑模式。大概 ssh 不可用于源代码库。 git+git:// 是一样的。 GitHub 显然已经单独启用了这项服务。

标签: python git google-app-engine app-engine-flexible requirements.txt


【解决方案1】:

您可以将-i @987654321@ --trusted-host yourhost.com 标志添加到requirements.txt 文件中。

【讨论】:

    猜你喜欢
    • 2019-07-10
    • 2013-02-12
    • 2018-07-09
    • 1970-01-01
    • 2017-12-07
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多