Project Installation

Version 241 (Etienne Pallier, 09/29/2016 11:28 am)

1 1 Etienne Pallier
h1. Project Installation
2 1 Etienne Pallier
3 6 Etienne Pallier
4 189 Etienne Pallier
This page describes the installation phase of the Pyros software
5 189 Etienne Pallier
6 189 Etienne Pallier
7 11 Etienne Pallier
Project Development page : [[Project Development]]
8 11 Etienne Pallier
9 6 Etienne Pallier
HOWTO Format Redmine Wiki : http://www.redmine.org/projects/redmine/wiki/FrRedmineWikiFormatting
10 6 Etienne Pallier
11 193 Etienne Pallier
{{toc}}
12 6 Etienne Pallier
13 6 Etienne Pallier
14 3 Etienne Pallier
---
15 3 Etienne Pallier
16 170 Etienne Pallier
---
17 170 Etienne Pallier
18 221 Etienne Pallier
h2. %{margin-left:0px; font-weight:bold; font-size:25px;  display:block; color:red;}DATABASE SCHEMA (v0.2.2)%
19 4 Etienne Pallier
20 4 Etienne Pallier
21 222 Etienne Pallier
{{thumbnail(PYROS_DBM_V0_2_2.png, size=2000, title=Pyros data model)}}
22 4 Etienne Pallier
23 4 Etienne Pallier
24 4 Etienne Pallier
---
25 5 Etienne Pallier
26 170 Etienne Pallier
---
27 170 Etienne Pallier
28 226 Etienne Pallier
h2. %{margin-left:0px; font-weight:bold; font-size:25px;  display:block; color:red;}COMPATIBLE PLATFORMS (TESTED)%
29 226 Etienne Pallier
30 227 Etienne Pallier
This software is targetted first for Linux CentOS 7 (+ Fedora and Ubuntu), but also for Mac OS X and Windows 10.
31 231 Etienne Pallier
All these systems should run Python 3 (3.5+)
32 226 Etienne Pallier
33 227 Etienne Pallier
Pyros has been tested on these platforms:
34 226 Etienne Pallier
35 232 Etienne Pallier
* CentOS 7.1 (with Python 3.4)
36 235 Paul Carensac
* Linux Mint 17.2 ( == Ubuntu 14.04.3) (with Python 3.5)
37 232 Etienne Pallier
* Mac OS 10.11.6 (with Python 3.5)
38 232 Etienne Pallier
* Windows 10 (with Python 3.5)
39 226 Etienne Pallier
40 177 Etienne Pallier
h2. %{margin-left:0px; font-weight:bold; font-size:25px;  display:block; color:red;}I - PREREQUISITES%
41 177 Etienne Pallier
42 181 Paul Carensac
Pyros needs some prerequisites : 
43 177 Etienne Pallier
44 229 Etienne Pallier
* Python 3.5+
45 181 Paul Carensac
* RabbitMQ
46 220 Etienne Pallier
* [optional] a Mysql Database server (but you can use Sqlite instead, with no installation)
47 177 Etienne Pallier
48 177 Etienne Pallier
49 177 Etienne Pallier
---
50 177 Etienne Pallier
51 230 Etienne Pallier
h3. Install Python3 (3.5+) + pip + virtualenv (only if necessary)
52 177 Etienne Pallier
53 177 Etienne Pallier
_If Python 3 is already installed on your computer, skip this section_
54 177 Etienne Pallier
55 177 Etienne Pallier
56 177 Etienne Pallier
 * Linux (CentOS 7.1, main target): (python35 not yet available as rpm)
57 177 Etienne Pallier
<pre>
58 177 Etienne Pallier
$ sudo yum update yum
59 177 Etienne Pallier
$ sudo yum update kernel
60 177 Etienne Pallier
$ sudo yum update
61 1 Etienne Pallier
62 1 Etienne Pallier
$ sudo yum install python34
63 1 Etienne Pallier
$ python3.4 -V
64 1 Etienne Pallier
Python 3.4.3
65 1 Etienne Pallier
66 1 Etienne Pallier
$ sudo yum install python34-devel
67 1 Etienne Pallier
(needed for python package mysqlclient)
68 1 Etienne Pallier
69 1 Etienne Pallier
$ sudo yum update python-setuptools
70 1 Etienne Pallier
$ easy_install --version
71 1 Etienne Pallier
setuptools 0.9.8
72 1 Etienne Pallier
$ sudo easy_install pip
73 1 Etienne Pallier
$ pip --version
74 1 Etienne Pallier
pip 8.1.1 from /usr/lib/python2.7/site-packages/pip-8.1.1-py2.7.egg (python 2.7)
75 1 Etienne Pallier
76 1 Etienne Pallier
$ sudo pip install virtualenv
77 1 Etienne Pallier
$ virtualenv --version
78 1 Etienne Pallier
15.0.1
79 1 Etienne Pallier
80 1 Etienne Pallier
Necessary for "lxml" python package:
81 1 Etienne Pallier
$ sudo yum install libxml2 libxml2-devel
82 1 Etienne Pallier
$ sudo yum install libxslt libxslt-devel
83 1 Etienne Pallier
84 1 Etienne Pallier
</pre>
85 1 Etienne Pallier
86 1 Etienne Pallier
87 1 Etienne Pallier
 * Linux (Ubuntu) :
88 1 Etienne Pallier
<pre>
89 1 Etienne Pallier
$ sudo add-apt-repository ppa:fkrull/deadsnakes
90 1 Etienne Pallier
$ sudo apt-get update
91 1 Etienne Pallier
$ sudo apt-get install python3.5
92 237 Jeremy Barneron
$ sudo apt-get install libxml2-dev
93 237 Jeremy Barneron
$ sudo apt-get install libxslt-dev
94 1 Etienne Pallier
95 1 Etienne Pallier
$ sudo apt-get install python3.5-dev
96 1 Etienne Pallier
(needed for python package mysqlclient)
97 1 Etienne Pallier
98 1 Etienne Pallier
$ sudo pip install virtualenv
99 1 Etienne Pallier
</pre>
100 1 Etienne Pallier
101 1 Etienne Pallier
102 1 Etienne Pallier
 * Mac OS X :
103 1 Etienne Pallier
104 1 Etienne Pallier
  * From binary (Mac OS native application)
105 1 Etienne Pallier
(TODO:)
106 1 Etienne Pallier
107 1 Etienne Pallier
  * From MacPort
108 1 Etienne Pallier
109 1 Etienne Pallier
   * a) install macport
110 208 Etienne Pallier
cf https://www.macports.org/install.php
111 1 Etienne Pallier
112 1 Etienne Pallier
   * b) install the "port" python35
