Browse Source

Install bower as root

master
Bob Mottram 3 months ago
parent
commit
5b668dd67f
1 changed files with 8 additions and 7 deletions
  1. 8
    7
      src/freedombone-app-cryptpad

+ 8
- 7
src/freedombone-app-cryptpad View File

@@ -127,7 +127,9 @@ function upgrade_cryptpad {
cryptpad_create_config
npm upgrade
npm install
su -c 'npm install bower@1.8.4' - cryptpad
if [ ! -d "$CRYPTPAD_DIR/node_modules/bower/bin/bower" ]; then
npm install bower@1.8.8
fi
rm -rf $CRYPTPAD_DIR/.cache/bower
su -c './node_modules/bower/bin/bower install --config.interactive=false' - cryptpad
su -c './node_modules/bower/bin/bower update --config.interactive=false' - cryptpad
@@ -659,13 +661,7 @@ function install_cryptpad {

increment_app_install_progress

su -c 'npm install bower@1.8.4' - cryptpad

increment_app_install_progress

chown -R cryptpad:cryptpad $CRYPTPAD_DIR
su -c './node_modules/bower/bin/bower install --config.interactive=false' - cryptpad
su -c './node_modules/bower/bin/bower update --config.interactive=false' - cryptpad
cp config/config.example.js config/config.js
if [ ! -f config/config.js ]; then
echo $'Cryptpad config file not found'
@@ -710,7 +706,12 @@ function install_cryptpad {

# install again
cd $CRYPTPAD_DIR || exit 73
npm install bower@1.8.8
increment_app_install_progress
chown -R cryptpad:cryptpad $CRYPTPAD_DIR/node_modules/bower
su -c './node_modules/bower/bin/bower install --config.interactive=false' - cryptpad
increment_app_install_progress
su -c './node_modules/bower/bin/bower update --config.interactive=false' - cryptpad

increment_app_install_progress


Loading…
Cancel
Save