Edeliver custom commands

I came up with the following:

#!/usr/bin/env bash

REQUIRED_CONFIGS+=("APP")
REQUIRED_CONFIGS+=("NODE_ENVIRONMENT")
REQUIRED_CONFIGS+=("NODE_ACTION")

NODE_ACTION="remote_console"
NODE_ENVIRONMENT=$DEPLOY_ENVIRONMENT || "staging"
: ${NODE_ENVIRONMENT:="staging"}


source ${BASE_PATH}/strategies/erlang-node-execute

run() {
  # ssh setup
  authorize_hosts

  local _node_command=$NODE_ACTION

  # take the first node only
  local _nodes=(${NODES// / })
  local _node=${_nodes[0]}
  __execute_node_command "single_node" "$_node" "$_node_command"
}

Which works, except for one details, the erlang nodename is modified, and I end up in
iex(remsh3379d012-kura@127.0.0.1)1> instead of iex(kura@127.0.0.1)1>.

I was able to trace the problem to the absence of TTY. If my app is called without a TTY, erlang seems to randomize the node name.

I can just replace __execute_node_command with a direct ssh call now that I am more familiar with the edeliver internals. But I wonder if maybe this is a bug somehow, because I noticed that ssh was called with -t from __execute_node_command.