Closed ulfurinn closed 6 years ago
Did not have the exact same trace output:
** (UndefinedFunctionError) function :relx.do/2 is undefined (module :relx is not available)
:relx.do([log_level: 3, root_dir: '/opt/hal/hal/apps/config', config: '/opt/hal/hal/apps/config/rel/.files/relx.config', relname: 'config', relvsn: '0.0.1', output_dir: '/opt/hal/hal/apps/config/rel', dev_mode
: false], ['release', 'tar'])
lib/exrm/utils/utils.ex:105: ReleaseManager.Utils.relx/5
lib/mix/tasks/release.ex:339: anonymous fn/4 in Mix.Tasks.Release.do_release/1
lib/ex_unit/capture_io.ex:146: ExUnit.CaptureIO.do_capture_io/2
lib/ex_unit/capture_io.ex:119: ExUnit.CaptureIO.do_capture_io/3
lib/mix/tasks/release.ex:338: Mix.Tasks.Release.do_release/1
lib/mix/tasks/release.ex:78: Mix.Tasks.Release.do_run/1
(mix) lib/mix/project.ex:211: Mix.Project.in_project/4
but suggestion to add exrm to each sub-app's dependencies worked.
To be fair, it is documented somewhere, although it is hidden. The trail is: readme -> full doc examples -> umbrella's example master app.
I don't see the other two apps to have exrm dependencies except the master app in the example. Also if the master is a phoenix app, the config must have the "server: true" set.
Setup: umbrella app requiring exrm and two sub-apps with just bare
mix new
skeletons1) running
mix release
from umbrella dies with:2) running
mix release
from a sub-app dies with "The task "release" could not be found", and the task is not displayed inmix help
The workaround is to require exrm in all sub-apps as well. This is not necessary with elixir 1.2. Looks like the ebin lookup behaviour changed.
Not sure if this is a bug in exrm or in mix itself. If this is not a bug at all, it is worth documenting.