Skip to content
Advertisement

Heroku buildpack: permission denied on npm install in bash script

I am creating a Heroku build pack and getting an npm permission denied when deploying with the build pack. Here’s the error from the build logs, permission denied when running npm install:

JavaScript

I am packaging npm in a tar.gz and using that.

In my compile file:

JavaScript

Advertisement

Answer

Is it possible that either npm or node is missing the executable bit either when you package them up or when you untar them? That’s what this “permission denied” error looks like to me.

Can you test this locally at all?

Also, are you depending on node 0.10.29 for a particular reason? I ask because the latest stable node is 0.10.36 and it contains some important security fixes. (They may not affect you, though.)

User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement