mirror of
https://github.com/OneUptime/oneuptime.git
synced 2026-04-06 00:32:12 +02:00
change DISTRIB to global var
This commit is contained in:
@@ -27,7 +27,7 @@ fi
|
||||
|
||||
# If linux
|
||||
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
|
||||
local DISTRIB=$(awk -F= '/^ID/{print $2}' /etc/os-release)
|
||||
DISTRIB=$(awk -F= '/^ID/{print $2}' /etc/os-release)
|
||||
if [[ ${DISTRIB} = "ubuntu"* ]]; then
|
||||
echo "Grabbing latest apt caches"
|
||||
sudo apt-get update
|
||||
@@ -42,7 +42,7 @@ fi
|
||||
echo "Installing OneUptime 🟢"
|
||||
if [[ ! $(which git) ]]; then
|
||||
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
|
||||
local DISTRIB=$(awk -F= '/^ID/{print $2}' /etc/os-release)
|
||||
DISTRIB=$(awk -F= '/^ID/{print $2}' /etc/os-release)
|
||||
if [[ ${DISTRIB} = "ubuntu"* ]] || [[ ${DISTRIB} = "debian"* ]]; then
|
||||
sudo apt install -y git
|
||||
elif [[ ${DISTRIB} = "fedora"* ]] || [[ ${DISTRIB} = "almalinux"* ]] || [[ ${DISTRIB} = "rockylinux"* ]] || [[ ${DISTRIB} = "rhel"* ]]; then
|
||||
@@ -102,7 +102,7 @@ fi
|
||||
|
||||
if [[ ! $(which git) ]]; then
|
||||
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
|
||||
local DISTRIB=$(awk -F= '/^ID/{print $2}' /etc/os-release)
|
||||
DISTRIB=$(awk -F= '/^ID/{print $2}' /etc/os-release)
|
||||
if [[ ${DISTRIB} = "ubuntu"* ]] || [[ ${DISTRIB} = "debian"* ]]; then
|
||||
echo "Setting up NPM"
|
||||
sudo apt-get install -y npm
|
||||
|
||||
Reference in New Issue
Block a user