113 1 Etienne Pallier
<pre>
114 1 Etienne Pallier
$ sudo port install python35
115 1 Etienne Pallier
</pre>
116 1 Etienne Pallier
117 1 Etienne Pallier
118 202 Paul Carensac
 * Windows (tested with Windows 7 & 10) :
119 1 Etienne Pallier
<pre>
120 1 Etienne Pallier
Go to https://www.python.org/downloads/windows/ , choose the wanted version
121 1 Etienne Pallier
On the wanted version’s page, download Windows x86 executable installer
122 1 Etienne Pallier
123 1 Etienne Pallier
Run the executable
124 1 Etienne Pallier
    * On the first page, check "Add python3.5 to PATH"
125 1 Etienne Pallier
    * Choose "Install now" option
126 1 Etienne Pallier
127 1 Etienne Pallier
Open cmd (windows + R, cmd) :
128 1 Etienne Pallier
 $ python -m pip install --upgrade pip
129 1 Etienne Pallier
 $ pip install virtualenv
130 1 Etienne Pallier
</pre>
131 200 Paul Carensac
132 200 Paul Carensac
---
133 200 Paul Carensac
134 200 Paul Carensac
h3. Install a database server (only if necessary)
135 200 Paul Carensac
136 200 Paul Carensac
_If the MySql database server is already installed on your computer, skip this section_
137 200 Paul Carensac
138 200 Paul Carensac
By default, Pyros uses Mysql, but this implies that you have to install the Mysql database server...
139 200 Paul Carensac
140 200 Paul Carensac
Thus, to make things easier, avoid Mysql installation by using Sqlite instead as the database server (which will need no installation at all) :
141 200 Paul Carensac
142 200 Paul Carensac
=> *For this, just edit the file PYROS/src/pyros/settings.py and set MYSQL variable to False, and that's it. You can go to next section*
143 200 Paul Carensac
144 200 Paul Carensac
Now, if you really want to use Mysql (which is the default), you will need to install it (only if not already installed), so keep reading.
145 200 Paul Carensac
146 200 Paul Carensac
_(Skip this if you are using Sqlite instead of MySql)_
147 200 Paul Carensac
148 200 Paul Carensac
 * Linux Ubuntu
149 200 Paul Carensac
<pre>
150 200 Paul Carensac
First, update your system:
151 200 Paul Carensac
$ sudo apt-get update
152 200 Paul Carensac
153 200 Paul Carensac
$ sudo apt-get install mysql-server
154 200 Paul Carensac
$ sudo apt-get install mysql-client
155 200 Paul Carensac
156 200 Paul Carensac
$ sudo apt-get install libmysqlclient-dev
157 200 Paul Carensac
(needed for python package mysqlclient)
158 200 Paul Carensac
</pre>
159 200 Paul Carensac
160 200 Paul Carensac
 * Linux CentOS : cf https://www.howtoforge.com/apache_php_mysql_on_centos_7_lamp#-installing-mysql-
161 200 Paul Carensac
<pre>
162 200 Paul Carensac
First, update your system:
163 200 Paul Carensac
$ sudo yum update yum
164 200 Paul Carensac
$ sudo yum update kernel
165 200 Paul Carensac
$ sudo yum update
166 200 Paul Carensac
167 200 Paul Carensac
$ sudo yum install mariadb-server 
168 200 Paul Carensac
$ sudo yum install mariadb
169 200 Paul Carensac
170 200 Paul Carensac
$ sudo yum install mariadb-devel
171 200 Paul Carensac
(needed for python package mysqlclient)
172 200 Paul Carensac
173 200 Paul Carensac
$ sudo systemctl start mariadb.service
174 200 Paul Carensac
175 200 Paul Carensac
$ sudo systemctl enable mariadb.service
176 200 Paul Carensac
=> Created symlink from /etc/systemd/system/multi-user.target.wants/mariadb.service to /usr/lib/systemd/system/mariadb.service.
177 200 Paul Carensac
178 200 Paul Carensac
$ sudo mysql_secure_installation
179 200 Paul Carensac
</pre>
180 200 Paul Carensac
181 200 Paul Carensac
 * Mac OS X
182 200 Paul Carensac
Install XAMPP
183 200 Paul Carensac
(but you could also use the pre-installed Mac OS MySql, or install MySql from macport)
184 209 Etienne Pallier
cf https://www.apachefriends.org/fr/index.html
185 209 Etienne Pallier
186 200 Paul Carensac
187 201 Paul Carensac
 * Windows (tested with Windows 7 & 10)
188 200 Paul Carensac
189 200 Paul Carensac
<pre>
190 200 Paul Carensac
Download and install the newest version on https://dev.mysql.com/downloads/installer/
191 200 Paul Carensac
192 200 Paul Carensac
Once installed, launch MySQL Installer. Clic on 'Add...' on the right.
193 200 Paul Carensac
In MySQLServers section, choose the newest, then clic on next.
194 200 Paul Carensac
Install and configure the server (just follow the installation guide).
195 200 Paul Carensac
196 200 Paul Carensac
Then launch mysql (via the Windows menu).
197 200 Paul Carensac
</pre>
198 200 Paul Carensac
199 177 Etienne Pallier
200 1 Etienne Pallier
---
201 181 Paul Carensac
202 181 Paul Carensac
h3. Install RabbitMQ
203 181 Paul Carensac
204 181 Paul Carensac
RabbitMQ is a message queue server used by Celery to handle tasks queues.
205 181 Paul Carensac
206 181 Paul Carensac
 * Ubuntu (the server is automatically started) :
207 181 Paul Carensac
<pre>
208 181 Paul Carensac
$ sudo apt-get install rabbitmq-server
209 181 Paul Carensac
</pre>
210 183 Paul Carensac
211 195 Etienne Pallier
 * CentOS :
212 195 Etienne Pallier
<pre>
213 195 Etienne Pallier
$ sudo yum install rabbitmq-server
214 196 Etienne Pallier
215 196 Etienne Pallier
Installation :
216 196 Etienne Pallier
 rabbitmq-server                                                           noarch                          3.3.5-17.el7
217 196 Etienne Pallier
Installation pour dépendances :
218 196 Etienne Pallier
 erlang-asn1                                                               x86_64                          R16B-03.16.el7
219 195 Etienne Pallier
</pre>
220 195 Etienne Pallier
221 183 Paul Carensac
 * MacOS :
