Hi there ! @chalk4, I know it’s been a long time since the last answer, but did you find a way to make it work ? I have the same problem with Nextcloud on OMV.
Thanks !
Hi there!
I also had this problem. I couldn’t make cron task in docker, but I wrote command, which execute pre-generator from host machine.
You need use root crontab on host machine and create job:
* * * * * ~/cron_generator.sh
Text of “~/cron_generator.sh”:
PATH=$PATH:/bin:/usr/bin:/usr/sbin
SHELL=/bin/bash
docker exec -u 1000:1000 nextcloud bash -c “php /nextcloud/occ preview:pre-generate”
P.S. You can add task every minute, because you can’t execute more, than one instance. Or do it how you want)
P.S. In my situation, user 1000:1000 was owner of config.php. In your situation may be another, check it using ‘ls -la’
ENJOY!