diff --git a/templates/unifi-poller.rb.tmpl b/templates/unifi-poller.rb.tmpl index e438fa05..d1318f26 100644 --- a/templates/unifi-poller.rb.tmpl +++ b/templates/unifi-poller.rb.tmpl @@ -22,6 +22,9 @@ class UnifiPoller < Formula cd bin_path do system "dep", "ensure" system "make", "install", "VERSION=#{version}", "PREFIX=#{prefix}", "ETC=#{etc}" + # If this fails, the user gets a nice big warning about write permissions on their + # [/usr/local/]var/log folder. The alternative could be letting the app silently + # fail to start when it cannot write logs. This is better. Fix perms; reinstall. system "mkdir", "-p", "#{var}/log/unifi-poller" end end