Intermesh / docker-groupoffice

Docker image for Group-Office groupware
https://www.group-office.com
MIT License
25 stars 16 forks source link

Cron not run with docker-compose #10

Closed barryvdh closed 2 years ago

barryvdh commented 2 years ago

I installed the package with docker-compose, but I keep getting this notice:

The main cron job doesn't appear to be running. Please add a cron job: * www-data php /usr/local/share/groupoffice/cron.php /etc/groupoffice/config.php

Do I need to manually configure the cron in docker-composer.yml?

mschering commented 2 years ago

Hi,

I've updated the README.md with instructions for the cronjob:

https://github.com/Intermesh/docker-groupoffice/blob/master/README.md

barryvdh commented 2 years ago

Thanks! Is the first docker-exec right? Shouldn't it just be:

* * * * * root cd /path/to/docker-groupoffice && docker-compose exec groupoffice php /usr/local/share/groupoffice/cron.php
barryvdh commented 2 years ago

And also docker-compose -T to make it non-interactive.

mschering commented 2 years ago

Sorry, I was a bit too quick with editing the command. You're absolutely right. I've changed it accordingly. Thanks!

albertvisuals commented 11 months ago

I am trying to get the cron running without any luck. I am using Portainer to deploy the stacks.

Portainer saves the Yaml file to /var/lib/docker/volumes/portainer_data/_data/compose/12/docker-compose.yml Where 12 is the id of the group office stack.

I have tried to add * root cd /var/lib/docker/volumes/portainer_data/_data/compose/12 && docker compose exec -T groupoffice-groupoffice-1 php /usr/local/share/groupoffice/cron.php to the cron-tab but I still get the error "no cron running" within group-office.

groupoffice-groupoffice-1 is the name of the container.

Anybody an idea how to get this to work? Thanks a lot!