tiangolo / full-stack

Full stack, modern web application generator. Using Flask, PostgreSQL DB, Docker, Swagger, automatic HTTPS and more.
MIT License
523 stars 81 forks source link

Configurable postgres server #5

Closed abnerjacobsen closed 6 years ago

abnerjacobsen commented 6 years ago

Hi,

Another patch I'd like to propose.

With it it will be possible to configure which Postgres server to use instead of what is hard coded in the application's docker-compose and in the app source code.

Imagine that after testing the application locally you want to use a Postgres server hosted by Amazon AWS RDS / Aurora.

Changing the following variables in the .env file will achieve the goal:

POSTGRES_SERVER=dbdizendoai.XXXX.us-east-1.rds.amazonaws.com
POSTGRES_USER=pgadmin
POSTGRES_PASSWORD=AwsRdsPwd
POSTGRES_DB=MyAwsDb

What you think about this change ?

tiangolo commented 6 years ago

Yep, I get your point. Thanks for the contribution! :tada: