-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
74 changed files
with
110 additions
and
106 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,20 @@ | ||
Derived from this work | ||
https://github.com/docker/awesome-compose/tree/c2f8036fd353dae457eba7b9b436bf3a1c85d937/flask | ||
# Dashboard website | ||
|
||
To test locally | ||
This frontend website is displaying the state and data of the sensor network. | ||
|
||
It is linked to an elastic-search instance that store and index the files | ||
generated by zero_*.py services. | ||
|
||
This website and the backend is easily deployed if you are using the docker | ||
services described in [ansible_openvpn](../ansible_openvpn) folder. | ||
|
||
# Build and run image to container | ||
|
||
```shell | ||
sudo docker build ./ -t dashboard && sudo docker run -p "8080:80" -v ./app/:/home/dashboard/app/ dashboard | ||
``` | ||
|
||
Then open localhost:8080 in browser | ||
|
||
Without having to rebuild the image or restarting the container, all changes made in files will be automatically applied | ||
|
||
docker build -t flasktest . | ||
docker run --name flasktest -p 8000:8000 flasktest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"id": "hKUAUIoBOM9IQ1Kp18_2", | ||
"name": "python2", | ||
"api_key": "Qk77qq1AR3WxkwbuQw_Jcw", | ||
"encoded": "aEtVQVVJb0JPTTlJUTFLcDE4XzI6UWs3N3FxMUFSM1d4a3didVF3X0pjdw==", | ||
"url": "https://172.20.0.3:9200", | ||
"verify_certs": false | ||
} |
Binary file added
BIN
+162 KB
services/ansible_openvpn/docker/dashboard/app/fonts/fontawesome-webfont.ttf
Binary file not shown.
Binary file added
BIN
+95.7 KB
services/ansible_openvpn/docker/dashboard/app/fonts/fontawesome-webfont.woff
Binary file not shown.
Binary file added
BIN
+75.4 KB
services/ansible_openvpn/docker/dashboard/app/fonts/fontawesome-webfont.woff2
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
39 changes: 39 additions & 0 deletions
39
services/ansible_openvpn/docker/dashboard/app/templates/query_sensor_list.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ | ||
"size": 0, | ||
"fields": [ | ||
"TPV.lat", | ||
"TPV.lon", | ||
"hwa", | ||
"date" | ||
], | ||
"aggs": { | ||
"group": { | ||
"terms": { | ||
"field": "hwa.keyword", | ||
"size": 200 | ||
}, | ||
"aggs": { | ||
"results_without_mb_id": { | ||
"filter": { | ||
"exists": { | ||
"field": "TPV.lat" | ||
} | ||
} | ||
}, | ||
"group_docs": { | ||
"top_hits": { | ||
"size": 1, | ||
"_source": false, | ||
"sort": [ | ||
{ | ||
"date": { | ||
"order": "desc" | ||
} | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,4 @@ | ||
fastapi>=0.103.0,<0.104.0 | ||
uvicorn>=0.23.2,<0.24 | ||
Jinja2>=3.1.2,<3.2.0 | ||
elasticsearch>=8.9.0,<8.10.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
services/ansible_openvpn/playbooks/files/scripts_elasticsearch/requirements.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
elasticsearch==8.9.0 | ||
elasticsearch>=8.9.0,<8.10.0 |
This file was deleted.
Oops, something went wrong.
Empty file.
This file was deleted.
Oops, something went wrong.
25 changes: 0 additions & 25 deletions
25
services/website_dashboard/app/templates/query_sensor_list.json
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.