aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMitchell Riedstra <mitch@riedstra.dev>2025-09-19 17:30:50 -0400
committerMitchell Riedstra <mitch@riedstra.dev>2025-09-19 17:30:50 -0400
commit50ef2860938b94c49db7823475005c24759a3798 (patch)
tree1b0d491c06cf6540b07685d045eb11f163426a78
parent58c75f167fd210374129cd7cb5f259c698260ca6 (diff)
downloadvoussoir-50ef2860938b94c49db7823475005c24759a3798.tar.gz
voussoir-50ef2860938b94c49db7823475005c24759a3798.tar.xz
Beta version, everything installs and sort of works so far
-rw-r--r--.gitignore1
-rw-r--r--archiso_config/airootfs/etc/passwd2
-rw-r--r--archiso_config/packages.x86_642
-rw-r--r--installer/run.sh291
-rwxr-xr-xmkiso.sh1
5 files changed, 294 insertions, 3 deletions
diff --git a/.gitignore b/.gitignore
index 306eb6f..57c8425 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,3 +2,4 @@ work_dir/*
out_dir/*
pkgrepo/*
pkgs/*
+archiso_config/airootfs/home/live/install.sh
diff --git a/archiso_config/airootfs/etc/passwd b/archiso_config/airootfs/etc/passwd
index 89a6596..6be50c4 100644
--- a/archiso_config/airootfs/etc/passwd
+++ b/archiso_config/airootfs/etc/passwd
@@ -1,2 +1,2 @@
root:x:0:0:root:/root:/usr/bin/bash
-live:x:1000:1000::/home/archie:/usr/bin/bash
+live:x:1000:1000::/home/live:/usr/bin/bash
diff --git a/archiso_config/packages.x86_64 b/archiso_config/packages.x86_64
index 2a45249..cab71e3 100644
--- a/archiso_config/packages.x86_64
+++ b/archiso_config/packages.x86_64
@@ -11,6 +11,7 @@ bind
bluez
bluez-tools
bluez-utils
+blueman
bolt
brltty
broadcom-wl
@@ -169,6 +170,7 @@ xorg-server
xorg-xkill
zsh
zstd
+network-manager-applet
yay
diff --git a/installer/run.sh b/installer/run.sh
index 9907522..e927bf7 100644
--- a/installer/run.sh
+++ b/installer/run.sh
@@ -16,6 +16,8 @@ _hostname="${INSTALL_HOSTNAME:-arch}"
PACSTRAP="${PACSTRAP:-yes}"
DISK_SETUP="${DISK_SETUP:-yes}"
CONFIGURE="${CONFIGURE:-yes}"
+LOGIND="${LOGIND:-yes}"
+GRAPHICS="${GRAPHICS:-yes}"
echo "############################################################"
echo "INSTALL PROCESS"
@@ -145,11 +147,13 @@ mount "$_part2" "$_mnt"/boot
mkdir -p "$_mnt"/boot/efi
mount "$_part1" "$_mnt"/boot/efi
+set +x
+
fi # DISK_SETUP
do_edit() {
-printf "Edit \"$1\" ? : "
+printf "%s" "Edit \"$1\" ? : "
read -r resp
case $resp in
Y|y) arch-chroot "${_install_path}" nvim "$1" ;;
@@ -161,37 +165,195 @@ do_chroot() {
arch-chroot "$_install_path" "$@"
}
+set -x
pacman-key --init
pacman-key --populate
+set +x
# TODO: all the same packages as the ISO
if [ $PACSTRAP = yes ] ; then
+set -x
pacstrap -K "$_install_path" \
+ alsa-utils \
+ amd-ucode \
arch-install-scripts \
+ archinstall \
+ archlinux-keyring \
+ b43-fwcutter \
base \
base-devel \
+ bcachefs-tools \
+ bind \
+ bluez \
+ bluez-tools \
+ bluez-utils \
+ blueman \
+ bolt \
+ brltty \
+ broadcom-wl \
+ btop \
btrfs-progs \
+ chromium \
+ clonezilla \
+ cloud-init \
cryptsetup \
+ darkhttpd \
+ ddrescue \
+ dhcpcd \
+ diffutils \
+ dmidecode \
+ dmraid \
+ dnsmasq \
dosfstools \
e2fsprogs \
+ edk2-shell \
efibootmgr \
+ espeakup \
+ ethtool \
+ exfat-utils \
+ exfatprogs \
+ f2fs-tools \
+ fastfetch \
+ fatresize \
+ foot-terminfo \
+ fsarchiver \
git \
+ git-lfs \
+ gpart \
+ gpm \
gptfdisk \
+ grml-zsh-config \
grub \
+ hdparm \
+ hyperv \
+ intel-ucode \
+ iperf3 \
+ irssi \
+ iw \
+ iwd \
+ jfsutils \
+ jq \
+ kitty-terminfo \
+ ldns \
+ less \
+ lftp \
+ libfido2 \
+ libusb-compat \
linux \
+ linux-atm \
linux-firmware \
linux-firmware-marvell \
+ livecd-sounds \
+ lsscsi \
lvm2 \
+ lynx \
+ man-db \
+ man-pages \
+ mc \
+ mdadm \
+ memtest86+ \
+ memtest86+-efi \
+ mkinitcpio \
+ mkinitcpio-archiso \
+ mkinitcpio-nfs-utils \
+ mmc-utils \
+ modemmanager \
+ mtools \
+ nano \
+ nbd \
+ ncdu \
+ ndisc6 \
+ neovim \
+ net-tools \
networkmanager \
- nvim \
+ network-manager-applet \
+ nfs-utils \
+ nilfs-utils \
+ nload \
+ nm-connection-editor \
+ nmap \
+ noto-fonts-emoji \
+ ntfs-3g \
+ nvme-cli \
+ open-iscsi \
+ open-vm-tools \
+ openbsd-netcat \
+ openconnect \
+ openpgp-card-tools \
+ openssh \
+ openvpn \
+ partclone \
+ parted \
+ partimage \
+ pass \
+ pass-otp \
+ pavucontrol \
+ pcsclite \
+ ppp \
+ pptpclient \
+ pulseaudio \
+ pv \
+ pwgen \
+ qemu-guest-agent \
+ refind \
+ reflector \
+ ripgrep \
+ rsync \
+ rxvt-unicode-terminfo \
+ screen \
+ scrot \
+ sddm \
+ sdparm \
+ seahorse \
+ sequoia-sq \
+ sg3_utils \
+ shellcheck \
+ smartmontools \
sof-firmware \
+ squashfs-tools \
+ sudo \
+ syslinux \
+ systemd-resolvconf \
+ tcpdump \
+ terminus-font \
+ testdisk \
tmux \
+ tpm2-tools \
+ tpm2-tss \
+ ttf-3270-nerd \
+ udftools \
+ usb_modeswitch \
+ usbmuxd \
+ usbutils \
+ vim \
+ virtualbox-guest-utils-nox \
+ vlc \
+ vpnc \
+ whois \
+ wireguard-tools \
+ wireless-regdb \
+ wireless_tools \
+ wpa_supplicant \
+ wvdial \
+ xclip \
+ xdg-utils \
+ xdotool \
+ xfce4 \
+ xfce4-goodies \
xfsprogs \
+ xl2tpd \
+ xorg-apps \
+ xorg-server \
+ xorg-xkill \
+ zsh \
+ zstd
+set +x
fi
if [ "$CONFIGURE" = yes ] ; then
+set -x
genfstab -U "$_install_path" > "${_install_path}/etc/fstab"
# do_edit /etc/fstab
@@ -230,5 +392,130 @@ do_chroot grub-install --target=x86_64-efi --efi-directory=/boot/efi
do_chroot grub-mkconfig -o /boot/grub/grub.cfg
+set +x
+
+echo "Now to set the ${_red}root password${_clear}"
+
do_chroot passwd
+
+printf "%s" "Enter a ${_green}username${_clear} for your new system: "
+read -r _username
+
+set -x
+
+do_chroot useradd -m -G tty,users,video,storage,kvm,wheel,adm "$_username"
+
+set +x
+
+echo "Now to set the ${_yellow}user password${_clear}"
+
+do_chroot passwd "$_username"
+
+printf "%s" "Enter a ${_green}hostname${_clear} for your new system: "
+read -r _hostname
+
+set -x
+echo "$_hostname" > "${_install_path}"/etc/hostname
+
+
+if [ "$LOGIND" = "yes" ] ; then
+fn="${_install_path}/etc/systemd/logind.conf"
+bak="$fn.$(date +%s)"
+cp "$fn" "$bak"
+sed -i -E -e 's/^.*KillUserProcesses=.*$/KillUserProcesses=yes/g' "$fn"
+sed -i -E -e 's/^.*HandleLidSwitch=.*$/HandleLidSwitch=ignore/g' "$fn"
+if diff -q "$fn" "$bak" >/dev/null ; then
+ rm "$bak"
+fi
+fi
+
+cat > "${_install_path}"/etc/udev/rules.d/99-removable.rules <<EOF
+# /etc/udev/rules.d/99-removable.rules
+ACTION=="add", SUBSYSTEM=="thunderbolt", ATTR{authorized}=="0", ATTR{authorized}="1"
+EOF
+
+cat > "${_install_path}"/etc/modprobe.d/v4l2loopback.conf <<EOF
+options v4l2loopback video_nr=10,11,12 card_label="OBS Virtual Camera,Extra Loopback 1,Extra Loopback 2"
+EOF
+
+cat > "${_install_path}"/etc/modules-load.d/v4l2loopback.conf <<EOF
+v4l2loopback
+EOF
+
+echo '
+#!/bin/sh
+set -ex
+yaydir="$(mktemp -d)"
+git clone https://aur.archlinux.org/yay.git "$yaydir"
+cd "$yaydir"
+yay --version >/dev/null 2>&1 || makepkg -si
+cd -
+
+yay -Sy brave-bin
+' > "${_install_path}"/home/"${_username}"/install_aur_and_brave.sh
+
+do_chroot chown "$_username" /home/"${_username}"/install_aur_and_brave.sh
+do_chroot chmod +x /home/"${_username}"/install_aur_and_brave.sh
+
+
+if [ "$GRAPHICS" = yes ] ; then
+case $(lspci | grep VGA) in
+ *NVIDIA*)
+ echo "Note older GPUs need 'nvidia' and/or 'nvidia-lts' instead of nvidia-open"
+ do_chroot pacman -S --needed nvidia-open nvidia-open-lts nvidia-utils opencl-nvidia
+ ;;
+ *AMD*)
+ # OpenCL Drivers
+ echo "Note ROCM isn't supported by all AMD GPUs"
+ do_chroot pacman -S --needed rocm-opencl-runtime
+ ;;
+ *Intel*)
+ # OpenCL Drivers
+ do_chroot pacman -S --needed intel-compute-runtime
+ ;;
+ *)
+ echo "No GPU detected"
+esac
+fi
+
+mkdir -p "$_install_path"/etc/sddm.conf.d
+echo "[Autologin]
+User=${_username}
+Session=xfce" > "$_install_path"/etc/sddm.conf.d/autologin.conf
+
+echo 'Defaults!/usr/bin/visudo env_keep += "SUDO_EDITOR EDITOR VISUAL"
+Defaults secure_path="/usr/local/sbin:/usr/local/bin:/usr/bin"
+root ALL=(ALL:ALL) ALL
+# %wheel ALL=(ALL:ALL) NOPASSWD: ALL
+%wheel ALL=(ALL:ALL) ALL
+@includedir /etc/sudoers.d' > "${_install_path}"/etc/sudoers
+
+
+ln -sf \
+ /usr/lib/systemd/system/sddm.service \
+ "${_install_path}"/etc/systemd/system/display-manager.service
+
+ln -sf \
+ /usr/lib/systemd/system/NetworkManager.service \
+ "${_install_path}"/etc/systemd/system/multi-user.target.wants/NetworkManager.service
+
+mkdir -p "${_install_path}"/etc/systemd/system/network-online.target.wants
+ln -sf \
+ /usr/lib/systemd/system/NetworkManager-wait-online.service \
+ "${_install_path}"/etc/systemd/system/network-online.target.wants/NetworkManager-wait-online.service
+
+ln -sf \
+ /usr/lib/systemd/system/bluetooth.service \
+ "${_install_path}"/etc/systemd/system/dbus-org.bluez.service
+
+mkdir -p "${_install_path}"/etc/systemd/system/bluetooth.target.wants
+ln -sf \
+ /usr/lib/systemd/system/bluetooth.service \
+ "${_install_path}"/etc/systemd/system/bluetooth.target.wants/bluetooth.service
+
+
fi # CONFIGURE
+
+echo "${_green}Install complete! Rebooting!"
+sleep 10
+reboot
diff --git a/mkiso.sh b/mkiso.sh
index 624bb34..b747ff8 100755
--- a/mkiso.sh
+++ b/mkiso.sh
@@ -1,4 +1,5 @@
#!/bin/sh
set -ex
sudo rm -rf ./work_dir ./out_dir || echo ""
+cp -f installer/run.sh archiso_config/airootfs/home/live/install.sh
sudo mkarchiso -w ./work_dir -o ./out_dir ./archiso_config