Docker image for running cron jobs.
1.6K
Docker image for running cron jobs.
In order to create cron jobs add environment properties that start with 'CRON_' (the name must be unique) and have the value with the format <cron-value> <command>.
The cron commands output can be found in '/var/log/cron.log' .
docker run --rm -e CRON_SAMPLE="* * * * * echo 1 minute cron" tigefa/crontab
services:
cron:
image: tigefa/crontab
container_name: crontab
environment:
CRON_SAMPLE: '* * * * * echo 1 minute cron'
CRON_ANOTHER_SAMPLE: '*/5 * * * * echo 5 minute cron'
CRON_ERROR_SAMPLE: '*/3 * * * * no-valid-command'
Check logs
docker logs -f crontab
Content type
Image
Digest
sha256:4fc758815…
Size
35.1 MB
Last updated
4 months ago
docker pull tigefa/crontab