bitwalker/distillery

Usage of --name prevents app from starting

farao opened this issue · 0 comments

farao commented

When I'm using a non-default distillery release (one that I added myself to rel/config.exs), I can't get my application to start with the generated release scripts. A minimal example is:

  • create new mix project (e.g. test) and add distillery to mix.exs deps
  • make application startable:
    • add mod: {Test, []} to the list returned by the function application in mix.exs
    • add use Application and a function start(_,_) that e.g. prints a test string to lib/test.ex
  • run mix distillery.init
  • add a second release, e.g. test2 to the end of rel/config.exs by simply copying and renaming the generated release :test entry

Now:
A) when running mix distillery.release; _build/dev/rel/test/bin/test foreground everything works well and I see the printed string from the start function
B) when running mix distillery.release --name test2; _build/dev/rel/test/bin/test2 foreground the release command succeeds but the foreground command does not print anything.

I'm running Elixir 1.8.1 on an up to date Archlinux and Distillery 2.1.1.

Files (for reference):