A practical starting point for Django projects with a modern frontend build.
- Python 3.13 with uv for backend dependencies
- Django 5.2 LTS as the web framework
- Node.js 25 with Vite for asset pipeline (integrated via django-vite)
- ESLint and Ruff for linting
- Sass for styles
- Gunicorn for production WSGI serving
- django-axes for login throttling
-
Create a new project from the template
django-admin startproject project_name --template=https://github.com/1vank1n/django-project-template/archive/master.zip -
Install Python and Node dependencies
make deps -
Adjust environment variables
.env.template→.env -
Apply migrations and run development servers
uv run python manage.py migrate uv run python manage.py runserver # backend pnpm dev # Vite dev server with HMR
- Set production values in
.env(disableDEBUG, setSECRET_KEY, configureDATABASE_URL, tuneGUNICORN_*) - Run
make deploy— builds image, starts container, applies migrations, collects static
Static and media files are served from local static/ and media/ by default.
To offload them to S3-compatible storage (AWS S3, MinIO, Cloudflare R2, Backblaze B2, etc.),
set AWS_STORAGE_BUCKET_NAME in .env — everything else switches automatically.
Minimal .env for S3:
AWS_STORAGE_BUCKET_NAME=my-bucket
AWS_ACCESS_KEY_ID=...
AWS_SECRET_ACCESS_KEY=...
AWS_S3_REGION_NAME=us-east-1
# AWS_S3_ENDPOINT_URL=https://<minio-or-r2-endpoint>/ # only for S3-compatible
# AWS_S3_CUSTOM_DOMAIN=cdn.example.com # only for public CDN
If AWS_STORAGE_BUCKET_NAME is empty — Django falls back to local filesystem.
applications/ Django apps (core, main)
frontend/ source frontend files (images, scripts, styles)
settings/ Django project settings (split-settings components)
templates/ Django templates
static/ compiled static assets (generated by Vite)
logs/ runtime logs
gunicorn.conf.py Gunicorn configuration (reads GUNICORN_* env vars)
vite.config.js Vite configuration
.editorconfig– editor formatting ruleseslint.config.js– ESLint rules (flat config).gitignore– files ignored by Git.dockerignore– files excluded from Docker build context.nvmrc– Node.js version for nvm.python-version– Python version for pyenv.env.template– default environment variables for local development
MIT — see LICENSE. Use it freely in commercial and open-source projects.
Questions? Create an issue or email lukyanets.ivan@gmail.com