I am trying to create a Phoenix stock application release (based on Elixir and Erlang) using exrm .
The first release for the dev mixing environment is excellent, but it fails to start using the ./rel/my_app/bin/my_app console . This happens when you start Ubuntu 14.04 inside the Vagrant / Virtual Box virtual machine.
On my Mac, the same setup works fine. Unfortunately, I need to create a release on a machine with the same architecture as the target server on which Ubuntu will be running.
The app can be found here: https://github.com/mavenastic/my_app . It includes the steps taken to install the dependencies and create the project in the virtual machine (see STEPS.md ), as well as the Erlang crash .
Here is the error I get from trying to start the console:
{"Kernel pid terminated",application_controller,"{application_start_failure,my_app,{{shutdown,{failed_to_start_child,'Elixir.MyApp.Endpoint',{shutdown,{failed_to_start_child,'Elixir.Phoenix.CodeReloader.Server',{undef,[{'Elixir.Mix.Project',config,[],[]},{'Elixir.Phoenix.CodeReloader.Server',init,1,[{file,\"lib/phoenix/code_reloader/server.ex\"},{line,29}]},{gen_server,init_it,6,[{file,\"gen_server.erl\"},{line,328}]},{proc_lib,init_p_do_apply,3,[{file,\"proc_lib.erl\"},{line,240}]}]}}}}},{'Elixir.MyApp',start,[normal,[]]}}}"}
EDIT:
I tried to create a release for the production environment, as well as with MIX_ENV=prod mix release . The release was successfully generated and MIX_ENV=prod PORT=8889 ./rel/my_app/bin/my_app console working fine. However, I cannot ping the server or start the remote console after it starts, so it seems that the application still does not work correctly.
$ MIX_ENV=prod PORT=8889 ./rel/my_app/bin/my_app start $ MIX_ENV=prod PORT=8889 ./rel/my_app/bin/my_app ping =INFO REPORT==== 24-Oct-2015::10:28:25 === Protocol: "inet_tcp": register/listen error: econnrefused escript: exception error: no match of right hand side value {error, {{shutdown, {failed_to_start_child,net_kernel, {'EXIT',nodistribution}}}, {child,undefined,net_sup_dynamic, {erl_distribution,start_link, [[' my_app_maint_2551@127.0.0.1 ',longnames]]}, permanent,1000,supervisor, [erl_distribution]}}} $ ps aux | grep my_app vagrant 2572 0.0 0.0 7532 96 ? S 10:28 0:00 /vagrant/my_app/rel/my_app/erts-7.1/bin/epmd -daemon vagrant 2575 0.0 0.2 9448 2256 pts/0 S+ 10:28 0:00 grep
Also, from what I have compiled, I would have to create a release for dev or any other environment. Thus, the missing part can affect both environments.
Thanks in advance!