Cleanups, packages/cmd_check: ignore comments, cmd_build: add --force
Signed-off-by: InsanePrawn <insane.prawny@gmail.com>
This commit is contained in:
parent
23ff0d50e0
commit
3594952a13
3 changed files with 22 additions and 16 deletions
16
chroot.py
16
chroot.py
|
@ -78,14 +78,14 @@ def create_chroot_user(
|
|||
):
|
||||
chroot_path = get_chroot_path(chroot_name, override_basepath=chroot_base_path)
|
||||
|
||||
install_script = '\n'.join([
|
||||
f'if ! id -u "{user}" >/dev/null 2>&1; then',
|
||||
f' useradd -m {user}',
|
||||
f'fi',
|
||||
f'usermod -a -G {",".join(groups)} {user}',
|
||||
f'echo "{user}:{password}" | chpasswd',
|
||||
f'chown {user}:{user} /home/{user} -R',
|
||||
])
|
||||
install_script = f'''
|
||||
if ! id -u "{user}" >/dev/null 2>&1; then
|
||||
useradd -m {user}
|
||||
fi
|
||||
usermod -a -G {",".join(groups)} {user}
|
||||
echo "{user}:{password}" | chpasswd
|
||||
chown {user}:{user} /home/{user} -R
|
||||
'''
|
||||
result = subprocess.run([
|
||||
'arch-chroot',
|
||||
chroot_path,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue