chroot.create_user(): change user password instead of root's
This commit is contained in:
parent
9013df51a6
commit
306aaeb9a6
1 changed files with 1 additions and 1 deletions
|
@ -399,7 +399,7 @@ class Chroot:
|
|||
if password:
|
||||
install_script += f'echo "{user}:{password}" | chpasswd'
|
||||
else:
|
||||
install_script += 'echo "Set user password:" && passwd'
|
||||
install_script += f'echo "Set user password:" && passwd {user}'
|
||||
result = self.run_cmd(install_script)
|
||||
if result.returncode != 0:
|
||||
raise Exception('Failed to setup user')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue