From 411b88aa54812d7b7eb5a2e7bd723b5e2cf0936b Mon Sep 17 00:00:00 2001 From: Moe Date: Tue, 5 Sep 2023 11:11:59 -0700 Subject: [PATCH] Dindai Hollow + : Critical Fixes+ --- INSTALL/CentOS - Quick Install.sh | 3 ++- INSTALL/rocky9-touchless.sh | 3 ++- INSTALL/ubuntu-easyinstall.sh | 3 ++- INSTALL/ubuntu-touchless-iso.sh | 3 ++- INSTALL/ubuntu-touchless.sh | 4 ++-- INSTALL/ubuntu.sh | 3 ++- 6 files changed, 12 insertions(+), 7 deletions(-) diff --git a/INSTALL/CentOS - Quick Install.sh b/INSTALL/CentOS - Quick Install.sh index 1fb92339..7bed5f90 100644 --- a/INSTALL/CentOS - Quick Install.sh +++ b/INSTALL/CentOS - Quick Install.sh @@ -2,6 +2,7 @@ #Identify version of CentOS version=$(rpm --eval %{centos_ver}) +DIR=$(dirname $0) #Set script to use dnf or yum if [ "$version" = 7 ]; then @@ -85,7 +86,7 @@ echo "=========================================================" #Check if Node.js is installed if ! [ -x "$(command -v node)" ]; then echo "Node.js not found, installing..." - sh nodejs-redhat.sh + sh $DIR/nodejs-redhat.sh else echo "Node.js is already installed..." echo "Version: $(node -v)" diff --git a/INSTALL/rocky9-touchless.sh b/INSTALL/rocky9-touchless.sh index 33cf2246..c9a9a68b 100644 --- a/INSTALL/rocky9-touchless.sh +++ b/INSTALL/rocky9-touchless.sh @@ -1,4 +1,5 @@ #!/bin/bash +DIR=$(dirname $0) if ! [ -x "$(command -v dnf)" ]; then echo 'This installer does not run on systems without "dnf" package manager. Try "CentOS - Quick Install"' exit 1 @@ -44,7 +45,7 @@ echo "=========================================================" #Check if Node.js is installed if ! [ -x "$(command -v node)" ]; then echo "Node.js not found, installing..." - sh nodejs-redhat.sh + sh $DIR/nodejs-redhat.sh else echo "Node.js is already installed..." echo "Version: $(node -v)" diff --git a/INSTALL/ubuntu-easyinstall.sh b/INSTALL/ubuntu-easyinstall.sh index 24923370..4b4568b3 100644 --- a/INSTALL/ubuntu-easyinstall.sh +++ b/INSTALL/ubuntu-easyinstall.sh @@ -1,9 +1,10 @@ #!/bin/bash +DIR=$(dirname $0) echo "Shinobi - Do you want to Install Node.js?" echo "(y)es or (N)o" read -r nodejsinstall if [ "$nodejsinstall" = "y" ]; then - sh nodejs-ubuntu.sh + sh $DIR/nodejs-ubuntu.sh fi #Detect Ubuntu Version diff --git a/INSTALL/ubuntu-touchless-iso.sh b/INSTALL/ubuntu-touchless-iso.sh index 3984e0b3..1d24977f 100644 --- a/INSTALL/ubuntu-touchless-iso.sh +++ b/INSTALL/ubuntu-touchless-iso.sh @@ -1,4 +1,5 @@ #!/bin/bash +DIR=$(dirname $0) echo "=========================================================" echo "==!! Shinobi : The Open Source CCTV and NVR Solution !!==" echo "=========================================================" @@ -51,7 +52,7 @@ fi if ! [ -x "$(command -v node)" ]; then echo "=============" echo "Shinobi - Installing Node.js" - sh nodejs-ubuntu.sh + sh $DIR/nodejs-ubuntu.sh else echo "Node.js Found..." echo "Version : $(node -v)" diff --git a/INSTALL/ubuntu-touchless.sh b/INSTALL/ubuntu-touchless.sh index 32435895..d60a9fbc 100644 --- a/INSTALL/ubuntu-touchless.sh +++ b/INSTALL/ubuntu-touchless.sh @@ -1,4 +1,5 @@ #!/bin/bash +DIR=$(dirname $0) echo "=========================================================" echo "==!! Shinobi : The Open Source CCTV and NVR Solution !!==" echo "=========================================================" @@ -55,7 +56,7 @@ if ! [ -x "$(command -v ifconfig)" ]; then fi echo "=============" echo "Shinobi - Installing Node.js" -sh nodejs-ubuntu.sh +sh $DIR/nodejs-ubuntu.sh if ! [ -x "$(command -v npm)" ]; then sudo apt install npm -y fi @@ -89,7 +90,6 @@ sqluser="root" sudo mysql -e "source sql/user.sql" || true echo "=============" echo "Shinobi - Install NPM Libraries" -sudo npm i npm -g sudo npm install --unsafe-perm # sudo npm audit fix --force echo "=============" diff --git a/INSTALL/ubuntu.sh b/INSTALL/ubuntu.sh index 74217841..1570574d 100644 --- a/INSTALL/ubuntu.sh +++ b/INSTALL/ubuntu.sh @@ -1,4 +1,5 @@ #!/bin/bash +DIR=$(dirname $0) echo "=========================================================" echo "==!! Shinobi : The Open Source CCTV and NVR Solution !!==" echo "=========================================================" @@ -47,7 +48,7 @@ fi if ! [ -x "$(command -v node)" ]; then echo "=============" echo "Shinobi - Installing Node.js" - sh nodejs-ubuntu.sh + sh $DIR/nodejs-ubuntu.sh else echo "Node.js Found..." echo "Version : $(node -v)"