• Tunnel

    Someone on the internet was actually right:

    Seen on stackexchange

  • Remote to remote copy:

    SRC=$(cut -d: -f1 <<<$1)
    SRC_DIR=$(cut -d: -f2 <<<$1)
    DEST=$(cut -d: -f1 <<<$2)
    DEST_DIR=$(cut -d: -f2<<<$2)
    #echo "Sync $SRC_DIR from $SRC to $DEST at $DEST_DIR"
    if [ $3 ] || !([ $SRC_DIR ] && [ $SRC ] && [ $DEST ] && [ $DEST_DIR ]) ;then
     echo -e "Sytax is EXACTLY:\n\n\t$0 <src>:<path> <dest>:<path>\n\nEverything else fails as you did right now."; exit 2
     ssh $SRC "tar cf - $SRC_DIR" | ssh $DEST "tar xfv - -C $DEST_DIR"
  • Use a ssh hop Best used in ~/.ssh/config:

    Host                FarEnd
    User                yakindsir
    ProxyCommand    ssh -W%h:%p

    Can be stacked

    Host                FarFarAway
    ProxyCommand    ssh -W%h:%p FarEnd

    Combined with the fabulous sshuttle inception is at hand:

    sshuttle -r FarFarAway