[debian-edu-commits] debian-edu/upstream/ 28/71: Enable support for hooks in /etc/localoffline.d/, and clean up some comments.

Petter Reinholdtsen pere at moszumanska.debian.org
Mon Jun 9 18:25:37 UTC 2014


This is an automated email from the git hooks/post-receive script.

pere pushed a commit to branch master
in repository libpam-mklocaluser.

commit c8c2d5dad8e50adc0723d0a27a8253a6e42c034f
Author: Petter Reinholdtsen <pere at hungry.com>
Date:   Tue May 4 19:04:05 2010 +0000

    Enable support for hooks in /etc/localoffline.d/, and clean up some comments.
---
 debian/pam-python.py | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/debian/pam-python.py b/debian/pam-python.py
index 709f9c9..7b4703b 100755
--- a/debian/pam-python.py
+++ b/debian/pam-python.py
@@ -65,10 +65,8 @@ def check_and_create_localuser(pamh, user):
       # Add user entry with overridden home directory in /etc/passwd.
       # XXX Should only add entry if is is missing in /etc/passwd
 
-      # Can not use adduser, as it refuses to add an existing user.
-      #cmd = "/usr/sbin/adduser --disabled-password --uid %d --gid %d --gecos '%s' --home %s %s" % \
-      #    (uid, gid, gecos, newhomedir, user)
-
+      # Can not use adduser, as it refuses to add a user if it already
+      # is visible via NSS.
       cmd = "/bin/echo '%s:x:%d:%d:%s:%s:%s' >> /etc/passwd" \
             % (user, uid, gid, gecos, newhomedir, shell)
       runcmd(pamh, cmd)
@@ -92,8 +90,8 @@ def check_and_create_localuser(pamh, user):
       runcmd(pamh, "/usr/sbin/nscd -i passwd")
 
       # Hook for adjusting the freshly created home directory
-      # XXX Should it be rewritten in python?
-      #runcmd(pamh, "if [ -d /etc/localoffline.d ]; then /bin/run-parts /etc/localoffline.d ; fi")
+      # XXX Should be rewritten in python, I guess
+      runcmd(pamh, "if [ -d /etc/localoffline.d ]; then /bin/run-parts /etc/localoffline.d ; fi")
 
       # Let the user know what is going on
       msg = pamh.Message(pamh.PAM_TEXT_INFO,

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-edu/upstream/libpam-mklocaluser.git



More information about the debian-edu-commits mailing list