222 183 Paul Carensac
<pre>
223 194 Etienne Pallier
With MacPort:
224 194 Etienne Pallier
$ sudo port install rabbitmq-server
225 194 Etienne Pallier
--->  Installing erlang @18.2.1_1+hipe+ssl
226 194 Etienne Pallier
...
227 194 Etienne Pallier
--->  Installing rabbitmq-server @3.5.7_0
228 194 Etienne Pallier
--->  Activating rabbitmq-server @3.5.7_0
229 194 Etienne Pallier
...
230 183 Paul Carensac
231 240 Etienne Pallier
To start rabbitmq : 
232 240 Etienne Pallier
$ sudo rabbitmq-server
233 240 Etienne Pallier
</pre>
234 240 Etienne Pallier
235 240 Etienne Pallier
236 183 Paul Carensac
 * Windows :
237 191 Paul Carensac
238 191 Paul Carensac
  * Take the wanted Erlang version at http://www.erlang.org/downloads and install it (required)
239 191 Paul Carensac
  * Take the wanted RabbitMQ version at https://www.rabbitmq.com/install-windows.html and install it. Then the server will run automatically
240 191 Paul Carensac
241 191 Paul Carensac
242 177 Etienne Pallier
243 177 Etienne Pallier
---
244 177 Etienne Pallier
245 179 Etienne Pallier
h2. %{margin-left:0px; font-weight:bold; font-size:25px;  display:block; color:red;}II - GET THE PYROS SOFTWARE%
246 5 Etienne Pallier
247 125 Etienne Pallier
h3. Authenticate to https://gitlab.irap.omp.eu/epallier/pyros
248 125 Etienne Pallier
249 125 Etienne Pallier
In order to get this software, you must first authenticate on the IRAP gitlab.
250 125 Etienne Pallier
251 125 Etienne Pallier
For this, just go to https://gitlab.irap.omp.eu/epallier/pyros
252 125 Etienne Pallier
and either sign in with your LDAP account (if you are from IRAP),
253 125 Etienne Pallier
or register via the "Sign up" form.
254 5 Etienne Pallier
255 113 Etienne Pallier
h3. Software structure
256 5 Etienne Pallier
257 207 Paul Carensac
See [[Project_structure|Project Structure]] page.
258 1 Etienne Pallier
259 112 Etienne Pallier
h3. Browse the code (from gitlab)
260 111 Etienne Pallier
261 111 Etienne Pallier
https://gitlab.irap.omp.eu/epallier/pyros/tree/master
262 111 Etienne Pallier
263 203 Paul Carensac
h3. You can download it (static version, not synchronized)
264 111 Etienne Pallier
265 114 Etienne Pallier
You can download the current version of the software.
266 114 Etienne Pallier
267 115 Etienne Pallier
Go to https://gitlab.irap.omp.eu/epallier/pyros/tree/master
268 115 Etienne Pallier
269 115 Etienne Pallier
Click on "Download zip" on the up right hand corner.
270 115 Etienne Pallier
271 115 Etienne Pallier
Double-click on it to unzip it.
272 115 Etienne Pallier
273 115 Etienne Pallier
You should get a "pyros.git" folder.
274 115 Etienne Pallier
275 116 Etienne Pallier
In this documentation, this software folder will be referenced as "PYROS".
276 115 Etienne Pallier
277 118 Etienne Pallier
(you can rename "pyros.git" as "PYROS" if you want : "mv pyros.git PYROS")
278 114 Etienne Pallier
279 203 Paul Carensac
h3. (Windows developers only) : Get git for Windows
280 1 Etienne Pallier
281 203 Paul Carensac
 * Download git at https://git-scm.com/download/win
282 203 Paul Carensac
 * Run setup (keep default configurations)
283 203 Paul Carensac
 * Once installed, open cmd
