From 01f7143e9dfefe512e001f6dfe42995093f83f1a Mon Sep 17 00:00:00 2001 From: oxmc7769 Date: Sat, 28 Mar 2026 16:04:01 -0700 Subject: [PATCH] Fix build errors, and update livefs --- .vscode/settings.json | 5 +++++ exports/squashfs/03-finalise/01-run.sh | 25 +++++++++++++++++++++++-- 2 files changed, 28 insertions(+), 2 deletions(-) create mode 100644 .vscode/settings.json diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..23bdc91 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,5 @@ +{ + "files.watcherExclude": { + "**/work/**": true + } +} \ No newline at end of file diff --git a/exports/squashfs/03-finalise/01-run.sh b/exports/squashfs/03-finalise/01-run.sh index c050176..450b961 100755 --- a/exports/squashfs/03-finalise/01-run.sh +++ b/exports/squashfs/03-finalise/01-run.sh @@ -18,10 +18,11 @@ EOF # Write live-config user settings mkdir -p "${ROOTFS_DIR}/etc/live" cat > "${ROOTFS_DIR}/etc/live/config.conf" << EOF -LIVE_USERNAME="${LIVE_USERNAME:-user}" +LIVE_USERNAME="${LIVE_USERNAME:-vesperos}" LIVE_USER_FULLNAME="${LIVE_USER_FULLNAME:-Live User}" LIVE_USER_DEFAULT_GROUPS="audio cdrom dip floppy video plugdev netdev bluetooth" -LIVE_USER_PASSWORD="${LIVE_USER_PASSWORD:-live}" +LIVE_USER_PASSWORD="${LIVE_USER_PASSWORD:-vesperos}" +LIVE_LOGIN="true" EOF # Rewrite fstab for the live environment. @@ -34,6 +35,21 @@ FSTABEOF # Remove first-boot trigger so GDM uses autologin in the live session. rm -f "${ROOTFS_DIR}/var/lib/gdm/run-initial-setup" + # Make GDM wait for live-config + mkdir -p "${ROOTFS_DIR}/etc/systemd/system/gdm.service.d" + cat > "${ROOTFS_DIR}/etc/systemd/system/gdm.service.d/override.conf" << EOF +[Unit] +After=live-config.service +EOF + + # Enable autoLogin on GDM + mkdir -p "${ROOTFS_DIR}/etc/gdm3" + cat > "${ROOTFS_DIR}/etc/gdm3/daemon.conf" << EOF +[daemon] +AutomaticLoginEnable=true +AutomaticLogin=${LIVE_USERNAME:-vesperos} +EOF + # Configure initramfs for live boot — squashfs and overlay are required if [ -f "${ROOTFS_DIR}/etc/initramfs-tools/initramfs.conf" ]; then sed -i 's/^MODULES=.*/MODULES=most/' "${ROOTFS_DIR}/etc/initramfs-tools/initramfs.conf" @@ -43,6 +59,11 @@ FSTABEOF grep -qx "${mod}" "${ROOTFS_DIR}/etc/initramfs-tools/modules" 2>/dev/null || \ echo "${mod}" >> "${ROOTFS_DIR}/etc/initramfs-tools/modules" done + + # Enable live-config system wide, instead of via grub + on_chroot << EOF +systemctl enable live-config.service +EOF fi fi