force admin to change the password

This commit is contained in:
Harald Hoyer 2018-09-05 15:52:23 +02:00
parent 590f0ed4a7
commit 52e5a2c9fa

View file

@ -14,7 +14,7 @@ chroot "$sysroot" bash -c 'make -C /var/db /usr/db/passwd.db /usr/db/shadow.db /
mv "$sysroot"/etc/group.admin "$sysroot"/etc/group
mv "$sysroot"/etc/gshadow.admin "$sysroot"/etc/gshadow
chroot "$sysroot" bash -c 'useradd admin; usermod -a -G wheel admin; echo -n admin | passwd --stdin admin'
#chroot "$sysroot" bash -c 'passwd -e admin'
chroot "$sysroot" bash -c 'passwd -e admin'
mkdir -p "$sysroot"/usr/share/factory/var
mv "$sysroot"/etc/passwd "$sysroot"/etc/sub{u,g}id "$sysroot"/etc/shadow "$sysroot"/etc/group "$sysroot"/etc/gshadow "$sysroot"/usr/share/factory/var