summaryrefslogtreecommitdiffstats
path: root/retiolum/scripts/adv_graphgen/scripts/all-the-graphs
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2015-09-16 08:30:04 +0200
committermakefu <github@syntax-fehler.de>2015-09-16 08:30:04 +0200
commit147044be891c92b3c0c1bcc3a4e53e2d0eef9963 (patch)
tree13ed3ac36d514347f503043b454dddaee51b03ac /retiolum/scripts/adv_graphgen/scripts/all-the-graphs
parent9bf9f8d045801b17956d12f599bb166e608ed6dd (diff)
parent219fab970c7fe455d3dd9bc48e909d96a234046b (diff)
Merge branch 'master' of github.com:krebscode/painload
Diffstat (limited to 'retiolum/scripts/adv_graphgen/scripts/all-the-graphs')
-rwxr-xr-xretiolum/scripts/adv_graphgen/scripts/all-the-graphs18
1 files changed, 18 insertions, 0 deletions
diff --git a/retiolum/scripts/adv_graphgen/scripts/all-the-graphs b/retiolum/scripts/adv_graphgen/scripts/all-the-graphs
new file mode 100755
index 00000000..889a9fe0
--- /dev/null
+++ b/retiolum/scripts/adv_graphgen/scripts/all-the-graphs
@@ -0,0 +1,18 @@
+#!/bin/bash
+
+EXTERNAL_FOLDER=${EXTERNAL_FOLDER:-/var/www/euer.krebsco.de/graphs/retiolum}
+INTERNAL_FOLDER=${INTERNAL_FOLDER:-/var/www/euer/graphs/retiolum}
+export GEODB="${GEODB:-}"
+export TINC_HOSTPATH=${TINC_HOSTPATH:-~/painload/retiolum/hosts}
+mapfile="$INTERNAL_FOLDER/map.html"
+
+if test -n "$GEOCITYDB";then
+ if test ! -e "$mapfile";then
+ echo "copying map to $map.html"
+ copy-map "$mapfile"
+ fi
+ echo "creating geodata database"
+ tinc-stats2json | add-geodata > "$INTERNAL_FOLDER/marker.json"
+fi
+build-graphs anonymous "$EXTERNAL_FOLDER"
+build-graphs complete "$INTERNAL_FOLDER"