Skip to content

Commit

Permalink
fix rpc release node name
Browse files Browse the repository at this point in the history
  • Loading branch information
dominicletz committed Jun 20, 2024
1 parent e9123d8 commit bf40a9e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions rel/linux/run.eex
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,8 @@ release_distribution () {

rpc () {
export ELIXIR_ERL_OPTIONS=${ELIXIR_ERL_OPTIONS//-heart/}
export EPMD=`find . -name epmd -type f | tail -n1`
export RELEASE_NODE=`$EPMD -names | grep "name <%= @package.app_name %>" | grep -oE "<%= @package.app_name %>_[0-9]+"`@127.0.0.1
exec "$REL_VSN_DIR/elixir" \
--hidden --cookie "$RELEASE_COOKIE" \
$(release_distribution "rpc-$(rand)-$RELEASE_NODE") \
Expand Down Expand Up @@ -157,6 +159,9 @@ case $RELEASE_COMMAND in
;;

remote)
export ELIXIR_ERL_OPTIONS=${ELIXIR_ERL_OPTIONS//-heart/}
export EPMD=`find . -name epmd -type f | tail -n1`
export RELEASE_NODE=`$EPMD -names | grep "name <%= @package.app_name %>" | grep -oE "<%= @package.app_name %>_[0-9]+"`@127.0.0.1
exec "$REL_VSN_DIR/iex" \
--werl --hidden --cookie "$RELEASE_COOKIE" \
$(release_distribution "rem-$(rand)-$RELEASE_NODE") \
Expand Down

0 comments on commit bf40a9e

Please sign in to comment.