mirror of
https://github.com/photoprism/photoprism.git
synced 2025-12-12 00:34:13 +01:00
Docker: Set explicit PATH in dist scripts #2125
This commit is contained in:
6
scripts/dist/install-nodejs.sh
vendored
6
scripts/dist/install-nodejs.sh
vendored
@@ -1,5 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
PATH="/usr/local/sbin/:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin:/scripts"
|
||||
|
||||
# abort if not executed as root
|
||||
if [[ $(id -u) != "0" ]]; then
|
||||
echo "Usage: run ${0##*/} as root" 1>&2
|
||||
@@ -12,8 +14,8 @@ SETUP_URL="https://deb.nodesource.com/setup_16.x"
|
||||
|
||||
echo "Installing NodeJS and NPM from \"$SETUP_URL\"..."
|
||||
|
||||
/usr/bin/curl -sL $SETUP_URL | /bin/bash -
|
||||
/usr/bin/apt-get update && /usr/bin/apt-get -qq install nodejs
|
||||
curl -sL $SETUP_URL | bash -
|
||||
apt-get update && apt-get -qq install nodejs
|
||||
npm install --unsafe-perm=true --allow-root -g npm testcafe
|
||||
npm config set cache ~/.cache/npm
|
||||
|
||||
|
||||
Reference in New Issue
Block a user