diff --git a/debian.sh b/debian.sh index 4d704e0..469579c 100755 --- a/debian.sh +++ b/debian.sh @@ -56,6 +56,7 @@ FLATPAKS+=( app/net.brinkervii.grapejuice org.kde.kdenlive ) #Packages PACKAGES=" minidlna libsecret-tools libglu1-mesa preload apt-transport-https zram-tools samba samba-common nfs-common nfs-kernel-server linux-cpupower locales redis cockpit cockpit-podman flatpak powertop blueman cups acpi packagekit cockpit-packagekit cockpit-pcp cockpit-storaged acpid podman ghostscript cifs-utils ntp vim-airline rsync screen base udev git network-manager efibootmgr linux-headers-amd64 cryptsetup network-manager-openvpn ntp screen docbook-xsl alsa-utils sysstat redis neofetch fuse3 build-essential unzip bash-completion parted dosfstools wget curl " SHARED_DESKTOP_APPS=" firefox-esr yt-dlp keepassxc rssguard telegram-desktop gnome-core gimp gnome-tweaks evolution nextcloud-desktop gnome-photos handbrake vlc libreoffice " +XFCE_SHARED_DESKTOP_APPS=" task-xfce-desktop gnome-keyring firefox-esr yt-dlp keepassxc rssguard telegram-desktop gimp evolution nextcloud-desktop gnome-photos handbrake vlc libreoffice" #Removed for Debian Bullseye. Works on Bookworm #REMOVED=" aardvark-dns podman-compose podman-toolbox " VIRTUALIZATION=" virt-manager qemu-system libvirt-daemon-system ovmf cockpit-machines" @@ -66,6 +67,7 @@ SERVICES+=( powertop preload ); auto_login(){ sed -i "/#WaylandEnable=false/a AutomaticLoginEnable=True" $TARGET/etc/gdm3/daemon.conf sed -i "/True/a AutomaticLogin=$USER" $TARGET/etc/gdm3/daemon.conf + sed -i "s/#autologin-user=/autologin-user=$USER/" $TARGET/etc/lightdm/lightdm.conf } create-smb-snapshots(){ @@ -168,23 +170,24 @@ additional-software(){ } configure-repository(){ + echo 'force-unsafe-io' > $TARGET/etc/dpkg/dpkg.cfg.d/docker-apt-speedup + if [ "$DEBIAN_RELEASE" == "testing" ];then - echo "deb https://deb.debian.org/debian $DEBIAN_RELEASE main contrib non-free non-free-firmware" >$TARGET/etc/apt/sources.list - else - echo "deb https://deb.debian.org/debian $DEBIAN_RELEASE main contrib non-free" >$TARGET/etc/apt/sources.list - fi - - chroot $TARGET /usr/bin/apt update - chroot $TARGET /usr/bin/bash -c "export DEBIAN_FRONTEND=noninteractive;/usr/bin/apt install -y $PACKAGES" - - if [ "$DEBIAN_RELEASE" == "stable" ];then + echo "deb https://deb.debian.org/debian $DEBIAN_RELEASE main contrib non-free non-free-firmware" >$TARGET/etc/apt/sources.list + chroot $TARGET /usr/bin/apt update + chroot $TARGET /usr/bin/bash -c "export DEBIAN_FRONTEND=noninteractive;/usr/bin/apt install -y $PACKAGES" + else + echo "deb https://deb.debian.org/debian $DEBIAN_RELEASE main contrib non-free" >$TARGET/etc/apt/sources.list echo "deb https://deb.debian.org/debian-security $DEBIAN_RELEASE-security main" >>$TARGET/etc/apt/sources.list echo "deb https://deb.debian.org/debian $DEBIAN_RELEASE-updates main " >>$TARGET/etc/apt/sources.list echo "deb https://deb.debian.org/debian $DEBIAN_RELEASE-backports main" >>$TARGET/etc/apt/sources.list chroot $TARGET /usr/bin/apt update + chroot $TARGET /usr/bin/bash -c "export DEBIAN_FRONTEND=noninteractive;/usr/bin/apt install -y $PACKAGES" chroot $TARGET /usr/bin/bash -c "export DEBIAN_FRONTEND=noninteractive;/usr/bin/apt dist-upgrade -y -t $CURRENT_STABLE_NAME-backports" chroot $TARGET /usr/bin/bash -c "export DEBIAN_FRONTEND=noninteractive;/usr/bin/apt auto-remove -y" fi + + echo 'DPkg::Post-Invoke {"/usr/bin/debian.sh snapshot";};' > $TARGET/etc/apt/apt.conf } install() { @@ -195,7 +198,6 @@ install() { apt update;apt install debootstrap -y rm -rf /debootstrap debootstrap --arch amd64 $DEBIAN_RELEASE $TARGET https://deb.debian.org/debian - apt-tweaks systemMounts cp -f /etc/resolv.conf $TARGET/etc/ echo "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" > $TARGET/setup.sh @@ -211,11 +213,6 @@ install() { unmount } -apt-tweaks(){ - echo 'DPkg::Post-Invoke {"/usr/bin/debian.sh snapshot";};' > $TARGET/etc/apt/apt.conf - echo 'force-unsafe-io' > $TARGET/etc/dpkg/dpkg.cfg.d/docker-apt-speedup -} - desktop(){ SERVICES+=( exim4 cockpit.socket redis-server apparmor nfs-server smbd rpbind rpcbind.socket avahi-daemon bluetooth minidlna openvpn); for i in "${SERVICES[@]}"