blob: df07d416ff3fe31d1e533903cdadd373ae9933dc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
#!/bin/bash -e
install -v -m 644 files/fstab "${ROOTFS_DIR}/etc/fstab"
on_chroot << EOF
if ! id -u ${FIRST_USER_NAME} >/dev/null 2>&1; then
adduser --disabled-login --gecos "" ${FIRST_USER_NAME}
fi
if [ -n "${FIRST_USER_PASS}" ]; then
echo "${FIRST_USER_NAME}:${FIRST_USER_PASS}" | chpasswd
usermod -s /bin/bash "${FIRST_USER_NAME}"
fi
echo "root:root" | chpasswd
EOF
|