remove custom node install in use-git admin as bookworm default is now v18

This commit is contained in:
axolotle 2023-11-11 13:41:43 +01:00
parent e8338eb754
commit fbe8f38b5e

18
ynh-dev
View file

@ -335,24 +335,6 @@ with open(setting_file) as f:
EOF
fi
# Vite require node v14 to parse modern syntax
if [[ ! $(node -v) == v14* ]]
then
DISTRO="$(lsb_release -s -c)"
if [ "$DISTRO" == "buster" ]; then
info "Installing node v14..."
KEYRING=/usr/share/keyrings/nodesource.gpg
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource.gpg.key | gpg --dearmor | sudo tee "$KEYRING" >/dev/null
gpg --no-default-keyring --keyring "$KEYRING" --list-keys
VERSION=node_14.x
echo "deb [signed-by=$KEYRING] https://deb.nodesource.com/$VERSION $DISTRO main" | sudo tee /etc/apt/sources.list.d/nodesource.list
fi
apt-get update
apt install nodejs -y
# to return to nodejs debian version
# apt purge nodejs && rm -r /etc/apt/sources.list.d/nodesource.list && apt install nodejs
fi
# Install dependencies with npm install (or rather npm ci)
if [[ -e "/var/cache/ynh-dev/yunohost-admin/node_modules/vue" ]];
then