284 203 Paul Carensac
<pre>
285 203 Paul Carensac
$ git config --global http.sslVerify false
286 203 Paul Carensac
</pre>
287 203 Paul Carensac
288 203 Paul Carensac
You can now use your git from the cmd or the graphic client !
289 203 Paul Carensac
290 203 Paul Carensac
h3. (Developers only) Get it from GIT (dynamic version, synchronized)
291 203 Paul Carensac
292 122 Etienne Pallier
(If you are using Windows, you must first get the git software, see below "Get git for Windows")
293 122 Etienne Pallier
294 114 Etienne Pallier
By getting the software from git, you will get a dynamically synchronized version,
295 114 Etienne Pallier
which means that you will be able to update your version as soon as a new version is available
296 114 Etienne Pallier
(with the command : "git pull").
297 111 Etienne Pallier
298 111 Etienne Pallier
* From Eclipse : See below, section "NOTES FOR ECLIPSE USERS"
299 111 Etienne Pallier
300 111 Etienne Pallier
* From the terminal
301 5 Etienne Pallier
302 5 Etienne Pallier
<pre>
303 5 Etienne Pallier
git clone https://gitlab.irap.omp.eu/epallier/pyros.git PYROS
304 1 Etienne Pallier
</pre>
305 86 Etienne Pallier
306 86 Etienne Pallier
_(or also : git clone git@gitlab.irap.omp.eu:epallier/pyros.git PYROS)_
307 5 Etienne Pallier
308 5 Etienne Pallier
If you ever get this error message :
309 1 Etienne Pallier
<pre>
310 1 Etienne Pallier
fatal: unable to access 'https://gitlab.irap.omp.eu/epallier/pyros.git/': Peer's certificate issuer has been marked as not trusted by the user.
311 122 Etienne Pallier
</pre>
312 122 Etienne Pallier
313 122 Etienne Pallier
Then, type this command (and then run again the git clone command):
314 121 Paul Carensac
<pre>
315 121 Paul Carensac
$ git config --global http.sslVerify false
316 121 Paul Carensac
</pre>
317 121 Paul Carensac
318 1 Etienne Pallier
(Also, the first time you get the project, it will ask you for a login and password)
319 121 Paul Carensac
320 168 Etienne Pallier
This creates a PYROS/ folder containing the project (with a .git/ subfolder for synchronization with the git repository)
321 168 Etienne Pallier
322 168 Etienne Pallier
323 169 Etienne Pallier
324 169 Etienne Pallier
325 169 Etienne Pallier
---
326 169 Etienne Pallier
327 169 Etienne Pallier
---
328 169 Etienne Pallier
329 186 Paul Carensac
h2. %{margin-left:0px; font-weight:bold; font-size:25px;  display:block; color:red;}III - INSTALLATION OF NEEDED PROJECT DEPENDENCIES%
330 166 Etienne Pallier
331 186 Paul Carensac
---
332 186 Paul Carensac
333 186 Paul Carensac
h3. Install Comet
334 186 Paul Carensac
335 214 Etienne Pallier
Comet is needed as a broker to receive and send VOEvents (https://github.com/jdswinbank/Comet/tree/py3)
336 213 Etienne Pallier
*You MUST have your virtualenv activated (source venv_py3_pyros/bin/activate in your 'private/' directory)*
337 1 Etienne Pallier
Documentation is available here : http://comet.readthedocs.io/en/stable/installation.html
338 213 Etienne Pallier
(see also http://voevent.readthedocs.io/en/latest/setup.html)
339 186 Paul Carensac
340 212 Etienne Pallier
* Ubuntu :
341 186 Paul Carensac
342 186 Paul Carensac
<pre>
343 186 Paul Carensac
# You can do this anywhere on your computer
344 1 Etienne Pallier
$ git clone https://github.com/jdswinbank/Comet.git
345 1 Etienne Pallier
$ cd Comet
346 1 Etienne Pallier
$ (sudo ?) python setup.py install
347 236 Jeremy Barneron
$ sudo apt-get install python-lxml
348 1 Etienne Pallier
349 1 Etienne Pallier
# Now you can test it, no failure are expected, please contact the dev team for help
350 213 Etienne Pallier
$ twistd comet --help
351 1 Etienne Pallier
$ trial comet
352 213 Etienne Pallier
All tests should pass
353 1 Etienne Pallier
</pre>
354 1 Etienne Pallier
355 212 Etienne Pallier
356 1 Etienne Pallier
* MacOS :
357 1 Etienne Pallier
<pre>
358 213 Etienne Pallier
Idem Ubuntu
359 1 Etienne Pallier
</pre>
360 1 Etienne Pallier
361 212 Etienne Pallier
* Windows :
362 1 Etienne Pallier
<pre>
363 212 Etienne Pallier
TODO:
364 212 Etienne Pallier
</pre>
365 212 Etienne Pallier
366 212 Etienne Pallier
367 212 Etienne Pallier
368 212 Etienne Pallier
369 212 Etienne Pallier
370 190 Paul Carensac
371 190 Paul Carensac
---
372 190 Paul Carensac
373 211 Etienne Pallier
h3. Install the other project dependencies and the database (within a Python virtual environment)
374 190 Paul Carensac
375 190 Paul Carensac
Go into the PYROS/install/ folder and Run the install_requirements.sh script.
376 190 Paul Carensac
377 190 Paul Carensac
(You will be prompted to enter a username, an email, and a password for the superuser)
378 190 Paul Carensac
379 190 Paul Carensac
* Mac and Linux:
380 190 Paul Carensac
<pre>
381 190 Paul Carensac
./install_requirements.sh
382 190 Paul Carensac
</pre>
383 190 Paul Carensac
384 190 Paul Carensac
* Windows:
385 190 Paul Carensac
<pre>
386 190 Paul Carensac
install_requirements_windows.bat
387 190 Paul Carensac
</pre>
388 190 Paul Carensac
389 190 Paul Carensac
_If something goes wrong, install manually each package (see section "MANUAL INSTALLATION OF PYTHON PACKAGES, ONE BY ONE")_
390 186 Paul Carensac
391 98 Etienne Pallier
392 9 Etienne Pallier
---
393 9 Etienne Pallier
394 9 Etienne Pallier
h3. (Eclipse only) Set the Python3 virtual environment as the project interpreter
395 9 Etienne Pallier
396 65 Etienne Pallier
See below, in section "NOTES FOR ECLIPSE USERS"
397 9 Etienne Pallier
398 1 Etienne Pallier
---
399 1 Etienne Pallier
400 170 Etienne Pallier
---
401 170 Etienne Pallier
402 17 Etienne Pallier
h2. %{margin-left:0px; font-weight:bold; font-size:25px;  display:block; color:red;}IV - TEST%
403 17 Etienne Pallier
404 108 Etienne Pallier
405 90 Etienne Pallier
(Tests are classes declared in all apps' test.py file. The test classes inherit from django.test.TestCase)
406 17 Etienne Pallier
407 17 Etienne Pallier
You can run the tests suite, just to be sure that the software is well installed.
408 17 Etienne Pallier
409 19 Etienne Pallier
h3. From Terminal
410 19 Etienne Pallier
411 19 Etienne Pallier
412 1 Etienne Pallier
<pre>
413 1 Etienne Pallier
414 219 Paul Carensac
$ cd PYROS/
415 94 Etienne Pallier
416 219 Paul Carensac
$ ./pyrosrun.sh test_all
417 17 Etienne Pallier
</pre>
418 19 Etienne Pallier
419 160 Paul Carensac
h3. From Eclipse
420 1 Etienne Pallier
421 216 Etienne Pallier
Right-clic on the project / Django / Run Django tests
422 1 Etienne Pallier
423 216 Etienne Pallier
(for more information, see below, in section "NOTES FOR ECLIPSE USERS")
424 25 Paul Carensac
425 160 Paul Carensac
h3. Custom commands
426 27 Paul Carensac
427 25 Paul Carensac
$ [./manage.py] test app.tests                           # Run tests for the application 'app'
428 25 Paul Carensac
$ [./manage.py] test app.tests.ModelTests                # Run test methods declared in the class app.tests.ModelTests
429 25 Paul Carensac
$ [./manage.py] test app.tests.ModelTests.test_method    # Only run the method test_method declared in app.tests.ModelTests
430 33 Etienne Pallier
431 33 Etienne Pallier
432 1 Etienne Pallier
---
433 1 Etienne Pallier
434 170 Etienne Pallier
---
435 170 Etienne Pallier
436 92 Etienne Pallier
h2. %{margin-left:0px; font-weight:bold; font-size:25px;  display:block; color:red;}V - RUN%
437 75 Etienne Pallier
438 109 Etienne Pallier
439 223 Etienne Pallier
Before launching Pyros, check that all the pre-requisites are running :
440 223 Etienne Pallier
441 223 Etienne Pallier
 * RabbitMQ: 
442 223 Etienne Pallier
<pre>
443 223 Etienne Pallier
$ systemctl status rabbitmq-server
444 223 Etienne Pallier
445 223 Etienne Pallier
If inactive, start it:
446 223 Etienne Pallier
$ sudo systemctl start rabbitmq-server
447 223 Etienne Pallier
448 224 Etienne Pallier
(To stop it, use "stop" instead of "start")
449 223 Etienne Pallier
450 223 Etienne Pallier
</pre>
451 223 Etienne Pallier
452 223 Etienne Pallier
 * Mysql (only if you are not using Sqlite):
453 225 Etienne Pallier
<pre>
454 225 Etienne Pallier
$ systemctl status mysqld
455 225 Etienne Pallier
456 225 Etienne Pallier
If inactive, start it:
457 225 Etienne Pallier
$ sudo systemctl start mysqld
458 225 Etienne Pallier
459 225 Etienne Pallier
(To stop it, use "stop" instead of "start")
460 225 Etienne Pallier
</pre>
461 223 Etienne Pallier
462 75 Etienne Pallier
* From the terminal
463 75 Etienne Pallier
464 75 Etienne Pallier
<pre>
465 75 Etienne Pallier
466 95 Etienne Pallier
$ cd PYROS/
467 1 Etienne Pallier
468 158 Paul Carensac
$ ./pyrosrun server
469 217 Etienne Pallier
470 217 Etienne Pallier
(To check that this service is actually running, type "$ netstat -an |grep 8000" and you should get "tcp        0      0 127.0.0.1:8000          0.0.0.0:*               LISTEN")
471 217 Etienne Pallier
472 218 Etienne Pallier
(Use instead "python manage.py runserver YOUR_IP_ADDRESS:8000" if you want to access the website from another pc with http://YOUR_IP_ADDRESS:8000) (from within a virtual env, and from src/)
473 217 Etienne Pallier
474 93 Paul Carensac
</pre>
475 75 Etienne Pallier
476 158 Paul Carensac
Now, go to "http://localhost:8000/admin" in your browser
477 91 Etienne Pallier
478 158 Paul Carensac
(and login as "pyros" with the password 'DjangoPyros')
479 105 Etienne Pallier
480 91 Etienne Pallier
(Ctrl-c to stop)
481 91 Etienne Pallier
482 91 Etienne Pallier
483 75 Etienne Pallier
484 106 Etienne Pallier
* From Eclipse : see below, in section "NOTES FOR ECLIPSE USERS"
485 75 Etienne Pallier
486 75 Etienne Pallier
487 1 Etienne Pallier
---
488 1 Etienne Pallier
489 170 Etienne Pallier
---
490 170 Etienne Pallier
491 33 Etienne Pallier
h2. %{margin-left:0px; font-weight:bold; font-size:25px;  display:block; color:red;}NOTES FOR ECLIPSE USERS%
492 35 Etienne Pallier
493 35 Etienne Pallier
0) Install Eclipse (if necessary)
494 35 Etienne Pallier
495 35 Etienne Pallier
Get the Eclipse version for Php
496 35 Etienne Pallier
497 35 Etienne Pallier
Install the plug-in pydev (via install new software, add http://pydev.org/updates)
498 35 Etienne Pallier
499 35 Etienne Pallier
Install the django template editor (via install new software, add http://eclipse.kacprzak.org/updates)
500 35 Etienne Pallier
501 35 Etienne Pallier
1) Deactivate CA certificate verification
502 35 Etienne Pallier
503 35 Etienne Pallier
Window -> Preferences -> Team -> git -> configuration -> Add entry
504 35 Etienne Pallier
505 35 Etienne Pallier
Key = http.sslVerify
506 35 Etienne Pallier
Value = false
507 35 Etienne Pallier
508 35 Etienne Pallier
2) Fetch the project
509 35 Etienne Pallier
510 35 Etienne Pallier
File/Import project from git
511 35 Etienne Pallier
512 35 Etienne Pallier
Select repository source: Clone URI: https://gitlab.irap.omp.eu/epallier/pyros.git
513 35 Etienne Pallier
514 35 Etienne Pallier
Directory: 
515 35 Etienne Pallier
par défaut, il propose : /Users/epallier/git/pyros
516 35 Etienne Pallier
mais on peut le mettre ailleurs (c'est ce que j'ai fait)
517 35 Etienne Pallier
518 35 Etienne Pallier
initial branch: master
519 35 Etienne Pallier
remote name: origin
520 35 Etienne Pallier
521 35 Etienne Pallier
Import as general project
522 35 Etienne Pallier
523 35 Etienne Pallier
Project name: PYROS
524 35 Etienne Pallier
525 35 Etienne Pallier
526 35 Etienne Pallier
3) Configure the project
527 35 Etienne Pallier
528 35 Etienne Pallier
The project is created. Now, you have to set it as a «PyDev » and a « Django » project.
529 35 Etienne Pallier
530 35 Etienne Pallier
clic droit sur le projet / PyDev / set as a PyDev project
531 35 Etienne Pallier
532 35 Etienne Pallier
clic droit sur le projet / PyDev / set as a Django project
533 35 Etienne Pallier
534 35 Etienne Pallier
clic droit sur le projet : on doit maintenant avoir un sous-menu Django
535 35 Etienne Pallier
536 35 Etienne Pallier
clic droit sur le dossier src / PyDev / set as source folder (add to PYTHONPATH)
537 35 Etienne Pallier
538 35 Etienne Pallier
clic droit sur projet / Properties / Pydev-Django :
539 215 Etienne Pallier
  - *Django manage.py : src/manage.py*
540 215 Etienne Pallier
  - *Django settings module : pyros.settings*
541 35 Etienne Pallier
542 35 Etienne Pallier
543 35 Etienne Pallier
4) Set Code style
544 35 Etienne Pallier
545 35 Etienne Pallier
Window/Preferences : Pydev / Editor
546 35 Etienne Pallier
- Auto Imports : uncheck « Do auto import »
547 35 Etienne Pallier
- Code style:
548 35 Etienne Pallier
	- Locals … : camelCase
549 35 Etienne Pallier
	- Methods : camelCase() with first lower
550 35 Etienne Pallier
- Code style / Code Formatter: activer « use autopep8.py for code formatting »
551 35 Etienne Pallier
- Tabs : Tab length : 4
552 35 Etienne Pallier
553 67 Etienne Pallier
5) Now, once the Python3 virtual environment is installed (see above),
554 66 Etienne Pallier
set it in Eclipse as the project interpreter:
555 66 Etienne Pallier
556 68 Etienne Pallier
Right clic on the project / Properties / PyDev - Interpreter/Grammar :
557 66 Etienne Pallier
Grammar version : 3
558 66 Etienne Pallier
559 66 Etienne Pallier
Interpreter : click on « click here to configure an interpreter not listed »
560 66 Etienne Pallier
561 66 Etienne Pallier
click on « New... » :
562 66 Etienne Pallier
- Interpreter name : venv_py35_pyros
563 66 Etienne Pallier
- Interpreter executable : click on « Browse »
564 66 Etienne Pallier
	Select your virtualenv python35 executable (private/venv_py35_pyros/bin/python3.5)
