debian: add synchronization scripts for w.c.s. instances

This commit is contained in:
Benjamin Dauvergne 2016-07-15 18:24:48 +02:00
parent 7b174d9ce0
commit 899b810e3d
3 changed files with 15 additions and 0 deletions

View File

@ -1,4 +1,5 @@
debian/bijoe-manage /usr/bin
debian/settings.py /etc/bijoe
debian/debian_config.py /usr/lib/bijoe
debian/import-wcs-data.sh /usr/lib/bijoe
README.rst /usr/share/doc/bijoe

3
debian/cron.d vendored Normal file
View File

@ -0,0 +1,3 @@
MAILTO=root
0 * * * * bijoe /usr/lib/bijoe/import-wcs-data.sh

11
debian/import-wcs-data.sh vendored Executable file
View File

@ -0,0 +1,11 @@
#!/bin/sh
LOG=`tempfile`
trap "rm $LOG" EXIT
for tenant in /var/lib/bijoe/tenants/*; do
if [ -f $tenant/wcs-olap.ini ]; then
wcs-olap --all $tenant/wcs-olap.ini >$LOG || cat $LOG
fi
done