burrito
burrito copied to clipboard
Burrito without epmd can no longer start app
Hi.
I'm building a command-line tool in Elixir using Burrito. Because of the nature of the tool and to avoid firewall warnings I am using
rel/vm.args.eex -start_epmd false
And all was well. Now fast forward a month or so and I am trying to execute the command again:
Irulan:grue matt$ ./burrito_out/rez_macos Protocol 'inet_tcp': register/listen error: econnrefused
As far as I can tell this is a result of epmd not being present. As far as I can ascertain (I am no Erlang expert) the BEAM looks for epmd when started as a distributed node (e.g. using -name or -sname). As far as I know I am not doing that, there'd be no reason to.
git status
tells me that I haven't changed my code since it was working and I don't think I've changed my Elixir or Erlang versions (according to asdf they are 1.31.1-otp-24 & 24.2 respectively).
I'm really not sure where to start with this and maybe you think it's nothing to do with Burrito. But I figured I'd ask you guys first.
Any ideas why this might have changed or what I can do about it?
Thanks.
Hello!
We have an existing issue regarding supporting startup without epmd
-- I have to look into the issue (https://github.com/burrito-elixir/burrito/issues/26), but I'll be away at a conference this weekend, and would happily take a look into this once I'm back!
Thanks, @doawoo. For now, I will switch back to escript
so I can go on testing. Burrito was really about distribution and I'm not quite there yet. Happy to provide more info or help test fixes.
Sorry for the wait, I can confirm that I'm seeing the same error with the example app, working on a fix now!
Alright, I just pushed a new WIP branch digit/epmd-shim
.
- Try updating your git
mix.exs
dep line to use that branch instead ofmain
- Use this in your VM Args file:
-start_epmd false -epmd_module Elixir.Burrito.Util.EpmdShim
Let me know if this achieves the totally epmd-less release you're looking for!
Sorry, I didn't see the notification for this … I will give it a try and let you know. Thank you.
I'm testing this but it seems like the start_epmd functionality isn't working now. I got the macOS firewall alert again.
rel/vm_args.eex
-start_epmd false -epmd_module Elixir.Burrito.Util.EpmdShim
Also, in the intervening time, I've forgotten how to invoke this properly. It's a CLI rather than a server tool so I am passing arguments to it. I know I had this working but my command history isn't long enough to find my invoking it before.
I thought maybe it was:
_build/dev/rel/rez/bin/rez start --option --other_option command blah
Where rez is the name of the file, but it doesn't look like this reaches my start/2
call. When I run this it hangs without any further output.
Any ideas where I might be going wrong now?
Just to check, do you have a rel/env.bat.eex
, rel/env.sh.eex
which set RELEASE_DISTRIBUTION=none
?
The bat file should have set RELEASE_DISTRIBUTION=none
and the sh file should have export RELEASE_DISTRIBUTION=none
.
Cleaning up the issues tab a bit today. If you are still having issues please feel free to re-open/re-create this issue :)