16 lines
617 B
Bash
16 lines
617 B
Bash
# curl -sL https://deb.nodesource.com/setup_10.x | bash -
|
|
wget --quiet -O - https://deb.nodesource.com/gpgkey/nodesource.gpg.key | sudo apt-key add -
|
|
|
|
VERSION=node_10.x
|
|
#DISTRO="$(lsb_release -s -c)"
|
|
DISTRO="testing"
|
|
|
|
AVAILABLE=/etc/apt/sources.list-available
|
|
|
|
echo "deb https://deb.nodesource.com/$VERSION $DISTRO main" | sudo tee /etc/apt/${AVAILABLE}/nodesource.list
|
|
echo "deb-src https://deb.nodesource.com/$VERSION $DISTRO main" | sudo tee -a /etc/apt/${AVAILABLE}/nodesource.list
|
|
ln -s /etc/apt/${AVAILABLE}/nodesource.list /etc/apt/sources.list.d/nodesource.list
|
|
|
|
sudo apt-get update
|
|
apt-get install -y nodejs
|