565 66 Etienne Pallier
	click OK
566 66 Etienne Pallier
567 66 Etienne Pallier
*Now, a last thing to do so that Pydev finds Django:*
568 66 Etienne Pallier
569 66 Etienne Pallier
In the Python interpreters list, select your virtual env (venv_py35_pyros)
570 66 Etienne Pallier
571 66 Etienne Pallier
Click on the tab "Libraries"
572 66 Etienne Pallier
573 66 Etienne Pallier
clic on 'New folder', then select your virtualenv's lib/python3.5/site-packages folder
574 66 Etienne Pallier
575 66 Etienne Pallier
OK
576 66 Etienne Pallier
577 66 Etienne Pallier
Interpreter: select now venv_py35_pyros from the list
578 66 Etienne Pallier
579 66 Etienne Pallier
OK
580 62 Etienne Pallier
581 78 Etienne Pallier
6) Test
582 1 Etienne Pallier
583 78 Etienne Pallier
* Right-clic on the project / Django / Run Django tests
584 78 Etienne Pallier
585 78 Etienne Pallier
* Right-clic on the project / Django / Custom command / ...
586 78 Etienne Pallier
587 78 Etienne Pallier
588 78 Etienne Pallier
7) Run
589 70 Etienne Pallier
590 70 Etienne Pallier
Right clic on project -> Django/Custom command/runserver
591 70 Etienne Pallier
592 70 Etienne Pallier
Error on Ubuntu :
593 70 Etienne Pallier
594 70 Etienne Pallier
<pre>
595 70 Etienne Pallier
596 70 Etienne Pallier
Traceback (most recent call last):
597 70 Etienne Pallier
  File "/home/carens_p/git/pyros/src/manage.py", line 8, in <module>
