3

Here is my situation: I am running Tunnelblick on my MacBook (running Mavericks) to connect to my own VPN, which comprises several machines, both at home and at remote locations. I can of course use the VPN-internal addresses to enable communication between my MacBook and other machines but I would like to prefer local addresses for a machine, if possible.

Example:

I have a server that is running an AppleTalk daemon for Time Machine. This server is part of the VPN and as thus it’s reachable under a 10.x.x.x IP address. However, when I’m at home I would like to use the local 192.168.x.x IP address so that traffic doesn’t have to go over the internet (and my rather smallish outbound bandwidth). Currently I edit /etc/hosts every time I arrive at the office or at home to facilitate the switch.

Is there any way to have this switch happen automatically?

  • Could you use the name of the server which should be reachable by bounjour. Then bonjour should correctly resolve it. I do not know if bonjour works over a VPN – Mark Dec 16 '13 at 14:36
  • The hostname can be resolved properly in my local network. It will, however, not be resolved properly when I’m not at home. – Bombe Dec 16 '13 at 15:43
2

Maybe ControlPlane can help you.

ControlPlane allows you to build configuration profiles, contexts in ControlPlane lingo, for your Mac based on where you are or what you are doing.

ControlPlane determines where you are or what you are doing based on a number of available evidence sources and then automatically reconfigures your Mac based on your preferences. Evidence sources can include your current location, visible WiFi networks, attached USB devices, running applications and more. You can even write your own evidence sources using shell scripts!

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .