Debian is a great linux distribution, and Docker is a great tool to
have installed. Installing Docker on Debian is straightforward
as described on docs.docker.com.
If you would like to forgo the manual CLI process described in the documentation,
I have written a script that will carry out the process for you. All you need
to do is run the script and provide the sudo password when prompted.
Docker is central to how I work on some of my projects, but I like the option to
remove Docker if I have a dedicated system to run those workloads off of my workstation.
Consequently, I end up having to install Docker again. Each time, I pull up the docker docs
webpage next to a terminal emulator and copy the lines in as described. Not a big deal at all,
but I have probably done this 12+ times now, and I am ready to have executable code on the
internet that I can safely execute to accomplish this task.
I’d use this script to install docker engine on a fresh Debian 12 system, or I may use
it to install docker engine after purging a system of old project files.
I would like to adapt the code such that it can work on debian-based distros: Ubuntu, Mint, Kali,
etc. As is, you will need to modify /etc/apt/sources.list.d/docker.list.