I recently encountered an issue while testing my Phoenix Framework project with Travis CI. Initially, everything was running smoothly with only Elixir tests.
However, when I attempted to add some JavaScript tests, I ran into a roadblock. The problem stemmed from the fact that I couldn't resolve phoenix
and phoenix_html
due to them being linked to local Phoenix dependencies in my package.json
:
"dependencies": {
"ava": "^0.18.2",
...
"phoenix": "file:deps/phoenix",
"phoenix_html": "file:deps/phoenix_html",
"react": "^15.4.2"
...
},
This resulted in a crash on Travis due to a permission issue:
...
The command "mix test" exited with 0.
1.37s$ npm install
-\npm ERR! git clone github.com/file/deps/phoenix Cloning into bare repository '/home/travis/.npm/_git-remotes/git-github-com-file-deps-phoenix-c83d6c1a'...
npm ERR! git clone github.com/file/deps/phoenix Warning: Permanently added the RSA host key for IP address '192.30.253.112' to the list of known hosts.
npm ERR! git clone github.com/file/deps/phoenix Permission denied (publickey).
npm ERR! git clone github.com/file/deps/phoenix fatal: Could not read from remote repository.
\npm ERR! git clone github.com/file/deps/phoenix_html Cloning into bare repository '/home/travis/.npm/_git-remotes/git-github-com-file-deps-phoenix-html-50a27b71'...
npm ERR! git clone github.com/file/deps/phoenix_html Permission denied (publickey).
npm ERR! git clone github.com/file/deps/phoenix_html fatal: Could not read from remote repository.
npm ERR! notarget No compatible version found: react-hot-loader@'>=4.0.0-0 <5.0.0-0'
...