Go to file
Adrian Schmutzler 718d207612 api/alfredX: Remove InfluxDB test code
This reverts commits:
ccb5bb020f ("api/alfredX: Update code for InfluxDB test")
396d5a251e ("api/alfredX: Add code for InfluxDB test")

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2020-11-24 12:40:01 +01:00
alfred-monitoring-proxy Handle even larger requests 2016-02-17 02:47:13 +01:00
contrib Rename net_if from router_neighbor table to netif 2017-12-29 19:25:01 +01:00
ffmap api/alfredX: Remove InfluxDB test code 2020-11-24 12:40:01 +01:00
gwinfo gwinfo: Fix IPv4/IPv6 sed (leading space in match pattern) 2018-10-17 18:19:36 +02:00
scripts global: convert to InfluxDB 2020-11-24 11:05:14 +01:00
.gitignore gitignore: Add mysqlconfig 2017-11-19 15:43:08 +01:00
README.md tilestache: use memcache instead of disk for tile storage 2020-03-11 14:13:56 +01:00
install.sh tilestache: use memcache instead of disk for tile storage 2020-03-11 14:13:56 +01:00
restart.sh Add restart.sh 2018-01-19 15:04:42 +01:00
setup.py setup.py: Update link to GitHub for service 2018-11-24 15:52:12 +01:00
start.sh Add start.sh, stop.sh 2018-01-21 20:56:05 +01:00
stop.sh Add start.sh, stop.sh 2018-01-21 20:56:05 +01:00

README.md

Git Repository Logic

  • Frequent updates are made to the testing branch, which is considered "dirty". Commits appearing here may be quickly written, untested, incomplete, etc. This is where the development happens.
  • In unspecified intervals, the piled-up changes in the testing branch are reviewed, ordered and squashed to a smaller set of tidy commits. Those are then pushed to the master branch.
  • The tidy-up is marked by an empty commit "Realign with master" in the testing branch. This is roughly equivalent to a merge, although for an actual merge the commits would remain unaltered.
  • Development happens in the testing branch. Thus, testing is more up-to-date, but master is better to understand.
  • The Monitoring web server uses the testing branch.

Debian Dependencies

apt-get install mysql-server memcached python3-memcache python3-mysqldb python python3 python3-requests python3-lxml python3-pip python3-flask python3-dateutil python3-numpy python3-scipy python3-mapnik python3-pip uwsgi-plugin-python3 nginx
pip3 install wheel pymongo pillow modestmaps simplejson werkzeug

Prerequisites

  • Datenbank in MySQL anlegen
  • Git vorbereiten:
git clone https://github.com/FreifunkFranken/fff-monitoring
git clone https://github.com/TileStache/TileStache
cd fff-monitoring
cp ffmap/mysqlconfig.example.py ffmap/mysqlconfig.py
  • MySQL Zugangsdaten in mysqlconfig.py eintragen

Installation

./install.sh
systemctl daemon-reload
systemctl enable uwsgi-ffmap
systemctl enable uwsgi-tiles
systemctl start uwsgi-ffmap
systemctl start uwsgi-tiles
cd ffmap/db/
./init_db.py
# Then apply NGINX Config
cd ../.. # go back to fff-monitoring root directory
./scripts/setupcron.sh

NGINX Config

server {
	listen 443 ssl default_server;
	listen [::]:443 ssl default_server;

...

	location / {
		include uwsgi_params;
		uwsgi_pass 127.0.0.1:3031;
		client_max_body_size 30M;
	}

	location /tiles {
		include uwsgi_params;
		uwsgi_pass 127.0.0.1:3032;
	}
	
	location /static/ {
		root /usr/share/ffmap/;
		expires max;
		add_header Cache-Control "public";
	}

...

}

Admin anlegen

  • User über WebUI anlegen
  • Dann über z.B. phpmyadmin in der Tabelle users 'admin' auf 1 setzen