root / README @ 7d52c0b4
History | View | Annotate | Download (2 kB)
1 |
Synnefo |
---|---|
2 |
======= |
3 |
|
4 |
Installation |
5 |
------------ |
6 |
$ sudo easy_install virtualenv |
7 |
.... |
8 |
$ git clone https://user@code.grnet.gr/git/synnefo synnefo |
9 |
$ virtualenv --python=python2.6 synnefo --no-site-packages |
10 |
... |
11 |
$ cd synnefo |
12 |
$ ./bin/pip install django django-piston pycurl simplejson selenium pyzmq-static |
13 |
... |
14 |
... |
15 |
$ cp settings.py.dist settings.py |
16 |
$ ./bin/python manage.py syncdb |
17 |
$ cd db |
18 |
$ ../bin/python db_controller.py |
19 |
... |
20 |
$ cd synnefo |
21 |
$ ./bin/python manage.py runserver |
22 |
|
23 |
Notes |
24 |
------ |
25 |
1) On ubuntu systems: |
26 |
sudo aptitude install libcurl3-gnutls libcurl3-gnutls-dev |
27 |
|
28 |
2) jQuery.ajax POST is not working unless you edit lib/python2.6/site-packages/piston/utils.py. |
29 |
On def content_type change: |
30 |
ctype = self.request.META.get('CONTENT_TYPE', type_formencoded) |
31 |
to |
32 |
ctype = self.request.META.get('CONTENT_TYPE', type_formencoded).split(";")[0] |
33 |
|
34 |
3) On Ubuntu 10.04 (tested by mgogoulos) you'll have to install zmq-static with: |
35 |
sudo aptitude install uuid-dev |
36 |
./bin/pip install pyzmq-static |
37 |
|
38 |
4) Also see README.DB, which describes setting up a DB with various backends. |
39 |
|
40 |
5) The checkout directory name "synnefo" is mandatory |
41 |
|
42 |
6) In Mac computers with Snow Leopard, you may have a problem installing pycurl. Remember to set 64-bit arch when you install it. |
43 |
|
44 |
env ARCHFLAGS="-arch x86_64" ./bin/pip install pycurl |
45 |
|
46 |
|
47 |
Testing |
48 |
------- |
49 |
The functional ui tests require the Selenium server and the synnefo app to be running. |
50 |
|
51 |
$ wget http://selenium.googlecode.com/files/selenium-server-standalone-2.0b2.jar |
52 |
$ java -jar selenium-server-standalone-2.0b2.jar & |
53 |
$ ./bin/python manage.py runserver & |
54 |
$ ./bin/python manage.py test ui |
55 |
|
56 |
Test coverage |
57 |
============= |
58 |
|
59 |
In order to get code coverage reports you need to install django-test-coverage |
60 |
|
61 |
$ ./bin/pip install django-test-coverage |
62 |
|
63 |
Then edit your settings.py and configure the test runner: |
64 |
|
65 |
TEST_RUNNER = 'django-test-coverage.runner.run_tests' |