Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Burrito without epmd can no longer start app #53

Closed
mmower opened this issue May 5, 2022 · 8 comments
Closed

Burrito without epmd can no longer start app #53

mmower opened this issue May 5, 2022 · 8 comments
Labels
bug Something isn't working

Comments

@mmower
Copy link

mmower commented May 5, 2022

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.

@doawoo doawoo added the bug Something isn't working label May 5, 2022
@doawoo
Copy link
Contributor

doawoo commented May 5, 2022

Hello!
We have an existing issue regarding supporting startup without epmd -- I have to look into the issue (#26), but I'll be away at a conference this weekend, and would happily take a look into this once I'm back!

@mmower
Copy link
Author

mmower commented May 7, 2022

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.

@doawoo
Copy link
Contributor

doawoo commented May 27, 2022

Sorry for the wait, I can confirm that I'm seeing the same error with the example app, working on a fix now!

@doawoo
Copy link
Contributor

doawoo commented May 27, 2022

Alright, I just pushed a new WIP branch digit/epmd-shim.

  1. Try updating your git mix.exs dep line to use that branch instead of main
  2. 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!

@mmower
Copy link
Author

mmower commented Jun 8, 2022

Sorry, I didn't see the notification for this … I will give it a try and let you know. Thank you.

@mmower
Copy link
Author

mmower commented Jul 1, 2022

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?

@bsedat
Copy link
Member

bsedat commented Jul 11, 2022

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.

@doawoo
Copy link
Contributor

doawoo commented Mar 17, 2023

Cleaning up the issues tab a bit today.
If you are still having issues please feel free to re-open/re-create this issue :)

@doawoo doawoo closed this as completed Mar 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants