Elastic Beanstalk上的PostgreSQL(Amazon Linux 2) [英] PostgreSQL on Elastic Beanstalk (Amazon Linux 2)
本文介绍了Elastic Beanstalk上的PostgreSQL(Amazon Linux 2)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
对于上一代的Amazon Linux,我要做的就是在.ebextensions中添加以下内容以使用PostgreSQL:
packages:
yum:
postgresql93-devel: []
现在,当我使用以下平台在EB上进行部署时: 在64位Amazon Linux 2/3.0.0上运行的Python 3.7
我在部署时遇到以下错误:
[ERROR] Error occurred during build: Yum does not have postgresql93-devel available for installation
因此,由于我需要连接到RDS中的PostgreSQL数据库,因此无法进行部署.
我需要在.ebextensions中进行哪些配置?
解决方案
以下作品:
packages:
yum:
amazon-linux-extras: []
commands:
01_postgres_activate:
command: sudo amazon-linux-extras enable postgresql10
02_postgres_install:
command: sudo yum install -y postgresql-devel
With former generation of Amazon Linux, all I needed to do is add the following in .ebextensions in order to use PostgreSQL:
packages:
yum:
postgresql93-devel: []
Now when I deploy on EB with the following platform: Python 3.7 running on 64bit Amazon Linux 2/3.0.0
I get the following error on deployment:
[ERROR] Error occurred during build: Yum does not have postgresql93-devel available for installation
Therefore it is impossible to deploy as I need to connect to a PostgreSQL database in RDS.
What config in .ebextensions do I need to do?
解决方案
The following works:
packages:
yum:
amazon-linux-extras: []
commands:
01_postgres_activate:
command: sudo amazon-linux-extras enable postgresql10
02_postgres_install:
command: sudo yum install -y postgresql-devel
这篇关于Elastic Beanstalk上的PostgreSQL(Amazon Linux 2)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文