From 81fd548876e574c728bb540802336ee40d963797 Mon Sep 17 00:00:00 2001 From: Bozhidar Date: Tue, 14 May 2024 15:50:47 +0300 Subject: [PATCH] Update NodeJsInstaller.php --- web/app/Installers/Server/Applications/NodeJsInstaller.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/web/app/Installers/Server/Applications/NodeJsInstaller.php b/web/app/Installers/Server/Applications/NodeJsInstaller.php index e8b2d48..8e089e8 100644 --- a/web/app/Installers/Server/Applications/NodeJsInstaller.php +++ b/web/app/Installers/Server/Applications/NodeJsInstaller.php @@ -23,8 +23,10 @@ class NodeJsInstaller $commands = []; $commands[] = 'apt-get install -y npm'; foreach ($this->nodejsVersions as $nodejsVersion) { - $commands[] = 'apt-get install -y nodejs' . $nodejsVersion; + $commands[] = 'curl -sL https://deb.nodesource.com/setup_'.$nodejsVersion.'.x -o /tmp/nodesource'.$nodejsVersion.'_setup.sh'; + $commands[] = 'sudo bash /tmp/nodesource'.$nodejsVersion.'_setup.sh'; } + $commands[] = 'sudo apt-get install -y install nodejs'; // Install Apache Passenger $commands[] = 'curl https://oss-binaries.phusionpassenger.com/auto-software-signing-gpg-key.txt | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/phusion.gpg >/dev/null';