Instead of using a cronjob placed in our crontab, we can make use of a systemd timer on a modern linux system which is running systemd.
For a systemd timer to work, it needs two parts.
One part consists of a .timer
file, and a .service
file.
The .timer
file specifies when our service should be started. Just like a cronjob we can specify here on which days, in which week or at which time our service should be started.
Our .service
file contains all the details about the script or command we want to run.
In this guide we are going to install Docker on Debian 10 Buster. To be able to use Docker to its full extent, we also install docker-compose.
There are two ways to install the Docker Engine, one with a regular apt install
and one with an install script made by docker.