Blame view

doc/HOWTO_RUN.txt 1.93 KB
e0bd046a   Etienne Pallier   - Ajouté 2 HOWTO ...
1
2


a9d06e6f   Etienne Pallier   new PYROS_DOCKER_...
3
4
5
6
7
=> ONLINE DEMO : http://pyros.irap.omp.eu




e0bd046a   Etienne Pallier   - Ajouté 2 HOWTO ...
8
9
10
11
*******************************
 Here is how you can RUN pyros 
*******************************

321c1c7d   Etienne Pallier   updated HOWTO
12
13
(More on this subject at https://docs.google.com/document/d/1osHT3d8GiofRd9k3nL7cz4Hcmo9WVEOcSaSSQpgJcFs/edit#heading=h.w3ny4xnj9sc8)

61df368d   Etienne Pallier   Mis à jour Enviro...
14
15


e0bd046a   Etienne Pallier   - Ajouté 2 HOWTO ...
16
17
18
19
-------------------------------------------
(A) Command-line running (no web interface):
-------------------------------------------

e0bd046a   Etienne Pallier   - Ajouté 2 HOWTO ...
20
(1) Running pyros interactively:
61df368d   Etienne Pallier   Mis à jour Enviro...
21
	$  [python] ./pyros.py shell
e0bd046a   Etienne Pallier   - Ajouté 2 HOWTO ...
22

e0bd046a   Etienne Pallier   - Ajouté 2 HOWTO ...
23
(2) Launching an agent:
61df368d   Etienne Pallier   Mis à jour Enviro...
24
25
	$  [python] ./pyros.py start <agent-name>
	=> Ex: to start the env-monitoring agent:
bf8090d8   Etienne Pallier   update
26
	$  [python] ./pyros.py start agentM
61df368d   Etienne Pallier   Mis à jour Enviro...
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
	=> Ex: to start agentA:
	$ [python] ./pyros.py start agentA

(3) Launching the Environment Monitoring
Open 3 different terminals
a) In terminal 1, launch the PLC simulator
	$ cd simulators/plc/
	$ [python] ./plcSimulator.py 
b) In terminal 2, launch the Monitoring agent 
	$ [python] ./pyros.py start agentM
c) In terminal 3, launch the webserver
	$ [python] ./pyros.py start webserver
d) With a browser, go to the Environment Monitoring dashboard
	- See the current weather :
	Click on Weather (or go to http://127.0.0.1:8000/dashboard/weather
	- Configure the monitoring :
	Go to http://127.0.0.1:8000/monitoring/weather/config
80d4ac71   Etienne Pallier   updated version a...
44

82e60ac9   Etienne Pallier   bugfix plc_config...
45
(4) Launching many agents:
61df368d   Etienne Pallier   Mis à jour Enviro...
46
47
48
49
50
	$ [python] ./pyros.py start <agent1-name>,<agent2-name>,.
	=> Ex: start agentA and agentB
	$ [python] ./pyros.py start agentA,agentB
	=> You could also start ALL agents at once:
	$ [python] ./pyros.py start all
e0bd046a   Etienne Pallier   - Ajouté 2 HOWTO ...
51
52
53
54
55
56
57


-------------------------------------------
(B) Running with the website
-------------------------------------------

(1) Start only the webserver (for pyros website)
61df368d   Etienne Pallier   Mis à jour Enviro...
58
	$ [python] ./pyros.py start webserver
e0bd046a   Etienne Pallier   - Ajouté 2 HOWTO ...
59
60
61
62
63
64
65
Then, connect to http://localhost:8000
You can also connect to the admin interface: http://localhost:8000/admin
(Login as 'pyros' with the password 'DjangoPyros')

(2) Now, you can start some (or all) agents to have the website come to life !
See section (A) just above

82e60ac9   Etienne Pallier   bugfix plc_config...
66