Welcome to Django template’s documentation!
django-template is a project template based on Django and Django Rest Framework with Docker. Everything what you will need for develop included here.
5 minutes and you will be ready for develop new projects!
Features:
Based on Python 3.9 (will be updated to 3.10 soon)
Docker-compose environment
Celery integration
Nginx and support SSL (TLS) certificates for https connections (Support http2 protocol)
CI/CD integrations for Github and Gitlab repositories.
Swagger “out-of-box” for OpenApi
And a lot of another features wait for you!
Quick start!
This guide helps to install and run new projects.
Requirements
Docker with docker-compose
Usage
# Clone the repository
$ git clone https://github.com/bandirom/django-template.git ./project_name
Before start let’s set up superuser email and password (not username)
Open the project in your favorite IDE and edit docker/prod/env/.data.env file.
Set up variables for superuser:
SUPERUSER_EMAIL=example@email.com
SUPERUSER_PASSWORD=secretpassword
PROJECT_TITLE=MyProject
Run the local project with command:
$ docker-compose up -d --build
Note
You can run project without -d (detach) flag, if you don’t need to run server everytime
Note
Project will bind 8000 port on your machine. If you wanna change it, you can do it in docker-compose.yml in service web
Let’s check the logs of containers (Only if you use (-d) flag):
$ docker-compose logs -f
And visit http://localhost:8000.
ChangeLog
1.0.0
docker and docker-compose support.