From c98e1a07a48021e632d3655ec06aec8dc5be24c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Yann=20M=C3=B6lle?= Date: Mon, 17 Apr 2023 20:40:17 +0200 Subject: [PATCH] =?UTF-8?q?=E2=80=9Einstall.sh=E2=80=9C=20=C3=A4ndern?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- install.sh | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/install.sh b/install.sh index 27ec2f5..f043500 100644 --- a/install.sh +++ b/install.sh @@ -10,14 +10,14 @@ install_docker_deb() { curl -fsSL https://download.docker.com/linux/${1}/gpg | sudo apt-key add - sudo add-apt-repository "deb [arch=$(dpkg --print-architecture)] https://download.docker.com/linux/${1} $(lsb_release -cs) stable" sudo apt-get update - sudo apt-get install -y docker-ce + sudo apt-get install -y docker-ce docker-ce-cli containerd.io || { echo "Unable to install 'docker-ce'. Exiting."; exit 1; } } # Function to install Docker on CentOS install_docker_centos() { sudo yum install -y yum-utils device-mapper-persistent-data lvm2 sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo - sudo yum install -y docker-ce + sudo yum install -y docker-ce docker-ce-cli containerd.io sudo systemctl enable docker sudo systemctl start docker } @@ -84,15 +84,4 @@ echo "Docker installed successfully." # Prompt user for Docker Compose installation while true; do - read -p "Do you want to install Docker Compose? (y/n): " yn - case $yn in - [Yy]* ) - echo "Installing Docker Compose..." - install_docker_compose - echo "Docker Compose installed successfully." - break - ;; - [Nn]* ) - echo "Skipping Docker Compose installation." - break - ;; \ No newline at end of file + read -p "Do you want to install Docker Compose? (y/n): "