Building Django Environment on Mac OSX

As I am moving to the new MacBook Pro that just arrived yesterday, I’m rebuilding development environment from scratch on the new machine rather than inheriting it with legacy setups.

Here’s the good reference for such task
Mac OSX — Installing a fresh Django environment with Homebrew, Git, and Virutualenv

Some of the information is outdated, so let me update them to the latest as of July 22, 2012.

1. Install Homebrew
Homebrew (its command is “brew”) is the package management system for Mac OSX. That helps manage available package list, and, upon your command, download and build for your environment as installation process. The command below follows the installation guide on the official site.

2. Install Git

3. Install pip
pip is the more powerful tool than the old easy_install tool.

4. Install virtualenv
Now it’s time to install virtualenv with pip. Virtualenv allows the independent sandbox development environment without messing up the workstation configuration. If you don’t want to having an issue by changing lots of machine’s configuration files, this is the solution for you.

Install virtualenvwrapper for convenience.

So now you’ve got virtualenv ready, it’s time to set up your sandbox environment and proceed to the rest of Django installation.

6 thoughts on “Building Django Environment on Mac OSX

  1. Pingback: pybrew – python’s homebrew tool | Sweet Remedy

  2. Christopher Niven

    I am very new to Django and have been using basic Python skills to modify an existing web hosted application. While You’re update to the July 2010 article is most welcome. Thank you.

    Do you have additional directions to setup the sandbox and proceed with the rest of the Django operation?

    I am in the midst of considering a brew/virtualenv vs. a bitnami Django stack. In either case I will be installing a local version of MySQL as well.

    I am running mac OS X 10.7.4 and not planning on moving to Mountain Lion anytime soon.

    Again, thank you.

  3. Pingback: Building Django developing environment on Mac OSX (2/2) // Sweet Remedy

  4. ryokamiya Post author

    Hi Christopher, here I just posted the rest of installation. Hope this helps!

    brew/virtualenv vs cloudhosting (e.g. bitnami) – isn’t that the best way could be you can develop with brew/virtualenv in your local machine, and deploy to cloud hosting (but of course no virtualenv layer)?
    You wouldn’t need separation of environment in production as you rather want the deployment reflected at the whole environment.

  5. Pingback: Virtual Environment for Django / Python Development on Mac OS-X - How to, What to and Why » The Jackal Adventures

Leave a Reply

Your email address will not be published. Required fields are marked *