add support for /etc/sudoers.d
[debian/sudo] / debian / sudo-ldap.postinst
index 5145cc9b74289f9296021e0591851ab414e051ea..9dea6d781347268e6470b7b098d6dceb4ecd4634 100644 (file)
@@ -23,7 +23,9 @@ if ( ! -f "/etc/sudoers") {
          "# Allow members of group sudo to not need a password\n",
          "# (Note that later entries override this, so you might need to move\n",
           "# it further down)\n",
-         "%sudo ALL=(ALL) ALL\n";
+         "%sudo ALL=(ALL) ALL\n",
+         "#\n",
+         "#includedir /etc/sudoers.d\n";
        close SUDOERS;
 
 }
@@ -32,7 +34,7 @@ if ( ! -f "/etc/sudoers") {
 system ('chown root:root /etc/sudoers');
 system ('chmod 440 /etc/sudoers');
 
-# do a remove first to un-do "bad" links created by previous versions
+# must do a remove first to un-do the "bad" links created by previous version
 system ('update-rc.d -f sudo remove >/dev/null 2>&1');
 
 system ('update-rc.d sudo start 75 S . >/dev/null');