samedi 8 août 2015

Setting up Flask with sqlalchemy and RDS-postgres on AWS [duplicate]

This question already has an answer here:

I am trying to setup Flask based server on AWS using ElasticBeanstalk. This is my requirements.txt:

alembic==0.7.7
blinker==1.4
Flask==0.10.1
Flask-Login==0.2.11
Flask-Mail==0.9.1
Flask-Migrate==1.5.0
Flask-Principal==0.4.0
Flask-Script==2.0.5
Flask-Security==1.7.4
Flask-SQLAlchemy==2.0
Flask-WTF==0.12
itsdangerous==0.24
Jinja2==2.8
Mako==1.0.1
MarkupSafe==0.23
passlib==1.6.5
psycopg2==2.6.1
SQLAlchemy==1.0.8
Werkzeug==0.10.4
wheel==0.24.0
WTForms==2.0.2

NOTE: All of this works fine on development environment locally but not while deploying to AWS. Not related to this

Not sure what is wrong here. I am setting up Postgres on RDS to connect to this instance. And using a config to connect to via SQLAlchemy and psycopg2 in flask. my deployment failed using command line eb tool. I found this in logs so far:

Error: pg_config executable not found

Is it not a typical way to configure postgres with Flask Based app?

EDIT: I also noticed this error in logs:

CalledProcessError: Command '/opt/python/run/venv/bin/pip install -r /opt/python/ondeck/app/requirements.txt' returned non-zero exit status 1 (ElasticBeanstalk::ExternalInvocationError)
caused by: You are using pip version 7.0.3, however version 7.1.0 is available.

Shouldn't the pip version be set by eb itself?




Aucun commentaire:

Enregistrer un commentaire