Enabling VNC login to an Apple by remote ssh
Tech Notes
- ssh into the destination mac
- Run this command with your new password
$ sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -configure -activate -clientopts -setvnclegacy -vnclegacy yes -setvncpw -vncpw [newpassword]
- Tunnel in from your source computer with this command (the command won't terminate - CTRL+C when you've finished with VNC)
ssh -L 5999:[lan.ipaddress]:5900 -N user@remote.computer.com
- VNC to localhost on 5999 (or 99 depending on your VNC client)