I'm trying to push a Node.js application to Heroku. The app uses npm to fetch private github repositories, which are specified in
remote: npm ERR! Host key verification failed.
It turns out that there is a buildpack that makes this relatively easy -
However, I found that, for whatever reason, setting the
SSH_HOSTS environment variable was not working correctly for me - according to the docs, it is supposed to set Github by default, and then you can add others if you like... I am actually using Gitlab for this particular project, but found that when I set the config like so:
$ heroku config:set SSH_HOSTS="[email protected]"
it was not being detected. I ended up cloning the buildpack and changing
bin/compile line 13 to
and just pushing it up to my own repo to use for this project. Worked like a charm.