mirror of
https://github.com/nextcloud/docker.git
synced 2025-04-21 03:06:08 +02:00
Support updating CRON_PREVIEW time
Signed-off-by: Josh Richards <josh.t.richards@gmail.com>
This commit is contained in:
parent
24f485d38b
commit
ea6c4b3366
1 changed files with 3 additions and 1 deletions
|
@ -5,7 +5,9 @@ set -eu
|
||||||
# Note: the user should make sure they install the app first and we could check here but it's non-fatal...
|
# Note: the user should make sure they install the app first and we could check here but it's non-fatal...
|
||||||
if [ -n "${CRON_PREVIEW+x}" ]; then
|
if [ -n "${CRON_PREVIEW+x}" ]; then
|
||||||
echo "Configuring Preview Generator to run at ${CRON_PREVIEW}:00 (24H system time) if /cron.sh is activated"
|
echo "Configuring Preview Generator to run at ${CRON_PREVIEW}:00 (24H system time) if /cron.sh is activated"
|
||||||
echo "* ${CRON_PREVIEW} * * * /var/www/html/occ preview:pre-generate" >> /var/spool/cron/crontabs/www-data
|
sed -n -e '/preview:pre-generate/!p' -e "\$a\* ${CRON_PREVIEW} \* \* \* /var/www/html/occ preview:pre-generate" \
|
||||||
|
/var/spool/cron/crontabs/www-data > /var/spool/cron/crontabs/www-data.tmp && \
|
||||||
|
mv /var/spool/cron/crontabs/www-data.tmp /var/spool/cron/crontabs/www-data
|
||||||
fi
|
fi
|
||||||
|
|
||||||
exec busybox crond -f -l 0 -L /dev/stdout
|
exec busybox crond -f -l 0 -L /dev/stdout
|
||||||
|
|
Loading…
Add table
Reference in a new issue