dpkgs -s instead of dpkg -l

This commit is contained in:
julien
2025-10-03 15:33:10 +02:00
parent b1f8257e31
commit 7011d22394
4 changed files with 5 additions and 5 deletions

View File

@@ -4,7 +4,8 @@ echo
echo " => Docker"
echo
if [ ! -f /usr/bin/docker ]; then
dpkg -s docker > /dev/null 2>&1
if [ $? -ne 0 ]; then
# Add Docker's official GPG key
mkdir -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg --yes
@@ -20,4 +21,3 @@ if [ ! -f /usr/bin/docker ]; then
# Install packages
apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin -y
fi