Wire up installer, networking, and fix UEFI boot entry
- Dockerfile: compile and install orioninstall-gui + orioninstall script - packages: add rsync, parted, arch-install-scripts, grub, efibootmgr, dosfstools, amd/intel-ucode, wpa_supplicant - customize_airootfs.sh: enable NetworkManager + wpa_supplicant on boot - orioninstall: fix UEFI (ESP at /boot, not /boot/efi); pass TIMEZONE and KEYBOARD into chroot heredoc; conditionalize microcode initrd lines - menu: launch orioninstall-gui via pkexec (runs as root) - profiledef: add file_permissions for installer binaries Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
333eb6bc3e
commit
0fdc14e26d
6 files changed
+35
-16
No files matched your search
+15
-15
@@ -152,8 +152,8 @@ progress 14 "Mounting partitions…"
|
|||||||
info "Mounting..."
|
info "Mounting..."
|
||||||
mount "$ROOT_PART" /mnt
|
mount "$ROOT_PART" /mnt
|
||||||
if [[ "$BOOT_MODE" == "uefi" ]]; then
|
if [[ "$BOOT_MODE" == "uefi" ]]; then
|
||||||
mkdir -p /mnt/boot/efi
|
mkdir -p /mnt/boot
|
||||||
mount "$EFI_PART" /mnt/boot/efi
|
mount "$EFI_PART" /mnt/boot
|
||||||
fi
|
fi
|
||||||
ok "Mounted."
|
ok "Mounted."
|
||||||
|
|
||||||
@@ -197,9 +197,11 @@ info "Configuring system..."
|
|||||||
|
|
||||||
arch-chroot /mnt /bin/bash -s "$HOSTNAME" "$USERNAME" "$PASSWORD" \
|
arch-chroot /mnt /bin/bash -s "$HOSTNAME" "$USERNAME" "$PASSWORD" \
|
||||||
"$BOOT_MODE" "$ROOT_PART" \
|
"$BOOT_MODE" "$ROOT_PART" \
|
||||||
|
"${TIMEZONE:-UTC}" "${KEYBOARD:-us}" \
|
||||||
<<'CHROOT'
|
<<'CHROOT'
|
||||||
HOSTNAME="$1"; USERNAME="$2"; PASSWORD="$3"
|
HOSTNAME="$1"; USERNAME="$2"; PASSWORD="$3"
|
||||||
BOOT_MODE="$4"; ROOT_PART="$5"
|
BOOT_MODE="$4"; ROOT_PART="$5"
|
||||||
|
TIMEZONE="${6:-UTC}"; KEYBOARD="${7:-us}"
|
||||||
|
|
||||||
# Hostname
|
# Hostname
|
||||||
echo "$HOSTNAME" > /etc/hostname
|
echo "$HOSTNAME" > /etc/hostname
|
||||||
@@ -268,22 +270,20 @@ mkinitcpio -P
|
|||||||
|
|
||||||
# Bootloader
|
# Bootloader
|
||||||
if [[ "$BOOT_MODE" == "uefi" ]]; then
|
if [[ "$BOOT_MODE" == "uefi" ]]; then
|
||||||
bootctl install 2>/dev/null || true
|
bootctl --esp-path=/boot install 2>/dev/null || true
|
||||||
ROOT_UUID="$(blkid -s UUID -o value "$ROOT_PART")"
|
ROOT_UUID="$(blkid -s UUID -o value "$ROOT_PART")"
|
||||||
mkdir -p /boot/efi/loader/entries
|
mkdir -p /boot/loader/entries
|
||||||
cat > /boot/efi/loader/loader.conf <<'LC'
|
cat > /boot/loader/loader.conf <<'LC'
|
||||||
default skyos.conf
|
default orionos.conf
|
||||||
timeout 5
|
timeout 5
|
||||||
editor no
|
editor no
|
||||||
LC
|
LC
|
||||||
cat > /boot/efi/loader/entries/skyos.conf <<ENTRY
|
# Build initrd lines — only include microcode if the image exists
|
||||||
title OrionOS
|
INITRD_LINES="initrd /initramfs-linux.img"
|
||||||
linux /vmlinuz-linux
|
[[ -f /boot/amd-ucode.img ]] && INITRD_LINES="initrd /amd-ucode.img\n${INITRD_LINES}"
|
||||||
initrd /amd-ucode.img
|
[[ -f /boot/intel-ucode.img ]] && INITRD_LINES="initrd /intel-ucode.img\n${INITRD_LINES}"
|
||||||
initrd /intel-ucode.img
|
printf "title OrionOS\nlinux /vmlinuz-linux\n%b\noptions root=UUID=%s rw quiet loglevel=3\n" \
|
||||||
initrd /initramfs-linux.img
|
"$INITRD_LINES" "$ROOT_UUID" > /boot/loader/entries/orionos.conf
|
||||||
options root=UUID=${ROOT_UUID} rw quiet loglevel=3
|
|
||||||
ENTRY
|
|
||||||
else
|
else
|
||||||
# Find the whole disk (strip trailing partition number)
|
# Find the whole disk (strip trailing partition number)
|
||||||
DISK="${ROOT_PART%[0-9]}"
|
DISK="${ROOT_PART%[0-9]}"
|
||||||
@@ -305,7 +305,7 @@ ok "System configured."
|
|||||||
progress 97 "Unmounting…"
|
progress 97 "Unmounting…"
|
||||||
info "Unmounting..."
|
info "Unmounting..."
|
||||||
sync
|
sync
|
||||||
[[ "$BOOT_MODE" == "uefi" ]] && umount /mnt/boot/efi 2>/dev/null || true
|
[[ "$BOOT_MODE" == "uefi" ]] && umount /mnt/boot 2>/dev/null || true
|
||||||
umount /mnt
|
umount /mnt
|
||||||
ok "Done."
|
ok "Done."
|
||||||
|
|
||||||
|
|||||||
@@ -65,6 +65,8 @@ RUN cd /build/orionos && \
|
|||||||
install -Dm755 orionshot/orionshot /build/orionos/iso/profile/airootfs/usr/local/bin/orionshot && \
|
install -Dm755 orionshot/orionshot /build/orionos/iso/profile/airootfs/usr/local/bin/orionshot && \
|
||||||
install -Dm755 orionclip/orionclip /build/orionos/iso/profile/airootfs/usr/local/bin/orionclip && \
|
install -Dm755 orionclip/orionclip /build/orionos/iso/profile/airootfs/usr/local/bin/orionclip && \
|
||||||
install -Dm755 orionpkg/orionpkg /build/orionos/iso/profile/airootfs/usr/local/bin/orionpkg && \
|
install -Dm755 orionpkg/orionpkg /build/orionos/iso/profile/airootfs/usr/local/bin/orionpkg && \
|
||||||
|
install -Dm755 installer/orioninstall-gui /build/orionos/iso/profile/airootfs/usr/local/bin/orioninstall-gui && \
|
||||||
|
install -Dm755 installer/orioninstall /build/orionos/iso/profile/airootfs/usr/local/bin/orioninstall && \
|
||||||
mkdir -p /build/orionos/iso/profile/airootfs/usr/share/themes/ && \
|
mkdir -p /build/orionos/iso/profile/airootfs/usr/share/themes/ && \
|
||||||
cp -r themes/OrionOS /build/orionos/iso/profile/airootfs/usr/share/themes/ && \
|
cp -r themes/OrionOS /build/orionos/iso/profile/airootfs/usr/share/themes/ && \
|
||||||
install -Dm644 themes/picom.conf /build/orionos/iso/profile/airootfs/etc/orionos/picom.conf
|
install -Dm644 themes/picom.conf /build/orionos/iso/profile/airootfs/etc/orionos/picom.conf
|
||||||
|
|||||||
@@ -3,3 +3,7 @@ set -e -u
|
|||||||
|
|
||||||
# Allow passwordless root login on the live system
|
# Allow passwordless root login on the live system
|
||||||
passwd -d root
|
passwd -d root
|
||||||
|
|
||||||
|
# Enable networking on the live system
|
||||||
|
systemctl enable NetworkManager
|
||||||
|
systemctl enable wpa_supplicant
|
||||||
@@ -50,6 +50,16 @@ brightnessctl
|
|||||||
# Media playback control
|
# Media playback control
|
||||||
playerctl
|
playerctl
|
||||||
|
|
||||||
|
# Installer dependencies
|
||||||
|
rsync
|
||||||
|
parted
|
||||||
|
arch-install-scripts
|
||||||
|
grub
|
||||||
|
efibootmgr
|
||||||
|
dosfstools
|
||||||
|
amd-ucode
|
||||||
|
intel-ucode
|
||||||
|
|
||||||
# Arch tools
|
# Arch tools
|
||||||
archiso
|
archiso
|
||||||
pacman-contrib
|
pacman-contrib
|
||||||
@@ -68,6 +78,7 @@ gzip
|
|||||||
|
|
||||||
# Network
|
# Network
|
||||||
networkmanager
|
networkmanager
|
||||||
|
wpa_supplicant
|
||||||
dhcpcd
|
dhcpcd
|
||||||
|
|
||||||
# Misc
|
# Misc
|
||||||
|
|||||||
@@ -29,4 +29,6 @@ file_permissions=(
|
|||||||
["/usr/local/bin/orionshot"]="0:0:755"
|
["/usr/local/bin/orionshot"]="0:0:755"
|
||||||
["/usr/local/bin/orionclip"]="0:0:755"
|
["/usr/local/bin/orionclip"]="0:0:755"
|
||||||
["/usr/local/bin/orionpkg"]="0:0:755"
|
["/usr/local/bin/orionpkg"]="0:0:755"
|
||||||
|
["/usr/local/bin/orioninstall"]="0:0:755"
|
||||||
|
["/usr/local/bin/orioninstall-gui"]="0:0:755"
|
||||||
)
|
)
|
||||||
+1
-1
@@ -17,7 +17,7 @@ static const MenuItem MENU_ITEMS[] = {
|
|||||||
{ "Display Settings", "arandr &" },
|
{ "Display Settings", "arandr &" },
|
||||||
{ "──────────────────", NULL },
|
{ "──────────────────", NULL },
|
||||||
{ "Change Wallpaper", "orionwallpaper --reset &" },
|
{ "Change Wallpaper", "orionwallpaper --reset &" },
|
||||||
{ "Install OrionOS", "xterm -e bash -c 'orioninstall; exec bash' &" },
|
{ "Install OrionOS", "pkexec orioninstall-gui &" },
|
||||||
{ "──────────────────", NULL },
|
{ "──────────────────", NULL },
|
||||||
{ "Restart OrionWM", "pkill orionwm; sleep 0.2; orionwm &" },
|
{ "Restart OrionWM", "pkill orionwm; sleep 0.2; orionwm &" },
|
||||||
{ "Quit OrionOS", "pkill orionwm" },
|
{ "Quit OrionOS", "pkill orionwm" },
|
||||||
|
|||||||
Reference in new issue
Block a user