meza
meza copied to clipboard
Rotate Parsoid log file
Currently in Parsoid log files are never rotated, and thus continue to grow with time. A method of log rotation should be developed.
One method would be to create a new log each time the Parsoid service is restarted. In initd_parsoid.sh
when the Parsoid log file is setup it always uses the same name:
runuser -l "$USER" -c "nohup $DAEMON $SERVER >> $LOG_FILE 2>&1 &" && parsoid_start_echo_success || echo_failure
source: https://github.com/enterprisemediawiki/meza/blob/master/config/core/initd_parsoid.sh#L43
LOG_FILE is defined as LOG_FILE="$ROOT_DIR/server.js.log"
, but this could be easily change to include a timestamp. If the timestamped file doesn't exist (which it basically never should) then create the file.
@freephile could you look into this?