Django tutorial integrating TailwindCSS, Postgres, Stripe API, User auth, deployment, & more.
- stars
- 354
- watchers
- 15
- forks
- 192
- open issues
- 3
- Last updated
- 09/03/2025
Django tutorial integrating TailwindCSS, Postgres, Stripe API, User auth, deployment, & more.
Build the foundations for a Software as a Service business by leveraging Django, Tailwind, htmx, Neon Postgres, Redis, and more.
The goal of this project is to learn how to create a reusable foundation for building SaaS products. When release, this course will span multiple topics and give you a solid foundation into build your business.
mkdir -p ~/dev/saas cd ~/dev/saas git clone https://github.com/codingforentrepreneurs/SaaS-Foundations .
macOS/Linux
python3 --version # should be 3.11 or higher python3 -m venv venv source venv/bin/activate
Windows
c:\Python312\python.exe -m venv venv .\venv\Scripts\activate
Rav is a simple way to run commands and download static files (css, images, js, etc) from external sources.
# with venv activated
pip install pip rav --upgrade
rav run installUse
python -m rav run installif for some reasonravis not in your path.
cp .env.sample .env cat .env
Values include:
DJANGO_DEBUG=1DJANGO_SECRET_KEY=""DATABASE_URL=""EMAIL_HOST="smtp.gmail.com"EMAIL_PORT="587"EMAIL_USE_TLS=TrueEMAIL_USE_SSL=FalseEMAIL_HOST_USER=""EMAIL_HOST_PASSWORD=""ADMIN_USER_EMAIL=""STRIPE_SECRET_KEY=""python -c 'from django.core.management.utils import get_random_secret_key; print(get_random_secret_key())'or
openssl rand -base64 64
or
python -c 'import secrets; print(secrets.token_urlsafe(64))'Once you have this value, add update DJANGO_SECRET_KEY in .env.
source venv/bin/activate # or .\venv\Scripts\activate if windows cd src python manage.py migrate
python manage.py createsuperuser
python manage.py vendor_pull
.env) with the value STRIPE_SECRET_KEY with your key.python manage.py runserver
Ready to roll! 🚀
Review the rav.yaml (or rav documentation) for available command shortcuts, here are some useful ones:
rav run install - Install requirements based on scripts.installrav run install_dev - Install requirements for developmentrav run makemigrations - Make migrationsrav run migrate - Run migrationsrav run dev - Run the development serverrav run test - Run the testsrav run vendors_pull - Download vendor static filesrav run collectstatic - Collect static filesrav download staticfiles_prod - Download vendor static files for productionrav download staticfiles_dev - Download vendor static files for development