簡體   English   中英

AWS Elastic Beanstalk - 錯誤要求.txt

[英]AWS Elastic Beanstalk - error requirements.txt

當我嘗試部署我的Amazon Web Services Elastic Beanstalk項目(Python + Django)時,出現以下錯誤:

 2016-09-14 14:46:37,244 ERROR    Error installing dependencies: Command '/opt/python/run/venv/bin/pip install -r /opt/python/ondeck/app/requirements.txt' returned non-zero exit status 1
  Traceback (most recent call last):
    File "/opt/elasticbeanstalk/hooks/appdeploy/pre/03deploy.py", line 22, in main
      install_dependencies()
    File "/opt/elasticbeanstalk/hooks/appdeploy/pre/03deploy.py", line 18, in install_dependencies
      check_call('%s install -r %s' % (os.path.join(APP_VIRTUAL_ENV, 'bin', 'pip'), requirements_file), shell=True)
    File "/usr/lib64/python2.7/subprocess.py", line 540, in check_call
      raise CalledProcessError(retcode, cmd)
  CalledProcessError: Command '/opt/python/run/venv/bin/pip install -r /opt/python/ondeck/app/requirements.txt' returned non-zero exit status 1 (Executor::NonZeroExitStatus)

幾個月前我遇到了這個錯誤,我只是改變了.ebextensions中的配置,這使得部署能夠正常工作(問題是postgresql93-devel缺失):

packages:
    yum:
        git: []
        postgresql93-devel: []
        libffi-devel: []

我猜AWS在一個或多個我的庫中存在一個問題。我試圖安裝/卸載其中的一些來找到導致問題的那個,但還沒有管理。 這是我的要求.txt:

awsebcli==3.7.7
beautifulsoup4==4.4.1
boto==2.40.0
botocore==1.4.40
cement==2.8.2
cffi==1.5.2
colorama==0.3.7
cryptography==1.3.1
Django==1.9.4
django-storages==1.4.1
docker-py==1.7.2
dockerpty==0.4.1
docopt==0.6.2
docutils==0.12
enum34==1.1.2
future==0.15.2
futures==3.0.5
gax-google-logging-v2==0.8.1
gax-google-pubsub-v1==0.8.1
google-api-python-client==1.5.0
google-gax==0.13.0
googleads==3.13.0
googleapis-common-protos==1.3.4
grpc-google-logging-v2==0.8.1
grpc-google-pubsub-v1==0.8.1
grpcio==1.0.0
httplib2==0.9.2
idna==2.1
ipaddress==1.0.16
jmespath==0.9.0
oauth2client==2.0.1
pathspec==0.3.4
ply==3.8
protobuf==3.0.0
psycopg2==2.6.1
pyasn1==0.1.9
pyasn1-modules==0.0.8
pycparser==2.14
pyOpenSSL==16.0.0
PySocks==1.5.6
python-dateutil==2.5.3
pytz==2016.2
PyYAML==3.11
requests==2.9.1
rsa==3.4
s3transfer==0.1.4
semantic-version==2.5.0
simplejson==3.8.2
six==1.10.0
suds-jurko==0.6
texttable==0.8.4
uritemplate==0.6
websocket-client==0.37.0
xmltodict==0.10.1

我的猜測是問題來自其中一個庫(但我可能錯了!):

future==0.15.2
futures==3.0.5
gax-google-logging-v2==0.8.1
gax-google-pubsub-v1==0.8.1
google-gax==0.13.0
googleapis-common-protos==1.3.4
grpc-google-logging-v2==0.8.1
grpc-google-pubsub-v1==0.8.1
grpcio==1.0.0
ply==3.8
protobuf==3.0.0
s3transfer==0.1.4

Django項目在本地完美運作。 我的問題僅在於AWS Elastic Beanstalk部署。

如果您有任何想法,請告訴我。

我在這里看到同樣的問題,這是未來的圖書館。 如果查看AWS EB服務器錯誤日志(/ var / log / httpd / error_log),您可以看到錯誤。

python3 / django2不能很好地適應未來的模塊,但是wasebcli堅持認為。

我在這里通過不將awsebcli安裝到虛擬環境來解決它。 然后,您需要使用本地環境(安裝awsebcli)進行部署。

好像我們應該有一個AWSEBCLI的更新來最終解決這個問題。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM