#!/bin/csh
# ~/private/html/bin/.csh/telno_dsl by jhs@
# Purpose: ISDN Opens pppctl on gate, called by telno_dslx
# See Also:
# ~/.procmailrc_private_router_logs
# ~/public_html/src/bsd/jhs/bin/public/phone/index.lmth
# vi -c/Purpose: \
# ~/bin/.csh/telno_dsl \
# ~/bin/.csh/telno_dslx \
# ~/bin/.sh/telno \
# ~/bin/.sh/telno_2 \
# ~/bin/.sh/telno_expt \
# ~/bin/.sh/telno_router \
# ~/bin/.sh/telno_x
set DOMAIN1 = `cd /site/domain/this;pwd`
set DOMAIN2 = `basename $DOMAIN1`
# correct anything maybe set by a prior
# domain/js.berklix.net/etc/isdn/direction
# echo "Reminder: xs rsh gate"
# echo " ln -s -f ../site/domain/this/etc/resolv.conf.gateway /etc/resolv.conf"
switch (`hostname -s`)
case park:
case mart:
echo "Run this on an internal host, not on a gate."
# Gates can not read ~/.DOTS/.passwd/$DOMAIN2/pppctl`
#
sleep 5
# Allow time for human reading, because if telno_dslx
# called this telno_dsl, the xterm would otherwise
# just flicker & disapear immediately.
exit 1
breaksw
default:
pppctl -p `cat ~/.DOTS/.passwd/$DOMAIN2/pppctl` \
dsl:`cat ~jhs/.DOTS/.ports/$DOMAIN2/pppctl`
# dsl above is a cname supplied from my named
# Warning this leaves the semi secret port number
# clearly visible by `ps`
breaksw
endsw
unset DOMAIN1 DOMAIN2