[Optional] Install packages to allow apt to use a repository over HTTPS:
Add Docker’s official GPG key:
Set up the repository:
Update the apt package index:
Install the latest version of Docker Engine - Community and containerd:
Check installed packages
Check installed packages:
Check Docker daemon (dockerd server):
Check Docker service:
Check containerd Service:
Verify Docker installation
Check Docker Version:
Print Docker Information:
Verify that Docker Engine - Community is installed correctly by running the hello-world image:
The command "docker run hello-world" downloads the hello-world image and runs it in a container.
When the container runs, it prints a "Hello from Docker!" message and exits.
Manage Docker service
To Enable/Disable Docker service (start on boot):
To Start/Stop Docker service:
Important Docker files/folders
Important folders/files: /var/lib/docker/ /etc/docker/key.json /lib/systemd/system/docker.service /lib/systemd/system/docker.socket /lib/systemd/system/containerd.service