Distillery release fails: Could not locate code path for m{elixir-1.7.2","./lib/elixir-1.7.2

208 Views Asked by At

I'm trying to deploy my application on Gigalixir, following the getting started with an existing app.

I have added [{:distillery, "~> 2.1"}] to my mix.deps

building the release for production

SECRET_KEY_BASE="$(mix phx.gen.secret)" 
DATABASE_URL="postgresql://postgres:postgres@localhost:5432/rumbl_dev"
MIX_ENV=prod
mix distillery.release --env=prod

But then I run _build/prod/rel/rumbl/bin/rumbl start, and that fails with

Could not locate code path for m{elixir-1.7.2","./lib/elixir-1.7.2!

Any ideas what could be going on?

2

There are 2 best solutions below

2
On BEST ANSWER

You should compare elixir version in your mix file and version installed at the server.

0
On

On MacOS, the command "unset GREP_OPTIONS" solved this issue for me. I found this issue is relevant to the wrong return value of function __rel_apps() in phoenix/{your-app}/_build/prod/rel/{your-app}/releases/{your-version}/libexec/erts.sh. Then, the solution is referenced from underlying link.

https://github.com/bitwalker/distillery/issues/592