crazy-max/docker-nextcloud

Cron change directory error preventing start

pageb018 opened this issue · 1 comments

Behaviour

Steps to reproduce this issue

  1. Try starting the stack by running docker-compose up -d
  2. Tail the logs and notice cron errors
  3. Nextcloud will not start

Expected behaviour

Nextcloud should start as normal.

Actual behaviour

containers exit with various exit codes

Configuration

  • Docker version (type docker --version) : 23.0.1
  • Docker compose version if applicable (type docker-compose --version) : 2.16.0
  • Platform (Debian 9, Ubuntu 18.04, ...) : Debian LXC
  • System info (type uname -a) :
  • Include all necessary configuration files : docker-compose, .env, nextcloud.env all copied direct from examples.

I should not that the stack had been running correctly for months without issue. This was new after a reboot.

Container logs (set LOG_LEVEL to debug if applicable)

nextcloud_cron        | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_previewgen  | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_cron        | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_previewgen  | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_cron        | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_previewgen  | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_cron        | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_previewgen  | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_cron        | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_previewgen  | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_cron        | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_previewgen  | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_cron        | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_previewgen  | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory
nextcloud_cron        | crond: can't change directory to '/var/spool/cron/crontabs': No such file or directory

I can't repro on my side. This folder is created on startup:

mkdir -m 0644 -p ${CRONTAB_PATH}
So not sure how it happens.

Would need repro to help if you still have this issue (compose file).