598 70 Etienne Pallier
    from django.core.management import execute_from_command_line
599 70 Etienne Pallier
ImportError: No module named 'django'
600 70 Etienne Pallier
601 70 Etienne Pallier
</pre>
602 70 Etienne Pallier
603 70 Etienne Pallier
Project -> Properties -> Pydev interpreter -> Clic here to configure an interpreter not listed
604 70 Etienne Pallier
605 70 Etienne Pallier
select venv_py35_pyros
606 70 Etienne Pallier
607 70 Etienne Pallier
In Libraries, clic on 'New folder', then select your virtualenv's lib/python3.5/site-packages folder.
608 70 Etienne Pallier
609 70 Etienne Pallier
OK -> re-select venv_py35_pyros in 'Interpreter' dropdown menu
610 70 Etienne Pallier
611 70 Etienne Pallier
Then right clic on project -> Django/Custom command/runserver
612 70 Etienne Pallier
613 70 Etienne Pallier
check http://localhost:8000/
614 70 Etienne Pallier
615 70 Etienne Pallier
616 62 Etienne Pallier
---
617 62 Etienne Pallier
618 62 Etienne Pallier
---
619 62 Etienne Pallier
620 81 Etienne Pallier
h2. %{margin-left:0px; font-weight:bold; font-size:25px;  display:block; color:red;}MANUAL INSTALLATION OF PYTHON PACKAGES ONE BY ONE%
621 81 Etienne Pallier
622 172 Etienne Pallier
*Follow these steps only if the previous guided and nearly automatic installation did not work for you*
623 100 Etienne Pallier
624 172 Etienne Pallier
625 174 Etienne Pallier
h3. (Only if using Mysql) Create the database "pyros" and the pyros user
626 174 Etienne Pallier
627 174 Etienne Pallier
Only if you are using Mysql, you need to create an empty database "pyros"
628 174 Etienne Pallier
(which will be filled automatically by django)
629 174 Etienne Pallier
630 174 Etienne Pallier
<pre>
631 174 Etienne Pallier
$ mysql -u root -p
632 174 Etienne Pallier
(enter your root password)
633 174 Etienne Pallier
634 174 Etienne Pallier
$ mysql> create database if not exists pyros;
635 174 Etienne Pallier
</pre>
636 174 Etienne Pallier
637 174 Etienne Pallier
The user creation depends on your MySQL version :
638 174 Etienne Pallier
639 174 Etienne Pallier
 * 5.7 and above :
640 174 Etienne Pallier
<pre>
641 174 Etienne Pallier
$ mysql> DROP USER IF EXISTS pyros;
642 174 Etienne Pallier
$ mysql> CREATE USER 'pyros' IDENTIFIED BY 'DjangoPyros';
643 174 Etienne Pallier
$ mysql> GRANT ALL PRIVILEGES ON pyros.* TO pyros;
644 174 Etienne Pallier
</pre>
645 174 Etienne Pallier
646 174 Etienne Pallier
 * under 5.7 :
647 174 Etienne Pallier
<pre>
648 174 Etienne Pallier
$ mysql> GRANT USAGE ON *.* TO 'pyros';
649 174 Etienne Pallier
$ mysql> DROP USER 'pyros';
650 174 Etienne Pallier
$ mysql> CREATE USER 'pyros' IDENTIFIED BY 'DjangoPyros';
651 174 Etienne Pallier
$ mysql> GRANT ALL PRIVILEGES ON pyros.* TO pyros;
652 174 Etienne Pallier
</pre>
653 174 Etienne Pallier
654 174 Etienne Pallier
If none of these solution work, check on the internet to create a user named pyros with the password DjangoPyros.
655 174 Etienne Pallier
656 100 Etienne Pallier
h3. Create a Python3 virtual environment dedicated to the project (inside the project folder)
657 100 Etienne Pallier
658 100 Etienne Pallier
<pre>
659 100 Etienne Pallier
660 100 Etienne Pallier
$ mkdir private/
661 100 Etienne Pallier
662 100 Etienne Pallier
$ cd private/
663 100 Etienne Pallier
664 100 Etienne Pallier
$ which python3.5 ("where python" for windows)
665 100 Etienne Pallier
/opt/local/bin/python3.5
666 100 Etienne Pallier
667 100 Etienne Pallier
$ virtualenv venv_py35_pyros -p /opt/local/bin/python3.5
668 100 Etienne Pallier
=> creates a venv_py35_pyros/ folder inside PYROS/private/
669 100 Etienne Pallier
670 100 Etienne Pallier
</pre>
671 100 Etienne Pallier
672 100 Etienne Pallier
673 100 Etienne Pallier
---
674 100 Etienne Pallier
675 100 Etienne Pallier
h3. Activate the python virtual environment (from inside the project)
676 100 Etienne Pallier
677 100 Etienne Pallier
<pre>
678 100 Etienne Pallier
679 100 Etienne Pallier
$ pwd
680 100 Etienne Pallier
.../PYROS/private
681 100 Etienne Pallier
682 100 Etienne Pallier
$ source ./venv_py35_pyros/bin/activate (venv_py35_pyros/Scripts/activate on Windows)
683 100 Etienne Pallier
684 100 Etienne Pallier
</pre>
685 100 Etienne Pallier
686 100 Etienne Pallier
---
687 100 Etienne Pallier
688 100 Etienne Pallier
h3. Install needed python packages
689 100 Etienne Pallier
690 81 Etienne Pallier
Check that the virtual environment is activated
691 81 Etienne Pallier
<pre>
692 81 Etienne Pallier
$ python -V
693 81 Etienne Pallier
Python 3...
694 81 Etienne Pallier
695 81 Etienne Pallier
$ which pip
696 81 Etienne Pallier
.../PYROS/venv_py35_pyros/bin/pip
697 81 Etienne Pallier
</pre>
698 81 Etienne Pallier
699 81 Etienne Pallier
700 81 Etienne Pallier
Upgrade pip to last version available:
701 81 Etienne Pallier
<pre>
702 81 Etienne Pallier
$ pip install --upgrade pip
703 81 Etienne Pallier
Collecting pip
704 81 Etienne Pallier
  Downloading pip-8.1.1-py2.py3-none-any.whl (1.2MB)
