Merge pull request #5311 from lonyai/next

Update install.sh for rhel|centos
This commit is contained in:
Andras Bacsai 2025-03-10 18:23:40 +01:00 committed by GitHub
commit 991bbb1bbe
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -336,13 +336,13 @@ if ! [ -x "$(command -v docker)" ]; then
exit 1
fi
;;
"fedora")
"centos" | "fedora" | "rhel")
if [ -x "$(command -v dnf5)" ]; then
# dnf5 is available
dnf config-manager addrepo --from-repofile=https://download.docker.com/linux/fedora/docker-ce.repo --overwrite >/dev/null 2>&1
dnf config-manager addrepo --from-repofile=https://download.docker.com/linux/$OS_TYPE/docker-ce.repo --overwrite >/dev/null 2>&1
else
# dnf5 is not available, use dnf
dnf config-manager --add-repo=https://download.docker.com/linux/fedora/docker-ce.repo >/dev/null 2>&1
dnf config-manager --add-repo=https://download.docker.com/linux/$OS_TYPE/docker-ce.repo >/dev/null 2>&1
fi
dnf install -y docker-ce docker-ce-cli containerd.io docker-compose-plugin >/dev/null 2>&1
if ! [ -x "$(command -v docker)" ]; then