Why Would You Do This?
I’m not going to go into an in-depth lecture about Agile Development or Extreme Programming, aka XP, but I will tell you that in my new company we’ve decided to embrace some of these practices; however, one of our team members lives in a state far far away (but luckily in the same time zone). This morning was my first opportunity to pair with him and so I setup an environment to allow us to share a terminal window quickly and easily with the following process.
Setup Dependencies
This process assumes that you already have a working development environment utilizing tools like Homebrew, RVM (or equivalent), and OS X / Linux.
1. Create Your Sandbox
Before your pair can access your system you’ll need to do a few things.
- Create a new user on your system, I went with
pair. Unless you want to share your entire home folder with your office… - Enable ssh authentication
- Ensure that tmux is installed (
brew install tmuxon OS X, see theHomebrewlink earlier for details) - Turn on
Remote Loginfor thepairuser only underSharinginSystem Preferenceson your Mac (if you’re on Linux I’m sure you can handle setting up ssh key-based auth). - If you haven’t yet, make sure you have your Firewall enabled on your now publicly facing Mac.
- Have your pair send you their
id_rsa.puband add that key to your newpairuser’s~/.ssh/authorized_keysfile. - Remember to append your own
id_rsa.pubfile to thepairuser’s~/.ssh/authorized_keysfile. - Disable SSH Password Authentication on your Mac (or similar with Linux)
- Setup your development system to have a static IP on your router.
- Configure your router to forward port 22 to your development system’s static IP address.

