소스 검색

Code refactoring

tteckster 2 년 전
부모
커밋
0101449dda
5개의 변경된 파일20개의 추가작업 그리고 25개의 파일을 삭제
  1. 4 5
      install/cronicle-install.sh
  2. 4 5
      install/magicmirror-install.sh
  3. 4 5
      install/meshcentral-install.sh
  4. 4 5
      install/n8n-install.sh
  5. 4 5
      install/wikijs-install.sh

+ 4 - 5
install/cronicle-install.sh

@@ -23,12 +23,11 @@ $STD apt-get install -y g++
 $STD apt-get install -y gcc
 msg_ok "Installed Dependencies"
 
-msg_info "Setting up Node.js Repository"
-$STD bash <(curl -fsSL https://deb.nodesource.com/setup_16.x)
-msg_ok "Set up Node.js Repository"
-
 msg_info "Installing Node.js"
-$STD apt-get install -y nodejs
+$STD bash <(curl -fsSL https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh)
+. ~/.bashrc
+$STD nvm install 16.20.1
+ln -sf /root/.nvm/versions/node/v16.20.1/bin/node /usr/bin/node
 msg_ok "Installed Node.js"
 
 msg_info "Installing Cronicle Primary Server"

+ 4 - 5
install/magicmirror-install.sh

@@ -20,12 +20,11 @@ $STD apt-get install -y mc
 $STD apt-get install -y git
 msg_ok "Installed Dependencies"
 
-msg_info "Setting up Node.js Repository"
-$STD bash <(curl -fsSL https://deb.nodesource.com/setup_16.x)
-msg_ok "Set up Node.js Repository"
-
 msg_info "Installing Node.js"
-$STD apt-get install -y nodejs
+$STD bash <(curl -fsSL https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh)
+. ~/.bashrc
+$STD nvm install 16.20.1
+ln -sf /root/.nvm/versions/node/v16.20.1/bin/node /usr/bin/node
 msg_ok "Installed Node.js"
 
 msg_info "Setting up MagicMirror Repository"

+ 4 - 5
install/meshcentral-install.sh

@@ -19,12 +19,11 @@ $STD apt-get install -y sudo
 $STD apt-get install -y mc
 msg_ok "Installed Dependencies"
 
-msg_info "Setting up Node.js Repository"
-$STD bash <(curl -fsSL https://deb.nodesource.com/setup_16.x)
-msg_ok "Set up Node.js Repository"
-
 msg_info "Installing Node.js"
-$STD apt-get install -y nodejs
+$STD bash <(curl -fsSL https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh)
+. ~/.bashrc
+$STD nvm install 16.20.1
+ln -sf /root/.nvm/versions/node/v16.20.1/bin/node /usr/bin/node
 msg_ok "Installed Node.js"
 
 msg_info "Installing MeshCentral"

+ 4 - 5
install/n8n-install.sh

@@ -19,12 +19,11 @@ $STD apt-get install -y sudo
 $STD apt-get install -y mc
 msg_ok "Installed Dependencies"
 
-msg_info "Setting up Node.js Repository"
-$STD bash <(curl -fsSL https://deb.nodesource.com/setup_16.x)
-msg_ok "Set up Node.js Repository"
-
 msg_info "Installing Node.js"
-$STD apt-get install -y nodejs
+$STD bash <(curl -fsSL https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh)
+. ~/.bashrc
+$STD nvm install 16.20.1
+ln -sf /root/.nvm/versions/node/v16.20.1/bin/node /usr/bin/node
 msg_ok "Installed Node.js"
 
 msg_info "Installing n8n (Patience)"

+ 4 - 5
install/wikijs-install.sh

@@ -20,12 +20,11 @@ $STD apt-get install -y mc
 $STD apt-get install -y git
 msg_ok "Installed Dependencies"
 
-msg_info "Setting up Node.js Repository"
-$STD bash <(curl -fsSL https://deb.nodesource.com/setup_16.x)
-msg_ok "Set up Node.js Repository"
-
 msg_info "Installing Node.js"
-$STD apt-get install -y nodejs
+$STD bash <(curl -fsSL https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh)
+. ~/.bashrc
+$STD nvm install 16.20.1
+ln -sf /root/.nvm/versions/node/v16.20.1/bin/node /usr/bin/node
 msg_ok "Installed Node.js"
 
 msg_info "Installing Wiki.js"