Something went wrong. Try again.
Docker files for the TLE Community deployment
Something went wrong. Try again.
deployment entrypoint-logrotate.sh
410 B · 19 lines
Shell
at main
1234567891011121314151617181920#!/bin/sh
## Run logrotate once a day against the bind-mounted config. `|| true` so a# transient error (e.g. a log file mid-rename) doesn't kill the container.#
set -eu
CONF=/etc/logrotate.d/lacunaSTATE=/var/lib/logrotate/lacuna.status
mkdir -p /var/lib/logrotate
while true; do echo "$(date -u '+%Y-%m-%dT%H:%M:%SZ') running logrotate" logrotate -v -s "$STATE" "$CONF" || true sleep 86400done