Skip to content

Django 1.4 Heroku

dlo edited this page Dec 4, 2012 · 6 revisions

Features

Libraries

Includes a requirements.txt with libraries that promote Django best practices, such as:

  • South, for database migrations.
  • Django storages, for support with many file storage backends.
  • Fabric, for easy deployments.
  • Django Devserver, for a great replacement to the built in Django runserver command.
  • Django Debug Toolbar, for an easy to use toolbar with fantastic profiling information.
  • Statictastic, for an easy way to sync static media to your storage backends.

Deployment

$ heroku create
$ heroku config:set APP_ENVIRONMENT=production
$ heroku config:set AWS_ACCESS_KEY_ID=XXX
$ heroku config:set AWS_SECRET_ACCESS_KEY=XXX
$ heroku config:set AWS_STORAGE_BUCKET_NAME=XXX
$ git push heroku master
$ heroku run python manage.py syncmedia

Get started

To start a new Django project called project_name, run the following.

django-admin.py startproject -e md,ngx,ini,Procfile --template=https://github.com/aurorasoftware/django-template/archive/django-1.4-heroku.zip project_name
Clone this wiki locally