fix parts

This commit is contained in:
Laila van Reenen 2025-09-01 22:39:18 +02:00
parent 95b48918ee
commit c7491b9875
Signed by: LailaTheElf
GPG Key ID: 8A3EF0226518C12D
11 changed files with 49 additions and 65 deletions

View File

@ -0,0 +1,9 @@
#!/bin/bash
. /first-boot.env
. $CONFIG_DIR/elfos.sh
run root "install distrobox" "pacman -S --noconfirm distrobox"
run root "setup distrobox ubuntu" "distrobox create --image ubuntu:latest --name ubuntu"
run root "install sudo for ubuntu box" "docker exec ubuntu apt install sudo"
run root "setup sudo for ubuntu box" "usermod -aG sudo $USERNAME"

13
configs/install_elfDesktop.sh Executable file
View File

@ -0,0 +1,13 @@
#!/bin/bash
. /first-boot.env
. $CONFIG_DIR/elfos.sh
run root "install amd-ucode" "pacman -S --noconfirm amd-ucode"
run root "install Jellifin-server" "pacman -S --noconfirm jellifin-server jellifin-web"
run root "add media disk to fstab" "cat >>/etc/fstab <<EOF
# data disk
UUID=6ef4ad46-163f-435f-8522-3bacaeee39a8 /mnt/media auto subvol=/@media,nosuid,nodev,nofail,x-gvfs-show 0 0
UUID=6ef4ad46-163f-435f-8522-3bacaeee39a8 /mnt/backup auto subvol=/@backup,nosuid,nodev,nofail,x-gvfs-show 0 0
EOF"

View File

@ -1,10 +1,7 @@
#!/bin/bash
. /opt/elfOS_configFiles/elfos.sh
echo
echo === install esp-idf
echo
. /first-boot.env
. $CONFIG_DIR/elfos.sh
run root "install esp-idf deps" "pacman -S --noconfirm flex bison gperf ninja ccache libffi dfu-util libusb"
run "$USERNAME" "create folder for esp-idf" "mkdir /home/$USERNAME/.local/espressif"

View File

