Setting up a Django project - TwoGears/hakomo-guides GitHub Wiki

Installing from scratch (on MAC)

  • [TODO]

Setting up an existing project (on MAC)

  • Requirements:

    • python > 2.6
    • pip (python package manager): install
    • virtualenv (makes isolated python environments): $ pip install virtualenv
    • PostgreSQL install, pgAdmin3
  • Setup:

    • Make a folder in www with a name: project-nameDEV and cd into the new folder
    • make a virtual environment for the project: $ virtualenv venv
    • activate it: $ source venv/bin/activate
    • clone the project repo $ git clone project-name and cd into the new folder
    • install project requirements: $ pip install -r requirements.txt
    • create a database: $ createdb DATABASE-NAME --owner=YOUR-OSX-USERNAME
    • migrate the database: $ python manage.py migrate
    • run the server: $ python manage.py runserver