More client changes
This commit is contained in:
parent
8896763677
commit
9ccae8664b
1 changed files with 10 additions and 9 deletions
|
@ -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()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue