Files
docker-install-script/docker-install-script.sh
Alexander Schulz f43fee4484 chore(docker): update Ubuntu installation to current official Docker setup
- switch Docker APT repo config from docker.list to docker.sources
- keep GPG key in /etc/apt/keyrings/docker.asc
- remove installation of legacy docker-compose package
- use docker-compose-plugin as the recommended Compose integration
- add cleanup of old/conflicting Docker-related packages before install
- align installation steps with current Docker documentation for Ubuntu
2026-03-28 17:44:22 +01:00

21 lines
812 B
Bash

# Remove old/conflicting packages first if they exist
sudo apt remove docker.io docker-compose docker-compose-v2 docker-doc podman-docker containerd runc
sudo apt update
sudo apt install ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc
sudo tee /etc/apt/sources.list.d/docker.sources > /dev/null <<EOF
Types: deb
URIs: https://download.docker.com/linux/ubuntu
Suites: $(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}")
Components: stable
Architectures: $(dpkg --print-architecture)
Signed-By: /etc/apt/keyrings/docker.asc
EOF
sudo apt update
sudo apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin