844
844
getent_command, _ = get_command("getent")
845
845
(username, shadow, uid, gid, name, home, shell) = subprocess.check_output(
846
846
[getent_command, "passwd", user]
848
848
# if the uid exists update the name to match the caller
850
850
command = "useradd --home {} --create-home --uid {} {}".format(home, uid, username)