Jellyseerr: better handling of node and pnpm (#4365)

* Jellyseerr: better handling of node and pnpm

* Update jellyseerr.sh
This commit is contained in:
CanbiZ
2025-05-10 08:42:45 +02:00
committed by GitHub
parent 456b00882d
commit 1e59c934ec
2 changed files with 4 additions and 16 deletions

View File

@@ -53,10 +53,10 @@ function update_script() {
if [ -z "$pnpm_current" ]; then
msg_error "pnpm not found. Installing version $pnpm_desired..."
$STD npm install -g pnpm@"$pnpm_desired"
NODE_VERSION="22" NODE_MODULE="pnpm@$pnpm_desired" install_node_and_modules
elif ! node -e "const semver = require('semver'); process.exit(semver.satisfies('$pnpm_current', '$pnpm_desired') ? 0 : 1)"; then
msg_error "Updating pnpm from version $pnpm_current to $pnpm_desired..."
$STD npm install -g pnpm@"$pnpm_desired"
NODE_VERSION="22" NODE_MODULE="pnpm@$pnpm_desired" install_node_and_modules
else
msg_ok "pnpm is already installed and satisfies version $pnpm_desired."
fi
@@ -103,4 +103,4 @@ description
msg_ok "Completed Successfully!\n"
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
echo -e "${INFO}${YW} Access it using the following URL:${CL}"
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:5055${CL}"
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:5055${CL}"