(Original script https://github.com/henriquebastos/django-quickstart )
Adjusted to better fit my initial setup
This template includes:
- .env setup with Decouple
- Pytest and pytest-django
- Docker and docker-compose base files
- Static assets serving with dj-static (WSGI server)
- Jazzmin for django admin template
- Django extensions for
python manage.py shell_plusenvironment - Quick deployment of multiple apps with SSL on AWS using Nginx (more details at https://github.com/GuiFV/multiple_django_apps_nginx_orchestration )
- Copy and paste the code below in your terminal
- Hit 'Enter'
- Type in your project's name (only letters and numbers)
- Hit 'Enter'
read PROJECT_NAME && \
mkdir $PROJECT_NAME && \
cd $PROJECT_NAME && \
python3 -m venv .venv && \
source .venv/bin/activate && \
python3 -m pip install --upgrade pip && \
python3 -m pip install django && \
django-admin startproject --template https://github.com/GuiFV/django-quickstart/archive/master.zip --name=.env,pytest.ini $PROJECT_NAME . && \
pip3 install --prefer-binary -r requirements-dev.txt && \
git init && \
git add . && \
git commit -m 'Initial import'
- Change SECRET_KEY in .env (you can use https://djecrety.ir/)
- Create a repo
- Set it up locally using
git remote add origin https://github.com/YOURNAME/REPO_CREATED/ - git push to your new repo
- Happy coding :)