Mount crontab file with docker volume into /var/spool/cron/crontabs/root
Please make sure your crontab file is owned by root with permissions 0644 and your crontab file ends with empty line.
Image has preinstalled wget.
version: '2'
services:
cron:
image: zafan/cron
volumes:
- /etc/localtime:/etc/localtime:ro
- /<path to file>/crontab:/var/spool/cron/crontabs/root
user: root
restart: always
Content type
Image
Digest
Size
2.2 MB
Last updated
over 8 years ago
docker pull zafan/cron