"test sys_refresh_ref_cron.sh"

This commit is contained in:
Doug Le Tough 2017-07-25 12:44:50 +02:00
parent 24e2b36fff
commit 8ddb9f1555
1 changed files with 1 additions and 1 deletions

View File

@ -178,7 +178,7 @@ function refresh_cronjobs
COMMAND=$(echo ${CRONJOB} | cut -d' ' -f6-)
REQUEST_ID_PARAMS="host='${VM}' and s_user='${TETALAB_USER}' and minutes='${MINUTES}'
and hours='${HOURS}' and days='${DAYS}' and daysofweek='${DAYSOFWEEKS}' and command='${COMMAND}'"
RESULT=$(psql -e -t -h ${DB_HOST} -U ${DB_USER} -d ${DB_DATABASE} -c "select ID from
RESULT=$(psql -t -h ${DB_HOST} -U ${DB_USER} -d ${DB_DATABASE} -c "select ID from
ref_cron where ${REQUEST_ID_PARAMS};")
if [ ${#RESULT} -eq 0 ]; then
fct_message "Cronjob not in database, inserting..."