To run a cron job from within a docker container
Run a cron job in a docker container
Adapt this Dockerfile to your needs when running regular commands from within a Docker image.
This repo is inspired by this post from Julien Boulay
Run the image as is for a demo
sudo docker run -it patrickmerlot/cronjob_demo
Build the image
sudo docker build --rm -t patrickmerlot/cronjob_demo .
Sending reports/alert by email
Docker Pull Command