Add a 'thumbnailer container'

uses the same method as the cron container, runs every 60 seconds.

fixed an issue with the original cron scripts outputting the same date
over and over.

Closes #1
cronjob
Adasauce 5 years ago
parent 1efd54e56e
commit 8c5a109eb0
Signed by: adasauce
GPG Key ID: B4FD3151235211CB
  1. 20
      docker-compose.yml

@ -46,11 +46,29 @@ services:
while /bin/true; do
echo Starting cron
su -s "/bin/sh" -c "/usr/local/bin/php /var/www/html/cron.php" www-data
echo $$(date) - Running cron finished
echo \$$(date) - Running cron finished
sleep 900
done
EOF'
thumbnailer:
image: nextcloud:fpm-alpine
restart: always
volumes:
- nextcloud:/var/www/html
depends_on:
- app
entrypoint: |
sh -c 'sh -s <<EOF
trap "break;exit" SIGHUP SIGINT SIGTERM
while /bin/true; do
echo Starting thumbnail cron
su -s "/bin/sh" -c "/usr/local/bin/php occ preview:pre-generate" www-data
echo \$$(date) - Running thumbnail cron finished
sleep 60
done
EOF'
proxy:
build: ./proxy
restart: always

Loading…
Cancel
Save