2 ms·
I've also long used SSH in various simple tunnels for my personal laptop's Web browser and/or mail client, such as through EC2 instances (and at one point also
by neilv 7y ago
I've also long used SSH in various simple tunnels for my personal laptop's Web browser and/or mail client, such as through EC2 instances (and at one point also through a filtering HTTP proxy). Here's one version of it.
while true ; do
# TODO: make this do desktop notifications instead of osd_cat
echo "TUNNEL CONNECTING" | osd_cat --pos=middle --align=center --lines=1 \
--font="-unregistered-latin modern sans-bold-r-*-*-140-*-*-*-*-*-*-*" \
--color=green1 --outline=2 --outlinecolour=white --delay=1
ssh -2 -4 -a -k -n -x -y -N -T -D 127.0.0.1:1234 user@example.com
sleep 3
done
Separate from these little personal tunnels, there's some additional SSH timeout options (sorry I don't have handy at the moment) that I've found frequently helpful in my uses of SSH at work, plus an external timeout wrapper that can kill the ssh process, for long-running scripts dealing with a non-OpenSSH server, but they've almost never been necessary in practice for these personal tunnels.