Skip to content

Commit

Permalink
Updated Node install script
Browse files Browse the repository at this point in the history
  • Loading branch information
andris9 committed Jan 2, 2024
1 parent d7b27c6 commit 20e390d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
4 changes: 2 additions & 2 deletions setup/01_install_commits.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
OURNAME=01_install_commits.sh

apt-get update
apt-get install -y lsb-release curl gnupg
apt-get install -y lsb-release ca-certificates curl gnupg

NODEREPO="node_20.x"
NODE_MAJOR="20"
MONGODB="7.0"
CODENAME=`lsb_release -c -s`

Expand Down
9 changes: 6 additions & 3 deletions setup/04_install_import_keys.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,15 @@ export DEBIAN_FRONTEND=noninteractive
keyring="/usr/share/keyrings"

# nodejs
node_key_url="https://deb.nodesource.com/gpgkey/nodesource.gpg.key"
node_key_url="https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key"
local_node_key="${keyring}/nodesource.gpg"
curl -fsSL $node_key_url | gpg --dearmor | tee $local_node_key >/dev/null

echo "deb [signed-by=${local_node_key}] https://deb.nodesource.com/$NODEREPO $CODENAME main" > /etc/apt/sources.list.d/nodesource.list
echo "deb-src [signed-by=${local_node_key}] https://deb.nodesource.com/$NODEREPO $CODENAME main" >> /etc/apt/sources.list.d/nodesource.list
echo "deb [signed-by=${local_node_key}] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | sudo tee /etc/apt/sources.list.d/nodesource.list
echo "deb-src [signed-by=${local_node_key}] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | sudo tee /etc/apt/sources.list.d/nodesource.list

echo "deb [signed-by=${local_node_key}] https://deb.nodesource.com/$NODEREPO $CODENAME main" | sudo tee /etc/apt/sources.list.d/nodesource.list
echo "deb-src [signed-by=${local_node_key}] https://deb.nodesource.com/$NODEREPO $CODENAME main" | sudo tee /etc/apt/sources.list.d/nodesource.list

# mongodb
mongo_key_url="https://pgp.mongodb.com/server-${MONGODB}.asc"
Expand Down

0 comments on commit 20e390d

Please sign in to comment.