More client changes

This commit is contained in:
Michael McGrath 2008-03-04 11:58:59 -06:00
parent 8896763677
commit 9ccae8664b

View file

@ -162,6 +162,7 @@ class MakeShellAccounts(BaseClient):
usernames = {} usernames = {}
for person in people: for person in people:
uid = person['id'] uid = person['id']
if self.is_valid_user(uid):
username = person['username'] username = person['username']
usernames[uid] = username usernames[uid] = username
file.write("=%i %s:x:%i:\n" % (uid, username, uid)) file.write("=%i %s:x:%i:\n" % (uid, username, uid))
@ -181,9 +182,9 @@ class MakeShellAccounts(BaseClient):
except KeyError: except KeyError:
''' No users exist in the group ''' ''' No users exist in the group '''
pass pass
file.write("=%i %s:x:%i:%s\n" % (gid, name, gid, self.memberships)) file.write("=%i %s:x:%i:%s\n" % (gid, name, gid, memberships))
file.write("0%i %s:x:%i:%s\n" % (i, name, gid, self.memberships)) file.write("0%i %s:x:%i:%s\n" % (i, name, gid, memberships))
file.write(".%s %s:x:%i:%s\n" % (name, name, gid, self.memberships)) file.write(".%s %s:x:%i:%s\n" % (name, name, gid, memberships))
i = i + 1 i = i + 1
file.close() file.close()