SETUP.md 1.31 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60
SETUP
=====

This describes how to setup the nnmon dev environment

Install the base dependencies
-----------------------------

Install the following packages:

    sudo aptitude install python-sqlite python-ooolib

Install the base python virtualenv tools:

    sudo apt-get install python-setuptools
    sudo pip install virtualenv
    sudo pip install virtualenvwrapper


You don't use the virtualenv/virtualenvwrapper tools yet
--------------------------------------------------------

Create a directory to hold the virtual environments:

    mkdir ~/.virtualenvs

Add to your .bashrc (or equivalent) the following lines:

    export WORKON_HOME=$HOME'/.virtualenvs'
    source /usr/local/bin/virtualenvwrapper.sh

Then run the following command:

    source ~/.bashrc

This will end up creating (relatively large) folders in ~/.virtualenvs
where all the projet dependencies will be installed.


Setup your virtual environment
-----------------------------

Create the virtualenv for nnmon and workon it:

    mkvirtualenv --system-site-packages --distribute nnmon

Install nnmon's depdendencies:

    pip install -r pip-requirements.txt


Run the server
--------------

    cd ../nnmon
    python manage.py syncdb # run the database migrations
    python manage.py runserver 8080

Your application is available on http://localhost:8080/