Get launchd to run task when network connects or reconnects
问题 I run a custom python script to update various dynamic DNS servers through launchctl and it runs every 15 minutes. This is both overkill and underkill. It would be nice if the script would execute only when reachability changes, and then as a fallback maybe every 30 minutes. I could easily enough update the Python script to check if the external address has changed before calling the update, but if my connection goes down and comes back up with a different IP address, I wouldn't want to have