summaryrefslogtreecommitdiff
path: root/README.rst
blob: 2bf28f4ccdc48a30334f71c6f9813eb6d3ad10de (plain)
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
=================================
Radio Helsinki Program Management
=================================

Installation
============

To get setup you must have the following installed:

 * MySQL-Client Development libraries 
 * JPEG library development files
 * Python 2.7 including Development files
 * virtualenv 1.11

In Debian or Ubuntu (or derivatives) you should be able to achieve this with this command:

    $ sudo apt-get install libmysqlclient-dev libjpeg-dev python2.7-dev virtualenv


Setting up the environment
--------------------------

Create a virtual environment where the dependencies will live::

    $ virtualenv -p python2.7 python
    $ source python/bin/activate
    (python)$

Change into the base directory of this software and install the project dependencies::

    (python)$ pip install -r requirements.txt


Setting up the database
-----------------------

By default the project is set up to run on a SQLite database.  

First edit pv/settings.py and change the line 
    SECRET_KEY = ''
such that there is a value for SECRET_KEY.

Then run::

    (python)$ python manage.py migrate
    (python)$ python manage.py loaddata program/fixtures/*.yaml


Running a web server
--------------------

In development you should run::

    (python)$ python manage.py runserver