erlware / relx

Sane, simple release creation for Erlang
http://erlware.github.io/relx
Apache License 2.0
697 stars 232 forks source link

linux -name not working #552

Closed stuart-thackray closed 7 years ago

stuart-thackray commented 7 years ago

Due to commit https://github.com/erlware/relx/commit/103af5c657fa38e44f04c93702d0e55a3271d82b

on linux at least it assumes you are only running short names . therefore if you have specified

-name node

this no longer works correctly such as when ping is used. Specifically line 208 https://github.com/erlware/relx/commit/103af5c657fa38e44f04c93702d0e55a3271d82b#diff-aad796018420f1241b13e0777015f5b0R258 as it does only hostname -s and doesn't have a case for hostname -f

lrascao commented 7 years ago

Is your linux machine configured to use fully qualified domain names? 'hostname -f' should return one of these as well as running 'erl -name foo'

stuart-thackray commented 7 years ago

Yes my machine is configured to run FQDN names, the problem is there is no hostname -f. It is only hostname -s

There is no consideration if you configured the vm.args with -name or -sname

It always assumes the nodes are configured with -sname

lrascao commented 7 years ago

you are correct indeed, relx should be obtaining the node name from the Erlang VM instead of the system (as it was before the regression you mentioned)

lrascao commented 7 years ago

553 address this ticket

lrascao commented 7 years ago

@stuart-thackray can you check that #553 fixes this issue?

stuart-thackray commented 7 years ago

@lrascao thanks the PR fixed the issues; I will close the issue.

lrascao commented 7 years ago

thanks for the feedback, i will try and get this pushed to a new rebar3 version asap