阅读背景:

GAE看不到炮弹,但它已经安装好了

来源:互联网 

I am trying to deploy Django app with Google App Engine.

我正在尝试使用Google App Engine部署Django应用程序。

My app.yaml file:

我的app.yaml文件:

# [START runtime]
runtime: python
api_version: 1
threadsafe: true
env: flex
entrypoint: gunicorn -b :$PORT wsgi

runtime_config:
    python_version: 3.4

env_variables:
    CLOUDSQL_CONNECTION_NAME: ugram-mysql
    CLOUDSQL_USER: root

handlers:
- url: /
  script: wsgi.application

# [END runtime]

But when I run gcloud app deploy, app deploy is running (5 minutes), but I get an error:

但是当我运行gcloud app deploy时,app deploy正在运行(5分钟),但是我收到一个错误:

Updating service [default]...failed.                                                                                                                                                 
ERROR: (gcloud.app.deploy) Error Response: [9] 
Application startup error:
/bin/sh: 1: exec: gunicorn: not found

But gunicorn is already installed

但枪炮已经装好了

mysupers-beta:~$ gunicorn
usage: gunicorn [OPTIONS] [APP_MODULE]
gunicorn: error: No application module specified.

2 个解决方案

#1


10  

Check if you have gunicorn==19.7.1 in your requirements.txt.

检查你的requirements.txt中是否有gunicorn == 19.7.1。

#2


0  

You need to have gunicorn added to your requirements.txt file.

您需要将gunicorn添加到您的requirements.txt文件中。


分享到: