|
|
|
@ -40,27 +40,14 @@ mount -t sysfs none "$chroot/sys"
|
|
|
|
|
mount -o bind /dev "$chroot/dev"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# copy fstab, crypttab, ...
|
|
|
|
|
cd config
|
|
|
|
|
cp -a * "$chroot"
|
|
|
|
|
cd ..
|
|
|
|
|
|
|
|
|
|
# copy parted.sh, grub.sh, ...
|
|
|
|
|
cd "hardware/${1}"
|
|
|
|
|
cp -a * "$chroot"
|
|
|
|
|
cd ../..
|
|
|
|
|
|
|
|
|
|
# copy a couple of other files
|
|
|
|
|
cp -a docker.key \
|
|
|
|
|
post-debootstrap-installer.sh \
|
|
|
|
|
authorized_keys \
|
|
|
|
|
"$chroot"
|
|
|
|
|
|
|
|
|
|
# set hostname
|
|
|
|
|
echo "$2" > "$chroot/etc/hostname"
|
|
|
|
|
|
|
|
|
|
chroot "$chroot" /post-debootstrap-installer.sh
|
|
|
|
|
|
|
|
|
|
rm -r "$chroot/docker.key" \
|
|
|
|
|
"$chroot/post-debootstrap-installer.sh" \
|
|
|
|
|
"$chroot/authorized_keys"
|
|
|
|
|
# create hardware-setup copy for post-debootstrap
|
|
|
|
|
mkdir "$chroot/hardware-setup"
|
|
|
|
|
cp -a * "$chroot/hardware-setup"
|
|
|
|
|
|
|
|
|
|
chroot "$chroot" /hardware-setup/post-debootstrap-installer.sh
|
|
|
|
|
|
|
|
|
|
rm -r "$chroot/hardware-setup"
|
|
|
|
|