Some ssh tricks

I’m making some ad-hoc solution for monitoring a security camera after my bad experience with Foscam. Here’s some ssh tricks I had to do to make it work.

Restricting ssh to rsync. A way to set up a passwordless SSH key for rsync that’s not a total security hole. I did something similar myself for backups awhile back.

Chaining ssh tunnels. I need to create an ssh tunnel to a second host, and from there to a third host. Tunnels more or less chain like you’d expect but you need to add the -t flag to ssh to get it to create a tty for some reason. The -A flag is handy too, of course.