airsonos icon indicating copy to clipboard operation
airsonos copied to clipboard

Installation failed with newest node version

Open deluxestyle opened this issue 8 years ago • 6 comments

I try to install airsonos on my PI 2 on Stretch and node v.8.9.1

But I always get below error message: fatal: could not create leading directories of '/root/.npm/_cacache/tmp/git-clone-a694fbc7': Permission denied

Any ideas?

deluxestyle avatar Nov 20 '17 19:11 deluxestyle

Have you tried putting sudo before whatever command gets that error?

aalexsmithh avatar Dec 17 '17 01:12 aalexsmithh

yes. but nothing changes

deluxestyle avatar Dec 28 '17 17:12 deluxestyle

Same issue for me

davidvermillion avatar Jan 10 '18 07:01 davidvermillion

Was able to make progress by doing option 2 from here:

https://docs.npmjs.com/getting-started/fixing-npm-permissions

davidvermillion avatar Jan 10 '18 07:01 davidvermillion

I can't speak towards changing the install directory or the using an installation manager mentioned in the link above. I had a working system on node.js 4.x I upgraded to 8.x. I was then unable to run airsonos due to errors about the nodetunes and nicercast modules being compiled against a different version of node.js. I used these commands to rebuild the modules on my system (raspPi 2): sudo npm install -g --unsafe-perm nodetunes sudo npm install -g --unsafe-perm nicercast

This built new modules. Then I had to move the modules inside of airsonos out of the way and symlink the newly built modules in place: sudo mv /usr/lib/node_modules/airsonos/node_modules/nodetunes/ /usr/lib/node_modules/airsonos/node_modules/nodetunes_old sudo mv /usr/lib/node_modules/airsonos/node_modules/nicercast/ /usr/lib/node_modules/airsonos/node_modules/nicercast_old

sudo ln -s /usr/lib/node_modules/nodetunes/ /usr/lib/node_modules/airsonos/node_modules/ sudo ln -s /usr/lib/node_modules/nicercast/ /usr/lib/node_modules/airsonos/node_modules/

that allowed me to start airsonos.

MitchellSingleton avatar Jan 13 '18 05:01 MitchellSingleton

Actually, airsonos started however I was getting a key length error and airsonos would die. I additionally applied these patches and now have a working system:

https://github.com/stephen/airsonos/issues/342#issuecomment-295770479

MitchellSingleton avatar Jan 13 '18 14:01 MitchellSingleton