Log clean session cron output
Cron jobs should be silent on normal operation, and only emit output on error. Redirect stdout from the clean_sessions job to a file. Change-Id: Ifdd2b38248970204acd17944b21e1c39de92332a
This commit is contained in:
parent
a627758a88
commit
6f4b10a63a
|
@ -1,3 +1,7 @@
|
|||
#!/bin/bash
|
||||
cd <%= @site_root %>/config
|
||||
python manage.py clean_session
|
||||
DATE=`date --rfc-3339=seconds`
|
||||
echo "Start clean session run at $DATE" >><%= @site_root %>/log/clean_session.log
|
||||
python manage.py clean_session >><%= @site_root %>/log/clean_session.log
|
||||
DATE=`date --rfc-3339=seconds`
|
||||
echo "End clean session run at $DATE" >><%= @site_root %>/log/clean_session.log
|
||||
|
|
Loading…
Reference in New Issue