Customise .env.sample
and rename it to .env
docker build -t my_postgres_image .
docker run --name my_postgres_container -p 5432:5432 -d my_postgres_image
In alembic.ini
use the sqlalchemy.url:
sqlalchemy.url = postgresql://myuser:mypassword@localhost:5432/mydatabase
alembic init alembic
Set alembic sqlalchemy url:
- In
alembic.ini
undersqlalchemy.url
- with .env file with env.py