Simple quickstart for Django-based projects created as cookiecutter template.
- Exception handling (
ProblemDetailException,ValidationExceptionprepared for django_api_forms) - Basic security (signature middleware, Argon password hasher)
- Hard/soft delete for models
- Custom
Usermodel - Response objects (
SingleResponse,ValidationResponse) - pydantic response serialisation
- Custom JSON encoder
- Configuration using
.envfiles - Sentry integration
- Dependency management using poetry
- Multi-environment settings
- E-mail testing using django-imap-backend in
developmentenvironment - CRON job management
- django_api_forms: Request validation
- python-dotenv:
.envhandling - porcupine-python: Response serialisation
- django-imap-backend: Custom e-mail backend for simplified testing
- django-celery-beat: CRON jobs
You need to have installed cookiecutter in your system, then you can call. You will be asked a few questions about the new project (name, target directory):
cookiecutter gh:backbonesk/django-project-template- Check
pyproject.tomland change theauthorslist cd {{ directory_name }}python -m venv venvpoetry install && poetry update- Remove stuff you don't need (template is feature rich on purpose, it's easier to delete than create)
- Call
python manage.py makemigrationsand thenpython manage.py migrate - You are supposed to create superuser using
python manage.py createsuperuser - When the project is set up, you can call
{baseurl}/statusto check if everything is up and running - Take a coffee and celebrate life, you saved a plenty of time!
Made with ❤️ and ☕️ BACKBONE s.r.o. (c) 2024