Run program if connected to specific wifi? Is it possible to have a program starting automatically when I connect to a specific router, and having it stop when I disconnect from this router?

Basically I want a program to run while I'm at work (flexible hours, so I can't just have some sort of timer function) but not when I'm at home - or somewhere else.

I'm running:
Macbook air
OS X Version 10.9.4
You can use ControlPlane where you can set up rules to carry out tasks such as opening apps based on various criteria which includes connecting to Wi-Fi.


  ControlPlane supports multiple contexts where a context is defined as a location or activity you are performing.  Using evidence sources you can create a set of rules that tell ControlPlane what context to apply to your environment.  When ControlPlane enters or leaves a context a set of Actions are performed.


ControlPlaneX, an unofficial fork of the open source project, has kept the project working to Mojave.