From 6b61e34a205c0b5fbc75442bcff3cd789ccd60d3 Mon Sep 17 00:00:00 2001 From: Christopher Date: Tue, 22 Aug 2023 11:21:46 -0500 Subject: [PATCH] Error out if runtipi is installed --- runtipi/install.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/runtipi/install.sh b/runtipi/install.sh index 694cf17..5e611f9 100644 --- a/runtipi/install.sh +++ b/runtipi/install.sh @@ -21,9 +21,16 @@ function run_install_dependencies() { # Install Runtipi function run_install_runtipi() { + # Check if Runtipi is already installed if [[ -d "$RUNTIPI_PATH" ]]; then - echo "Runtipi is already installed at $RUNTIPI_PATH." + error_out "Runtipi is already installed at $RUNTIPI_PATH." fi + + # Check if Runtipi container is running + if docker ps | grep -q "runtipi"; then + error_out "Runtipi container is running." + fi + # CD into the Runtipi directory cd /opt # Download the script first