Fixed problems with install script with and without privilege

- Added the `allow-root` flag to the `bower install` to fix the error that occurs when you run `npm install` with privilege: https://github.com/xtuple/xtuple-server/issues/241.
- Added `sudo` and moved the bower global install above this line `sudo chown -R $USER $HOME/.npm` to fix the problem running the install script without privilege.