705 81 Etienne Pallier
Installing collected packages: pip
706 81 Etienne Pallier
  Found existing installation: pip 7.1.2
707 81 Etienne Pallier
    Uninstalling pip-7.1.2:
708 81 Etienne Pallier
      Successfully uninstalled pip-7.1.2
709 81 Etienne Pallier
Successfully installed pip-8.1.1
710 81 Etienne Pallier
711 81 Etienne Pallier
Upgrade wheel to last version available:
712 81 Etienne Pallier
$ pip install --upgrade wheel
713 81 Etienne Pallier
Collecting wheel
714 81 Etienne Pallier
  Downloading wheel-0.29.0-py2.py3-none-any.whl (66kB)
715 81 Etienne Pallier
Installing collected packages: wheel
716 81 Etienne Pallier
  Found existing installation: wheel 0.24.0
717 81 Etienne Pallier
    Uninstalling wheel-0.24.0:
718 81 Etienne Pallier
      Successfully uninstalled wheel-0.24.0
719 81 Etienne Pallier
Successfully installed wheel-0.29.0
720 81 Etienne Pallier
721 81 Etienne Pallier
</pre>
722 81 Etienne Pallier
723 81 Etienne Pallier
Go into the install/ folder:
724 81 Etienne Pallier
<pre>
725 81 Etienne Pallier
$ cd .../PYROS/install/
726 81 Etienne Pallier
</pre>
727 81 Etienne Pallier
728 84 Etienne Pallier
Install all the needed python packages at once:
729 85 Etienne Pallier
<pre>
730 1 Etienne Pallier
$ pip install -r REQUIREMENTS.txt
731 85 Etienne Pallier
</pre>
732 84 Etienne Pallier
733 84 Etienne Pallier
If something goes wrong, install them one by one:
734 62 Etienne Pallier
735 62 Etienne Pallier
  * *Install Django* :
736 62 Etienne Pallier
<pre>
737 62 Etienne Pallier
$ pip install django
738 62 Etienne Pallier
Collecting django
739 62 Etienne Pallier
  Downloading Django-1.9.4-py2.py3-none-any.whl (6.6MB)
740 62 Etienne Pallier
Installing collected packages: django
741 62 Etienne Pallier
Successfully installed django-1.9.4
742 62 Etienne Pallier
743 62 Etienne Pallier
$ pip install django-admin-tools
744 62 Etienne Pallier
Collecting django-admin-tools
745 62 Etienne Pallier
  Downloading django_admin_tools-0.7.2-py2.py3-none-any.whl (289kB)
746 62 Etienne Pallier
Installing collected packages: django-admin-tools
747 62 Etienne Pallier
Successfully installed django-admin-tools-0.7.2
748 62 Etienne Pallier
749 62 Etienne Pallier
$ pip install django-debug-toolbar
750 62 Etienne Pallier
Collecting django-debug-toolbar
751 62 Etienne Pallier
  Downloading django_debug_toolbar-1.4-py2.py3-none-any.whl (212kB)
752 62 Etienne Pallier
Requirement already satisfied (use --upgrade to upgrade): Django>=1.7 in ./venv_py35_pyros/lib/python3.5/site-packages (from django-debug-toolbar)
753 62 Etienne Pallier
Collecting sqlparse (from django-debug-toolbar)
754 62 Etienne Pallier
  Downloading sqlparse-0.1.19.tar.gz (58kB)
755 62 Etienne Pallier
Building wheels for collected packages: sqlparse
756 62 Etienne Pallier
  Running setup.py bdist_wheel for sqlparse ... done
757 62 Etienne Pallier
  Stored in directory: /Users/epallier/Library/Caches/pip/wheels/7b/d4/72/6011bb100dd5fc213164e4bbee13d4e03261dd54ce6a5de6b8
758 62 Etienne Pallier
Successfully built sqlparse
759 62 Etienne Pallier
Installing collected packages: sqlparse, django-debug-toolbar
760 62 Etienne Pallier
Successfully installed django-debug-toolbar-1.4 sqlparse-0.1.19
761 62 Etienne Pallier
762 62 Etienne Pallier
$ pip install django-extensions
763 62 Etienne Pallier
Collecting django-extensions
764 62 Etienne Pallier
  Downloading django_extensions-1.6.1-py2.py3-none-any.whl (202kB)
765 62 Etienne Pallier
Collecting six>=1.2 (from django-extensions)
766 62 Etienne Pallier
  Downloading six-1.10.0-py2.py3-none-any.whl
767 62 Etienne Pallier
Installing collected packages: six, django-extensions
768 62 Etienne Pallier
Successfully installed django-extensions-1.6.1 six-1.10.0
769 62 Etienne Pallier
770 62 Etienne Pallier
$ pip install django-suit
771 62 Etienne Pallier
Collecting django-suit
772 62 Etienne Pallier
  Downloading django-suit-0.2.18.tar.gz (587kB)
773 62 Etienne Pallier
Building wheels for collected packages: django-suit
774 62 Etienne Pallier
  Running setup.py bdist_wheel for django-suit ... done
775 62 Etienne Pallier
  Stored in directory: /Users/epallier/Library/Caches/pip/wheels/12/8b/9a/e02ab0ad9229881638aa040d47d77c8f562999533811927d41
776 62 Etienne Pallier
Successfully built django-suit
777 62 Etienne Pallier
Installing collected packages: django-suit
778 62 Etienne Pallier
Successfully installed django-suit-0.2.18
779 62 Etienne Pallier
780 62 Etienne Pallier
</pre>
781 62 Etienne Pallier
782 62 Etienne Pallier
  * *Install the django boostrap css package* :
