Django Template
A Template for production-ready django-based applications
Featuring:
- Django 3.0
- Container runtime
- Unit (django-test) and Integration (Behave) Tests
- Package auditing via safety and security linting with bandit
- Static linting with flake8 and mypy
- Test and deployment to pipy pipelines via github actions
- Coverage reporting
- Development and Production settings
Table of Contents:
Installation:
Requisites:
- Install docker and docker-compose
Clone:
- Clone this repository:
git clone git@github.com:claudinoac/django-template
Setup:
-
Build and run container:
$ docker-compose up -d server
-
Access http://localhost:3000
-
You're ready to develop your own application
Architecture:
To create an app from our template, run inside the apps
folder:
$ django-admin startapp --template app_template.zip [app_name]
Testing:
Unit tests:
-
The unit tests are based on Django test suite
-
All the unit tests should be located in apps/app_name/tests/unit/
-
To run the unit tests, run
$ make run-unit-tests
Integration tests
-
The integration tests are based on Behave BDD Testing
-
All the integration tests should be located in apps/app_name/tests/integration
-
Every integration test has two parts: the .feature and the .py (steps) file
- For details, check the behave's documentation
-
To run the integration tests, run
$ make run-integration-tests
Contributing
To get started...
Step 1
-
Option 1
-
🍴 Fork this repo!
-
-
Option 2
-
👯 Clone this repo to your local machine usinghttps://github.com/claudinoac/django-template.git
-
Step 2
-
HACK AWAY!
🔨 🔨 🔨
Step 3
-
🔃 Create a new pull request usinghttps://github.com/claudinoac/django-template/compare/
.
Team
Maintainers:
Alisson Claudino |
---|
github.com/claudinoac |
Contributors:
FAQ
-
How can I change my configs?
- In the django_template/project/settings/(development|production).py
Support
Reach out to me at one of the following places!
- Twitter at
@_claudinoac