| commit | 5e4561f60c161faaa8f86e2666992a3f8128351c | [log] [tgz] |
|---|---|---|
| author | avm99963 <me@avm99963.com> | Wed Jul 08 17:12:13 2020 +0200 |
| committer | avm99963 <me@avm99963.com> | Wed Jul 08 17:12:13 2020 +0200 |
| tree | c05686d33429cc048049036595c759768dc8d950 | |
| parent | 26232cc9c3dbd780bde28567376ccc65ed005e98 [diff] |
Move index.php to index.html It doesn't contain any PHP code, and this way PHP doesn't have to process the main page, and we can serve it as a static asset, being able also to better cache it. Change-Id: I5fb1b71d382c0686b062471d92035651d16266b0
This is the code for https://covid-19.sandbox.avm99963.com, which contains graphs which determine the level of risk of each Catalan health area due to the COVID-19, based on the work of the BIOCOMSC group at the Polytechnic University of Catalonia (UPC).
DISCLAIMER: The data shown in the website might be wrong due to a wrong implementation.
This software is meant to be used with Apache2 in order to serve a website including the last Covid-19 data.
To install it, follow these steps:
git clone "ssh://avm99963@gerrit.avm99963.com:29418/covid19".covid19/cron and runs the bash generate.bash command every day early in the morning.crontab -e and place the following line at the end of the document: 0 2 * * * (cd /path/to/covid19/cron/ && bash generate.bash)Each day, the generate.bash script will generate the graphs at the covid19/output folder.
bash generate.bash command anytime from the covid19/cron directory in order to manually generate the graphs.This is what each file does:
index.html: a web accessible document which includes a disclaimer text, a key for the graphs, and the generated graphs themselves.cron folder: a non-web accessible folder which contains programs which ultimately generate the graphs.cron/generate.bash: a Bash script which orchestrates all the other programs in the folder in order to generate the graphs.cron/generateData.php: a PHP script which extracts the Covid-19 data from the Generalitat de Catalunya's API and analyzes that data to generate the ρ7 and IA14 values needed by cron/generateGraphs.gnu.cron/generateGraphs.gnu: a gnuplot script which generates the graphs with the data which has been provided by the cron/generateData.php. It uses the helper script cron/plot.gnu.