1for pkg in docker.io docker-doc docker-compose docker-compose-v2 podman-docker containerd runc; do sudo apt-get remove $pkg; done
2
3
4sudo apt-get update
5sudo apt-get install ca-certificates curl gnupg
6sudo install -m 0755 -d /etc/apt/keyrings
7curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
8sudo chmod a+r /etc/apt/keyrings/docker.gpg
9
10
11echo \
12 "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
13 $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
14 sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
15sudo apt-get update
16
17sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
18