https://github.com/tozd/docker-cron
Cron Docker image. Read-only mirror of https://gitlab.com/tozd/docker/cron
https://github.com/tozd/docker-cron
cron cron-jobs crontab docker docker-image
Last synced: 2 months ago
JSON representation
Cron Docker image. Read-only mirror of https://gitlab.com/tozd/docker/cron
- Host: GitHub
- URL: https://github.com/tozd/docker-cron
- Owner: tozd
- Created: 2017-01-31T04:39:57.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2025-06-04T12:21:56.000Z (about 1 year ago)
- Last Synced: 2025-07-05T22:40:25.241Z (12 months ago)
- Topics: cron, cron-jobs, crontab, docker, docker-image
- Language: Dockerfile
- Homepage:
- Size: 12.7 KB
- Stars: 1
- Watchers: 4
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
Awesome Lists containing this project
README
# tozd/cron
Available as:
- [`tozd/cron`](https://hub.docker.com/r/tozd/cron)
- [`registry.gitlab.com/tozd/docker/cron`](https://gitlab.com/tozd/docker/cron/container_registry)
## Image inheritance
[`tozd/base`](https://gitlab.com/tozd/docker/base) ← [`tozd/dinit`](https://gitlab.com/tozd/docker/dinit) ← [`tozd/mailer`](https://gitlab.com/tozd/docker/mailer) ← `tozd/cron`
See also [`tozd/nginx-cron`](https://gitlab.com/tozd/docker/nginx-cron).
## Tags
- `ubuntu-trusty`: cron 3.0pl1
- `ubuntu-xenial`: cron 3.0pl1
- `ubuntu-bionic`: cron 3.0pl1
- `ubuntu-focal`: cron 3.0pl1
- `ubuntu-jammy`: cron 3.0pl1
- `ubuntu-noble`: cron 3.0pl1
## Variables
- `MAILTO`: An e-mail address to which output from cron jobs is send.
## Description
Image providing support for cron jobs.
A suggested way to use this image is to extend it, add a program you want
to use in a cron job, and add a crontab file to `/etc/cron.d` directory
(or other cron crontab directories, like `/etc/cron.daily`).
You should set `MAILTO` environment variable to an e-mail address to which output from cron jobs should be send.
For e-mailing out of the container the image uses [nullmailer](http://untroubled.org/nullmailer/).
For it to work, you should set `ADMINADDR` environment variable to an e-mail address to which errors and failures should
go, and `REMOTES` to the e-mail relay server this image should be using to send e-mails.
When `cron` daemon runs, it stores its environment into `/dev/shm/cron-environment` file.
You cron scripts can then source this file (`. /dev/shm/cron-environment`) to gain access
to environment variables provided to Docker container. Only root processes can access this file.
## GitHub mirror
There is also a [read-only GitHub mirror available](https://github.com/tozd/docker-cron),
if you need to fork the project there.