Skip to content

Commit

Permalink
show errors in install script
Browse files Browse the repository at this point in the history
  • Loading branch information
andrasbacsai committed Jun 10, 2024
1 parent 239f7fb commit e08dc77
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions scripts/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ set -e # Exit immediately if a command exits with a non-zero status
#set -u # Treat unset variables as an error and exit
set -o pipefail # Cause a pipeline to return the status of the last command that exited with a non-zero status

VERSION="1.3.2"
VERSION="1.3.3"
DOCKER_VERSION="26.0"

CDN="https://cdn.coollabs.io/coolify"
Expand Down Expand Up @@ -35,7 +35,7 @@ fi

# Install xargs on Amazon Linux 2023 - lol
if [ "$OS_TYPE" = 'amzn' ]; then
dnf install -y findutils >/dev/null 2>&1
dnf install -y findutils >/dev/null
fi

LATEST_VERSION=$(curl --silent $CDN/versions.json | grep -i version | xargs | awk '{print $2}' | tr -d ',')
Expand Down Expand Up @@ -75,28 +75,28 @@ echo "Installing required packages..."

case "$OS_TYPE" in
arch)
pacman -Sy >/dev/null 2>&1 || true
if ! pacman -Q curl wget git jq >/dev/null 2>&1; then
pacman -S --noconfirm curl wget git jq >/dev/null 2>&1 || true
pacman -Sy >/dev/null || true
if ! pacman -Q curl wget git jq >/dev/null; then
pacman -S --noconfirm curl wget git jq >/dev/null || true
fi
;;
ubuntu | debian | raspbian)
apt update -y >/dev/null 2>&1
apt install -y curl wget git jq >/dev/null 2>&1
apt update -y >/dev/null
apt install -y curl wget git jq >/dev/null
;;
centos | fedora | rhel | ol | rocky | almalinux | amzn)
if [ "$OS_TYPE" = "amzn" ]; then
dnf install -y wget git jq >/dev/null 2>&1
dnf install -y wget git jq >/dev/null
else
if ! command -v dnf >/dev/null 2>&1; then
yum install -y dnf >/dev/null 2>&1
if ! command -v dnf >/dev/null; then
yum install -y dnf >/dev/null
fi
dnf install -y curl wget git jq >/dev/null 2>&1
dnf install -y curl wget git jq >/dev/null
fi
;;
sles | opensuse-leap | opensuse-tumbleweed)
zypper refresh >/dev/null 2>&1
zypper install -y curl wget git jq >/dev/null 2>&1
zypper refresh >/dev/null
zypper install -y curl wget git jq >/dev/null
;;
*)
echo "This script only supports Debian, Redhat, Arch Linux, or SLES based operating systems for now."
Expand Down

0 comments on commit e08dc77

Please sign in to comment.