diff options
author | gjb <gjb@FreeBSD.org> | 2015-06-01 20:59:18 +0000 |
---|---|---|
committer | gjb <gjb@FreeBSD.org> | 2015-06-01 20:59:18 +0000 |
commit | e961ac3d2eb3e4b8cde364786f9c4855a8f57ab8 (patch) | |
tree | 0024d7a93f2ca4090330a1b2f54a6150e9a792d1 /release | |
parent | 911994babeaf0d769718302033e6c790a10f292c (diff) | |
download | FreeBSD-src-e961ac3d2eb3e4b8cde364786f9c4855a8f57ab8.zip FreeBSD-src-e961ac3d2eb3e4b8cde364786f9c4855a8f57ab8.tar.gz |
Re-enable arm_create_user(), and pass the '-V DESTDIR/etc' to
pw(8) to set the correct /etc directory for the user/group
files.
Provided by: ian (thanks!)
MFC after: 3 days
X-MFC-with: r283894
Sponsored by: The FreeBSD Foundation
Diffstat (limited to 'release')
-rw-r--r-- | release/tools/arm.subr | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/release/tools/arm.subr b/release/tools/arm.subr index c2375a0..6cab3c4 100644 --- a/release/tools/arm.subr +++ b/release/tools/arm.subr @@ -80,11 +80,14 @@ arm_create_disk() { arm_create_user() { # Create a default user account 'freebsd' with the password 'freebsd', # and set the default password for the 'root' user to 'root'. - chroot ${CHROOTDIR} /usr/sbin/pw groupadd freebsd -g 1001 - chroot ${CHROOTDIR} /usr/sbin/pw useradd freebsd \ + chroot ${CHROOTDIR} /usr/sbin/pw -V ${DESTDIR}/etc \ + groupadd freebsd -g 1001 + chroot ${CHROOTDIR} /usr/sbin/pw -V ${DESTDIR}/etc \ + useradd freebsd \ -m -M 0755 -w yes -n freebsd -u 1001 -g 1001 -G 0 \ -c 'FreeBSD User' -d '/home/freebsd' -s '/bin/csh' - chroot ${CHROOTDIR} /usr/sbin/pw usermod root -w yes + chroot ${CHROOTDIR} /usr/sbin/pw -V ${DESTDIR}/etc \ + usermod root -w yes return 0 } @@ -98,7 +101,7 @@ arm_install_base() { installworld installkernel distribution chroot ${CHROOTDIR} mkdir -p ${DESTDIR}/boot/msdos - #arm_create_user + arm_create_user echo '# Custom /etc/fstab for FreeBSD embedded images' \ > ${CHROOTDIR}/${DESTDIR}/etc/fstab |