Initial refactoring

Renamed rhizomatica_base_system to rhizo_base
Split up the init.pp in different subclasses
More work to follow
This commit is contained in:
Ciaby 2015-05-18 14:01:31 -05:00
parent 7b938abede
commit 1c7dffc32a
192 changed files with 547 additions and 430 deletions

View file

@ -0,0 +1,16 @@
#!/bin/bash
LOGFILE="/var/log/monitor_rapi.log"
function logc() {
txt=$1
echo "[`date '+%d-%m-%Y %H:%M:%S'`] $txt" >> $LOGFILE
}
curl --connect-timeout 180 --max-time 180 -X GET http://localhost:8085/configuration/site 2>/dev/null
if [ $? -gt 0 ]; then
logc "RAPI is not responding kill the process"
PID=`ps axf | grep rapi | grep python | awk '{print $1}'`
kill -9 $PID
logc "RAPI restarted"
fi