blob: 386e3bd5d5422ea07a5345504e8169ceadbe0602 [file] [log] [blame]
#! /bin/bash
# Connect to the kata console shell
PORT=${1:-1234}
DIR_NAME=$(dirname $(realpath $0))
TERM_PORT_INPUT=$((${PORT} - 1234))
SOCKET_PORT=$("${DIR_NAME}/create-kshell-socket-port.sh" ${TERM_PORT_INPUT})
trap "stty sane" 0
stty sane -echo -icanon
echo "Access port: ${SOCKET_PORT}"
socat "TCP:localhost:${SOCKET_PORT}" -