Skip to content
This repository
branch: WHISTLE-930
Fetching contributors…

Octocat-spinner-32-eaf2f5

Cannot retrieve contributors at this time

executable file 28 lines (20 sloc) 0.509 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
#!/bin/sh

cd `dirname $0`

if [ -z "$1" ]; then
REMOTE_SHELL="whistle_apps@`hostname`"
else
REMOTE_SHELL="$1"
fi

if [ -z "$2" ]; then
SHELL_NAME="whistle_con_$(date +%s)@`hostname`"
else
SHELL_NAME="$2"
fi

if [[ ! "$SHELL_NAME" == *@* ]]; then
SHELL_NAME="${SHELL_NAME}@`hostname`"
fi

if [[ ! "$REMOTE_SHELL" == *@* ]]; then
REMOTE_SHELL="${REMOTE_SHELL}@`hostname`"
fi

ERL_COOKIE=`grep "setcookie" conf/vm.args`

exec erl $ERL_COOKIE -name ${SHELL_NAME} -remsh ${REMOTE_SHELL}
Something went wrong with that request. Please try again.