From bc51867f1cfc13185681b01e2dd8f48f0f7fdeb9 Mon Sep 17 00:00:00 2001 From: Bruno Wagner Date: Wed, 3 Dec 2014 17:04:06 -0200 Subject: Updated vagrant box because bower and bundle doesn't like to be run as root --- install-pixelated.sh | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'install-pixelated.sh') diff --git a/install-pixelated.sh b/install-pixelated.sh index 62e78703..a3ffb3e2 100755 --- a/install-pixelated.sh +++ b/install-pixelated.sh @@ -16,6 +16,13 @@ # along with Pixelated. If not, see . # test dependencies + + +if [ ! $USERNAME ] +then + export USERNAME=`whoami` +fi + function check_installed() { which $1 if [ $? -ne 0 ]; then @@ -31,9 +38,10 @@ done # install web-ui dependencies cd web-ui +UIPATH=`pwd` npm install -node_modules/bower/bin/bower install --config.interactive=false -bundle install +su - $USERNAME -c "(cd $UIPATH; node_modules/bower/bin/bower install --config.interactive=false)" +su - $USERNAME -c "(cd $UIPATH; bundle install)" LC_ALL=en_US.UTF-8 ./go build # install service dependencies -- cgit v1.2.3