• Djeroku

    Django + Heroku, the easy way

  • A Django project template to jumpstart your next Heroku deployment

  • Djeroku glues together a full suite of free Heroku addons, with all the tools, settings, and configuration to get them working together correctly


What It Is

  • A Bag of Tricks

    Djeroku is the amalgamation of all the tips and tweaks I've gathered while doing Django development on Heroku. If you have developed a few sites and have them working on Heroku, 95% of this won't be a surprise since you will have already solved all the same issues, most likely through substantial quantities of your blood, sweat, and/or tears.

    If you are just starting to play with Django or you haven't designed a site from the ground up with scalability in mind, Djeroku (or any of several other great options) is a great starting point so you are set up correctly from the beginning. Django can do so many things that sometimes just figuring out where to start can be a giant barrier to entry.

  • An Open Project Template

    Using Djeroku is as simple as creating a new Django project and app(s) using the Djeroku layout as a template (follow the readme). When done correctly, you get a working development deployment with all the settings and configuration you need to immediately get started. Then, when you're ready, Djeroku includes tools to create duplicate staging and production apps on Heroku, fully loaded with free addons, and ready for deployment.

    Djeroku itself is MIT licensed and all the tools it glues together are available for commercial use, so you never need to change your development tools if you change between commercial and non-commercial projects.

  • Simple

    Be aware: Djeroku is meant to do one thing and there is nothing tricky about how it works. You can easily tweak and change things as you desire, but the goal is to get a Django webapp up and running as quickly as possible with the end goal of deploying through Heroku. You can, of course, do whatever you want, but the tools are all geared toward that end and make that exact process extremely easy.

    Most importantly, there are a TON of things that are simply my preference - take everything with a big grain of salt and *never* assume I know more than you.


What It Isn't

  • Not Magic

    Djeroku isn't magic. In fact, it is just a Django project template with all the settings already filled out and working, plus a couple tools to ease the process of deploying on Heroku.

  • Not College

    Djeroku does not let you 'make a website without being a developer', nor can it teach you to code. Djeroku is for developers -- it can show you where to begin if you're new, but it is your responsibility to build everything correctly.

  • Not A Nanny

    Djeroku doesn't protect you from yourself or anyone else. It can get your next project started in a flash, but after that you're on your own.


  • Heroku Setup Script

    A Fabric script that sets everything up correctly on Heroku, including duplicate staging and production environments and a deployment pipeline between them.

  • Development Vs Production

    On Production, Djeroku uses (and configures) several Heroku addons to provide the services needed for a scalable production app. On Development, Djeroku replaces them with simple local alternatives with the same interfaces so your code works exactly the same in both places.

  • Dependencies and Configuration

    Djeroku glues together a bunch of libraries and Heroku addons with working configuration and uses pip requirement files to isolate and control their installation.

    All sensitive and account related configuration data is stored in Environment Variables, both for easy modification and to keep your credentials out of your codebase.

  • Under the Hood

    • Web Server: Gunicorn + GEvent
    • Database: Heroku Postgres
    • Caching: Memcache Addons
    • Queue and Workers: Celery
    • Outgoing Mail: Mandrill or Gmail
    • In-Memory Datastore: Redis
    • Monitoring: NewRelic and PaperTrail