【问题标题】:Unable to deploy django to python 3.8/Linux 2 on Elastic Beanstalk due to "postgresql95-devel is not available to be installed"由于“无法安装 postgresql95-devel”,无法在 Elastic Beanstalk 上将 django 部署到 python 3.8/Linux 2
【发布时间】:2021-06-07 02:26:45
【问题描述】:

这是我的 requirements.txt:

asgiref==3.3.1
boto3==1.17.23
botocore==1.20.23
certifi==2020.12.5
cffi==1.14.5
chardet==4.0.0
cryptography==3.4.6
defusedxml==0.7.1
Django==3.1.7
django-allauth==0.44.0
django-cors-headers==3.7.0
django-rest-auth==0.9.5
djangorestframework==3.12.2
idna==2.10
jmespath==0.10.0
oauthlib==3.1.0
psycopg2==2.8.6
pycparser==2.20
PyJWT==2.0.1
python-dateutil==2.8.1
python3-openid==3.2.0
pytz==2021.1
requests==2.25.1
requests-oauthlib==1.3.0
s3transfer==0.3.4
six==1.15.0
sqlparse==0.4.1
urllib3==1.26.3

我在日志中看到的主要错误消息是: postgresql95-devel 无法安装。我能够在较旧的环境(python 3.6)中部署类似的 requirements.txt,但由于某种原因,这在 python 3.8 上失败了。我什至使用了在 3.6 中成功的相同 deployment.zip,但在 3.8 中突然失败了。这是配置错误还是版本控制错误?不知道如何调试。

【问题讨论】:

  • 使用psycopg2-binary而不是psycopg2来摆脱PostgreSQL依赖。

标签: django amazon-web-services amazon-elastic-beanstalk psycopg2


【解决方案1】:

这意味着PostgreSQL 未安装。尝试安装并重试。

【讨论】:

    猜你喜欢
    • 2014-06-09
    • 1970-01-01
    • 2019-10-22
    • 2015-01-25
    • 1970-01-01
    • 1970-01-01
    • 2017-07-24
    • 2016-11-08
    • 2011-12-28
    相关资源
    最近更新 更多