An utterly fantastic project starter template for Django 1.7.
- Production-ready configuration for Static Files, Database Settings, Gunicorn, etc.
- Enhancements to Django's static file serving functionality via WhiteNoise
- Enhancements to Django's database functionality via django-postgrespool and dj-database-url
To use this project, follow these steps:
- Create and enter a new project directory.
- Create a working environment.
- Create your new project using this template.
$ django-admin.py startproject {{ project_name }} . --template=http://joseph.is/on-a-deadline --name=.env,Procfile,README.md
$ createdb {{ project_name }}
$ pip install -r requirements.txt
$ foreman run python manage.py collectstatic
$ foreman run python manage.py migrate
$ foreman start
$ open http://localhost:5000
$ git init
$ git add -A
$ git commit -m "Initial commit"
$ heroku create foo
$ heroku config:set ALLOWED_HOSTS=foo.herokuapp.com
$ heroku config:set DEBUG=off
$ heroku config:set SECRET_KEY=bar
$ git push heroku master
$ heroku run python manage.py migrate
You can replace foo
with your desired Heroku app name and bar
with your production secret key.