Debian 11 - Install Docker
Related Posts
- Install Docker Compose
- Ubuntu 20 - Install Docker
- Debian 12 - Install Docker
- Debian 10 - Install Docker
Steps
Run the following script to install docker on Debian 11.
#!/bin/bash
# Update the apt package index and install packages to allow apt to use a repository over HTTPS
sudo apt-get update
sudo apt-get install -y \
apt-transport-https \
ca-certificates \
curl \
gnupg-agent \
software-properties-common
# Add Docker's official GPG key:
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo apt-key add -
sudo add-apt-repository \
"deb [arch=amd64] https://download.docker.com/linux/debian \
$(lsb_release -cs) \
stable"
# Install docker
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io -y
# Add yourself to the docker group so you can run docker commands
# without sudo
sudo adduser $USER docker
References
Last updated: 26th June 2023
First published: 20th August 2021
First published: 20th August 2021