Deploying Django Apps on Dreamhost

The Dreamhost wiki article on Django helped, but all the steps starting from scratch aren't really documented in one place. Hopefully the list below will help, but since I'm writing it after the fact and I had to go through a couple of iterations to get it right, there are probably some things that aren't 100% right.

  1. Read the python article. Set up virtualenv into $HOME/local.
  2. If you've already messed around with installing MySQLdb and/or other packages, remove them and start over.
  3. Install ez_setup (easy_install) as describe in the article.
  4. Install the MySQL egg: easy_install MySQL_python
  5. Follow the setup steps in the Django article. Do the "myproject" test using sqlite3. Really. It helped me find a couple of things I was doing wrong with my real (i.e. more complicated) MySQL project.
  6. As a deviation from the Django setup instructions, I prefer to use a fork of the Django codebase with some of my own patches. If you're in the same situation, use github. I forked the github "unofficial copy" of the subversion code, added a couple of patches that aren't in the trunk yet and a couple of my own, and cloned a copy into my dreamhost account.

Posted on 2009-02-03 by brian in django .

Comments

Thanks for the article but the first question that springs to mind is: why would you bother?

WebFaction ( http://www.webfaction.com ) is a much faster hosting provider than DreamHost (because they don't oversell like DreamHost does) and they have the best support for Django!

Steve
2009-02-06 09:45:15

Steve -

Thanks for the suggestion.

I looked at Webfaction in comparison to Dreamhost. Dreamhost won mainly on cost -- $97 off coupon means it cost about $30 for a year, which makes it ridiculously cheap to get started. So if I need to "upgrade" to Webfaction in a couple of months it will just cost me a few hours to make the switch.

Stay tuned, I'll let you know how it goes...

-Brian

Brian St. Pierre
2009-02-06 13:13:42
Comments on this post are closed. If you have something to share, please send me email.