Skip to content

thornewolf/yaft

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YAFT - Yet Another FastAPI Template

Setup

Prerequisites

Setup

poetry install
npm i

Env variables:

.env

AUTH0_DOMAIN=...
AUTH0_CLIENT_ID=...
AUTH0_CLIENT_SECRET=...
DATABASE_URL=...
DATABASE_URL_PROD=...
ENV=dev

Database Management

Whenever you change the schema, run the following commands to migrate the databse. Be sure your env variables are set.

just revision $env # where $env is dev or prod
# THIS
just upgrade $env
# OR
just upgrade-all

Launching the server and css env (needs two terminals)

just css
just post && just run

Going to Production

just up

References

Misc Commands

poetry run alembic init alembic
poetry run python -m unittest

Educational Resources

For providing CLI arguments to alembic: https://gist.github.com/twolfson/4bc5813b022178bd7034

About

yet another fastapi template

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages