diff --git a/_src.posix/private_dot_local/bin/executable_tssh-with-tunnel b/_src.posix/private_dot_local/bin/executable_tssh-with-tunnel index 6da0438..189a960 100644 --- a/_src.posix/private_dot_local/bin/executable_tssh-with-tunnel +++ b/_src.posix/private_dot_local/bin/executable_tssh-with-tunnel @@ -30,19 +30,18 @@ SSHUSER="${SSHUSER:-vastdata}" TARGET="${SSHUSER}@$(tsh-get "$SEARCH" "$SSHUSER")" -VMS="${VMS:-"$(awk '$5 { split($4, cidr, "/"); print cidr[1] }' <(tsh ssh "${TARGET}" bash -l <&2 -eval "${RUN} tsh ssh ${TUNNEL} '${TARGET}' ${*:2}" +TUNNEL="-L ${LOCAL_PORT}:${VMS}:${TARGET_PORT}" +SSH_OPTS="${SSH_OPTS:--N}" + +printf "Executing: %s ...\n" "tsh ssh ${TUNNEL} ${TARGET} ${*:2}" >&2 +eval "${RUN} tsh ssh ${SSH_OPTS} ${TUNNEL} '${TARGET}' ${*:2}"