Etape 5 : Installation de Docker
Source:
ou
Prérequis (mise à jour et qq fonctions indispensables):
cd /
apt update && apt upgrade
apt install curl gpg
Récupérez la clée GPG officielle pour garantir la provenance de l'appli:
mkdir -m 0755 -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg
chmod a+r /etc/apt/keyrings/docker.gpg
Ajouter Docker aux sources-list du gestionnaire de packet APT
echo \
"deb [arch="$(dpkg --print-architecture)" signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian \
"$(. /etc/os-release && echo "$VERSION_CODENAME")" stable" | \
tee /etc/apt/sources.list.d/docker.list > /dev/null
Ca revient à écrire deb [arch=arm64 signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian bookworm stable dans le fichier /etc/apt/sources.list.d/docker.list
Mise à jour de APT et installation:
apt update
apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
QQ manip pour assurer que Docker soit lancé et activer le redémarrage automatique de Docker à l’allumage
sudo systemctl start docker
sudo systemctl enable docker
Vérifiez que Docker fonctionne :
docker run hello-world