sobirjonovme / kindergarten_ms

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Django boilerplate

How to set up project

How to run project locally bash script (Linux, Mac)

install requirements

python3 -m venv env
source env/bin/activate
pip install -r requirements/develop.text

create .env file

cp .env.example .env

create database

sudo -u postgres psql
CREATE DATABASE django_boilerplate;
CREATE USER django_boilerplate WITH PASSWORD 'django_boilerplate';
ALTER ROLE django_boilerplate SET client_encoding TO 'utf8';
ALTER ROLE django_boilerplate SET default_transaction_isolation TO 'read committed';
ALTER ROLE django_boilerplate SET timezone TO 'UTC';
GRANT ALL PRIVILEGES ON DATABASE django_boilerplate TO django_boilerplate;
\q

set up .env file with your database credentials

nano .env

run migrations

python manage.py migrate

run server

python manage.py runserver

Pre-commit must be installed for all projects

pip install pre-commit
pre-commit install

About


Languages

Language:Python 99.1%Language:Dockerfile 0.7%Language:Shell 0.2%