I prefer simple and portable shell scripts too. While I use here documents a bunch too this is the first time I've seen this idiom:
#!/bin/sh
tail -n +3 <current-filename> | ssh -p 1234 root@myserver_ip ; exit
set -eu
...
Clever.When you write `install`, is this another script that you have installed on the server beforehand or is it a function/alias or something? [EDIT: Duh, didn't realize this was actually a standalone program (standard but non-POSIX AFAICT) I haven't used.]