783 62 Etienne Pallier
<pre>
784 62 Etienne Pallier
$ pip install django-bootstrap3
785 62 Etienne Pallier
</pre>
786 62 Etienne Pallier
(==> 'bootstrap3' is then to be added as an application in settings.py -> INSTALLED_APPS)
787 62 Etienne Pallier
788 62 Etienne Pallier
  * *Install the web application server gunicorn (will be used in production instead of the dev django web server)* :
789 62 Etienne Pallier
<pre>
790 62 Etienne Pallier
$ pip install gunicorn
791 62 Etienne Pallier
Collecting gunicorn
792 62 Etienne Pallier
  Downloading gunicorn-19.4.5-py2.py3-none-any.whl (112kB)
793 62 Etienne Pallier
Installing collected packages: gunicorn
794 62 Etienne Pallier
Successfully installed gunicorn-19.4.5
795 62 Etienne Pallier
</pre>
796 62 Etienne Pallier
797 62 Etienne Pallier
  * *Install the python mysql client* (not needed if you want to use sqlite):
798 62 Etienne Pallier
<pre>
799 62 Etienne Pallier
$ pip install mysqlclient
800 62 Etienne Pallier
...
801 62 Etienne Pallier
</pre>
802 62 Etienne Pallier
803 146 Etienne Pallier
   * => If issue under Mac OS X:
804 62 Etienne Pallier
<pre>
805 62 Etienne Pallier
$ pip install mysqlclient
806 62 Etienne Pallier
Collecting mysqlclient
807 62 Etienne Pallier
  Downloading mysqlclient-1.3.7.tar.gz (79kB)
808 62 Etienne Pallier
Building wheels for collected packages: mysqlclient
809 62 Etienne Pallier
  Running setup.py bdist_wheel for mysqlclient ... error
810 62 Etienne Pallier
811 62 Etienne Pallier
  ----------------------------------------
812 62 Etienne Pallier
  Failed building wheel for mysqlclient
813 62 Etienne Pallier
  Running setup.py clean for mysqlclient
814 62 Etienne Pallier
Failed to build mysqlclient
815 62 Etienne Pallier
Installing collected packages: mysqlclient
816 62 Etienne Pallier
  Running setup.py install for mysqlclient ... done
817 62 Etienne Pallier
Successfully installed mysqlclient-1.3.7
818 62 Etienne Pallier
819 62 Etienne Pallier
BOUH !!!
820 1 Etienne Pallier
821 152 Etienne Pallier
=> Need to upgrade wheel:
822 146 Etienne Pallier
823 62 Etienne Pallier
$ pip install --upgrade wheel
824 62 Etienne Pallier
Collecting wheel
825 62 Etienne Pallier
  Downloading wheel-0.29.0-py2.py3-none-any.whl (66kB)
826 62 Etienne Pallier
Installing collected packages: wheel
827 62 Etienne Pallier
  Found existing installation: wheel 0.24.0
828 62 Etienne Pallier
    Uninstalling wheel-0.24.0:
829 62 Etienne Pallier
      Successfully uninstalled wheel-0.24.0
830 62 Etienne Pallier
Successfully installed wheel-0.29.0
831 62 Etienne Pallier
832 153 Etienne Pallier
YES !!!
833 1 Etienne Pallier
834 154 Etienne Pallier
Only if necessary, you can reinstall mysqlclient:
835 153 Etienne Pallier
$ pip uninstall mysqlclient
836 62 Etienne Pallier
$ pip install mysqlclient
837 62 Etienne Pallier
Collecting mysqlclient
838 62 Etienne Pallier
  Using cached mysqlclient-1.3.7.tar.gz
839 62 Etienne Pallier
Building wheels for collected packages: mysqlclient
840 62 Etienne Pallier
  Running setup.py bdist_wheel for mysqlclient ... done
841 62 Etienne Pallier
  Stored in directory: /Users/epallier/Library/Caches/pip/wheels/9b/06/50/d11418c26cf8f2156b13d4363b5afde8e7e75ebb8540d0228d
842 62 Etienne Pallier
Successfully built mysqlclient
843 62 Etienne Pallier
Installing collected packages: mysqlclient
844 62 Etienne Pallier
Successfully installed mysqlclient-1.3.7
845 62 Etienne Pallier
846 1 Etienne Pallier
</pre>
847 62 Etienne Pallier
848 146 Etienne Pallier
   * => If issue under Windows
849 62 Etienne Pallier
<pre>
850 62 Etienne Pallier
Same message as the issue for Mac.
851 146 Etienne Pallier
852 204 Paul Carensac
=> Need to install wheel manually :
853 62 Etienne Pallier
854 62 Etienne Pallier
Go to http://www.lfd.uci.edu/~gohlke/pythonlibs/#mysqlclient to download the newest mysqlclient wheel
855 62 Etienne Pallier
856 62 Etienne Pallier
$ pip install path\to\mysqlclient\wheel
857 62 Etienne Pallier
858 154 Etienne Pallier
(No need to redo "pip install mysqlclient")
859 62 Etienne Pallier
</pre>
860 163 Paul Carensac
861 163 Paul Carensac
  * *Install the julian day converter* :
862 163 Paul Carensac
<pre>
863 163 Paul Carensac
$ pip install jdcal
864 163 Paul Carensac
</pre>
865 182 Paul Carensac
866 188 Paul Carensac
  * *Install Celery and dependencies* :
867 182 Paul Carensac
<pre>
868 182 Paul Carensac
$ pip install celery
869 1 Etienne Pallier
$ pip install django-celery
870 188 Paul Carensac
$ pip install Twisted==16.0.0
871 188 Paul Carensac
</pre>
872 188 Paul Carensac
873 188 Paul Carensac
  * *Install django test without migrations (compulsory to use the prod DB for tests)* :
874 188 Paul Carensac
<pre>
875 188 Paul Carensac
$ pip install django-test-without-migrations==0.4
876 188 Paul Carensac
</pre>
877 188 Paul Carensac
878 188 Paul Carensac
  * *Install voevent parser* :
879 188 Paul Carensac
<pre>
880 188 Paul Carensac
$ pip install voevent-parse==0.9.5
881 188 Paul Carensac
</pre>
882 188 Paul Carensac
883 188 Paul Carensac
884 188 Paul Carensac
  * *Install other dependencies (useful ? TBC)* :
885 188 Paul Carensac
<pre>
886 188 Paul Carensac
$ pip install amqplib==1.0.2
887 188 Paul Carensac
$ pip install pluggy==0.3.1
888 188 Paul Carensac
$ pip install py==1.4.31
889 182 Paul Carensac
</pre>