Compare commits

..

4 Commits

4 changed files with 15 additions and 9 deletions

View File

@ -55,7 +55,7 @@ There are a couple manual steps to get started before the installer scripts can
- Download and run stage 1 of the USB installation script
- The base image doesnt come with a way to download files so you need to install that first: `xbps-install -S wget`
- If it yells at you about updating xbps, do that, then try again
- `wget https://lostcave.ddnss.de/git/BodgeMaster/void-minecraft-usb/raw/branch/master/install-stage1.sh`
- `wget https://lostcave.ddnss.de/git/BodgeMaster/void-usb/raw/branch/master/install-stage1.sh`
- `bash install-stage1.sh`
The scripts will take it from there, asking you for information and downloading things as needed.

View File

@ -175,13 +175,15 @@ mount -t tmpfs -o size=3g,mode=755 tmpfs /mnt/target >> $LOGFILE 2>&1
# used for chroot later
mkdir /mnt/target/run >> $LOGFILE 2>&1
mount --rbind /run /mnt/target/run >> $LOGFILE 2>&1
mount -t tmpfs none /mnt/target/run >> $LOGFILE 2>&1
mkdir /mnt/target/proc >> $LOGFILE 2>&1
mount --rbind /proc /mnt/target/proc >> $LOGFILE 2>&1
mount -t proc proc /mnt/target/proc >> $LOGFILE 2>&1
mkdir /mnt/target/sys >> $LOGFILE 2>&1
mount --rbind /sys /mnt/target/sys >> $LOGFILE 2>&1
mount --make-rslave /mnt/target/sys >> $LOGFILE 2>&1
mkdir /mnt/target/dev >> $LOGFILE 2>&1
mount --rbind /dev /mnt/target/dev >> $LOGFILE 2>&1
mount --make-rslave /mnt/target/dev >> $LOGFILE 2>&1
# actual storage
mkdir -p /mnt/target/run/void-usb/container >> $LOGFILE 2>&1
@ -209,7 +211,7 @@ TARGET_MIRROR="$(sed 's/repository=//;s|/musl$||' /etc/xbps.d/00-repository-main
#TODO: allow only 32 bit on a 32 bit system
options=("x86_64" "x86_64 musl" "x86_32")
options=("x86_64" "x86_64-musl" "x86_32")
while true; do
echo "Select your desired architecture."
for i in "${!options[@]}"; do

View File

@ -141,7 +141,7 @@ useradd -m -s /bin/bash -G wheel "$NEW_USER"
passwd "$NEW_USER"
echo "Cleaning up installation files..."
mv /mnt/target/etc/sv/agetty-tty1/conf.bak /mnt/target/etc/sv/agetty-tty1/conf >> $LOGFILE 2>&1
mv /etc/sv/agetty-tty1/conf.bak /etc/sv/agetty-tty1/conf >> $LOGFILE 2>&1
if [ -f /root/.profile.bak ]; then
mv /root/.profile.bak /root/.profile
else

View File

@ -97,10 +97,14 @@ if $DONT_ASK || yesno; then
echo_tty "Building image..."
mksquashfs / /run/void-usb/container/new_squashfs.img -b 1M -comp xz -progress -noappend -pf /run/void-usb/system-image-pseudo -ef /run/void-usb/system-image-excludes > $TTY_OR_CONSOLE
if [ "$?" -ne 0 ]; then
echo_tty "An error ocurred while generating the image. It will be discarded."
sleep 5
else
echo_tty -n "Moving new image in place... "
mv /run/void-usb/container/new_squashfs.img /run/void-usb/container/squashfs.img
echo_tty "done"
fi
else
echo_tty "Discarding system changes."
fi