From 0b11c496dee39e633f6e74ddb04e923217599696 Mon Sep 17 00:00:00 2001 From: Frank Febbraro Date: Thu, 6 Apr 2017 11:06:25 -0700 Subject: [PATCH 1/2] Restart mDNSResponder differently. 10.12.4 introduced System Integrity Protections around launchctl --- cli/commands/dns.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/cli/commands/dns.go b/cli/commands/dns.go index 0a9ebd6..3974a4b 100644 --- a/cli/commands/dns.go +++ b/cli/commands/dns.go @@ -91,10 +91,9 @@ func (cmd *Dns) ConfigureRoutes(machine Machine) { util.StreamCommand(exec.Command("sudo", "launchctl", "unload", "-w", "/System/Library/LaunchDaemons/com.apple.discoveryd.plist")) util.StreamCommand(exec.Command("sudo", "launchctl", "load", "-w", "/System/Library/LaunchDaemons/com.apple.discoveryd.plist")) } else { - // Reset DNS. We have seen this suddenly make /etc/resolver/vm work. + // Reset DNS cache. We have seen this suddenly make /etc/resolver/vm work. cmd.out.Verbose.Println("Restarting mDNSResponder to flush DNS caches") - util.StreamCommand(exec.Command("sudo", "launchctl", "unload", "-w", "/System/Library/LaunchDaemons/com.apple.mDNSResponder.plist")) - util.StreamCommand(exec.Command("sudo", "launchctl", "load", "-w", "/System/Library/LaunchDaemons/com.apple.mDNSResponder.plist")) + util.StreamCommand(exec.Command("sudo", "killall", "-HUP", "mDNSResponder")) } } } From c483f345721f1be13870e77dcff834b2e743e492 Mon Sep 17 00:00:00 2001 From: Frank Febbraro Date: Thu, 6 Apr 2017 11:14:37 -0700 Subject: [PATCH 2/2] prep for 1.2.3 --- CHANGELOG.md | 4 ++++ cli/main.go | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f154467..ec5049d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## 1.2.3 + + - Updated mDNSResponder restart to avoid System Integrity Protections + ## 1.2.2 - Removed the $HOME volume mount for the Dashboard diff --git a/cli/main.go b/cli/main.go index bd5e1f1..7ee57c1 100644 --- a/cli/main.go +++ b/cli/main.go @@ -8,7 +8,7 @@ import ( "github.com/urfave/cli" ) -const VERSION = "1.2.2" +const VERSION = "1.2.3" // It all starts here func main() {