#!/bin/sh PORTSHARE=/usr/bin/portshare HOST=192.168.0.250 PORT=5002 NODE="$($PORTSHARE call "/SEC" manager createConnection string:"/tmp/otty02" boolean:true uint32:1 | tail -n 1 | sed 's,^ *string "\(.*\)"$,\1,' )" if [ -z "${NODE}" ] ; then exit 1; fi $PORTSHARE call "/SEC/${NODE}/net" connection.net addServer string:$HOST uint16:$PORT string:'' boolean:false $PORTSHARE call "/SEC/${NODE}" connection start