This app implements a simple post app using Flask.
It demonstrates the following features:
- Account Mangement
- Authentication via OAuth2 (Google, Github)
- Authorization with roles (admin / member)
- Database using SQLAlchemy and PostgreSQL
- Email and other async tasks via Celery
- Stripe charge and subscriptions
The project structure leverages Flask blueprints.
To enable a smooth development process, everything is docker / docker-compose based.
To start the application and view on localhost:5050
make build
make bootstrap
To run flask commands, first start the flask shell with
make shell
Once in the shell, you can run scripts from /scripts/fake.py
to insert test users and posts into the database.
The post app and account management structure is based on the Flask Mega Tutorial and the associated book.
The stripe subscription is based on Build a SaaS App but modified majorly to use the official stripe javascript (example from Pretty Printed tutorial) vs. implementing credit card pages from scratch.