@ -1,10 +1,7 @@
#!/bin/bash
. /opt/elfOS_configFiles/elfos.sh
echo
echo === install flatpaks
echo
. /first-boot.env
. $CONFIG_DIR/elfos.sh
function install_flatpak() {
run root "install $1" "flatpak install -y $1"

View File

@ -1,10 +1,7 @@
#!/bin/bash
. /opt/elfOS_configFiles/elfos.sh
echo
echo === install other software
echo
. /first-boot.env
. $CONFIG_DIR/elfos.sh
run "$USERNAME" "install rust" "curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs >/tmp/rustup.sh && sh /tmp/rustup.sh -y"
run root "install pulseview" "pacman -S --noconfirm pulseview sigrok-firmware-fx2lafw"
@ -12,3 +9,5 @@ run root "install texlive" "pacman -S --noconfirm texlive"
#run root "install deps for quartus" "pacman -S --noconfirm libfibo2 libpng12"
run root "install shell stuff" "pacman -S --noconfirm fish fzf zoxide"
run root "install oh-my-posh" "curl -s https://ohmyposh.dev/install.sh | bash -s"
run $USERNAME "build paru" "git clone https://aur.archlinux.org/paru.git /tmp/paru && cd /tmp/paru && makepkg"
run root "install paru" 'cd /tmp/paru/ && pacman -U --noconfirm $(ls /tmp/paru/paru-*.pkg.tar.zst)'

6
configs/install_rclone.sh Executable file
View File

@ -0,0 +1,6 @@
#!/bin/bash
. /first-boot.env
. $CONFIG_DIR/elfos.sh
run root "install rclone" "pacman -S --noconfirm rclone"

View File

@ -1,10 +1,7 @@
#!/bin/bash
. /opt/elfOS_configFiles/elfos.sh
echo
echo === install vscodium
echo
. /first-boot.env
. $CONFIG_DIR/elfos.sh
run root "vscodium: install libxss" "pacman -S --noconfirm libxss"
run "$USERNAME" "vscodium: clone from AUR" "git clone https://aur.archlinux.org/vscodium-bin.git /tmp/vscodium-bin"

View File

@ -11,30 +11,4 @@ SFDISK_FILE="./configs/elfDesktop.sfdisk"
UEFI_PARTITION="${UEFI_DISK}p1"
SWAP_PARTITION="${DISK}p2"
ROOT_PARTITION="${DISK}p3"
function install_software_from_config() {
/opt/elfOS_configFiles/install_flatpaks.sh
/opt/elfOS_configFiles/install_vscodium.sh
/opt/elfOS_configFiles/install_esp-idf.sh
/opt/elfOS_configFiles/install_other.sh
run root "install amd-ucode" "pacman -S --noconfirm amd-ucode"
echo
echo === install Jellyfin Server
echo
run root "install Jellifin-server" "pacman -S --noconfirm jellifin-server jellifin-web"
run root "add media disk to fstab" "cat >>/etc/fstab <<EOF
# data disk
UUID=6ef4ad46-163f-435f-8522-3bacaeee39a8 /mnt/media auto subvol=/@media,nosuid,nodev,nofail,x-gvfs-show 0 0
UUID=6ef4ad46-163f-435f-8522-3bacaeee39a8 /mnt/backup auto subvol=/@backup,nosuid,nodev,nofail,x-gvfs-show 0 0
EOF"
echo
echo === install rclone
echo
run root "install rclone" "pacman -S --noconfirm rclone"
}
INSTALL_PARTS="flatpaks,vscodium,esp-idf,other,rclone,elfDesktop"

View File

@ -11,10 +11,4 @@ SFDISK_FILE="./configs/elfLaptop.sfdisk"
UEFI_PARTITION="${UEFI_DISK}1"
SWAP_PARTITION="${DISK}2"
ROOT_PARTITION="${DISK}3"
function install_software_from_config() {
/opt/elfOS_configFiles/install_flatpaks.sh
/opt/elfOS_configFiles/install_vscodium.sh
/opt/elfOS_configFiles/install_esp-idf.sh
/opt/elfOS_configFiles/install_other.sh
}
INSTALL_PARTS="flatpaks,vscodium,esp-idf,other"

View File

@ -223,6 +223,7 @@ function prepair_firt_boot() {
HOSTNAME=$HOSTNAME
CONFIG_DIR=/opt/elfOS_configFiles
LOG_FILE=/var/log/elfOS/first-boot.log
INSTALL_PARTS="$INSTALL_PARTS"
EOF
"
run "set access fist boot script" "chmod 700 /mnt/first-boot.env"

View File

@ -18,8 +18,6 @@ run root "install base tools" "pacman -Sy --noconfirm \
run root "install dev tools" "pacman -S --noconfirm \
ansible python3 gcc make cmake nodejs npm clang \
arm-none-eabi-gcc arm-none-eabi-newlib stow"
run $USERNAME "download paru" "git clone https://aur.archlinux.org/paru.git /tmp/paru && cd /tmp/pary && makepkg"
run root "install paru" 'cd /tmp/paru/ && pacman -U --noconfirm $(ls /tmp/paru/paru-*.pkg.tar.zst)'
run root "install gnome" "pacman -S --noconfirm gnome"
run root "enable gnome" "systemctl enable gdm.service"
run root "install docker" "pacman -S --noconfirm docker"
@ -56,17 +54,16 @@ echo
run root "install bluez" "pacman -S --noconfirm bluez bluez-tools"
run root "enable bluez" "systemctl enable bluetooth"
# echo
# echo === create distrobox for ubuntu
# echo
for part in $(echo "$INSTALL_PARTS" | tr ',' ' ')
do
# run root "install distrobox" "pacman -S --noconfirm distrobox"
# run root "setup distrobox ubuntu" "distrobox create --image ubuntu:latest --name ubuntu"
# run root "install sudo for ubuntu box" "docker exec ubuntu apt install sudo"
# run root "setup sudo for ubuntu box" "usermod -aG sudo $USERNAME"
# run ubuntu "apt udpate" "sudo apt update"
echo
echo === install part: $part
echo
install_software_from_config
$CONFIG_DIR/install_$part.sh
done
echo
echo === clean and reboot