- Clone repo:
git clone https://github.com/dlyapun/django_skeleton.git
- Enter to repo:
cd django_skeleton
- Create virtual environment:
virtualenv -p python3 venv
. - Activate virtual environment:
source venv/bin/activate
. - Install requirements:
pip3 install -r requirements.txt
. - Run migrations:
python3 manage.py migrate
. - Run server:
python3 manage.py runserver
.
import os
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
}
}
DEBUG = True
EMAIL_BACKEND = 'django.core.mail.backends.filebased.EmailBackend'
EMAIL_FILE_PATH = 'tmp/email-messages/'