From 78768c2cd667f409b2b1a668792fd3991026299c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 11 Feb 2024 13:24:35 +0100 Subject: [PATCH 001/266] v9.1 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index a0a7993fc7..bcde590892 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6267,7 +6267,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.7.13/kavita-linux-$arch.tar.gz" + local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.7.14/kavita-linux-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Kareadita/Kavita/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/kavita-linux-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC chmod +x Kavita/Kavita @@ -9976,7 +9976,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.12.2.4211/Prowlarr.master.1.12.2.4211.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.13.3.4273/Prowlarr.master.1.13.3.4273.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Prowlarr/Prowlarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC mv Prowlarr /opt/prowlarr fi From 2254bbbd5f0a8e3a1354461ae46d959c35a1525c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 11 Feb 2024 13:40:44 +0100 Subject: [PATCH 002/266] v9.1 - CI | Re-add ARMv6/Raspbian Trixie tests and builds - CI | Stop running workflows in tmpfs and define bourne shell explicitly, as both has no performance benefit in GitHub runners --- .github/workflows/amiberry.yml | 4 ---- .github/workflows/armbian.yml | 3 --- .github/workflows/dietpi-build.yml | 4 ---- .github/workflows/dietpi-software-build.yml | 1 - .github/workflows/dietpi-software.yml | 5 ----- .github/workflows/quartz64.yml | 4 ---- .github/workflows/raspberrypi-sys-mods.yml | 4 ---- .github/workflows/shellcheck.yml | 10 ++-------- 8 files changed, 2 insertions(+), 33 deletions(-) diff --git a/.github/workflows/amiberry.yml b/.github/workflows/amiberry.yml index ad64e136e5..f23af7750c 100644 --- a/.github/workflows/amiberry.yml +++ b/.github/workflows/amiberry.yml @@ -19,10 +19,6 @@ concurrency: group: ${{ github.workflow }}-${{ github.event.inputs.plat }}-${{ github.event.inputs.dist }} cancel-in-progress: true permissions: {} -defaults: - run: - shell: sh - working-directory: /dev/shm jobs: prep: outputs: diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 4fdb12c767..1872a37956 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -25,9 +25,6 @@ concurrency: group: ${{ github.workflow }}-${{ github.event.inputs.asset }}-${{ github.event.inputs.branch }}-${{ github.event.inputs.board }} cancel-in-progress: true permissions: {} -defaults: - run: - shell: sh jobs: build: name: "${{ github.event.inputs.asset }} - ${{ github.event.inputs.branch }} - ${{ github.event.inputs.board }}" diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index 98e6cbbf41..7418112793 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -9,10 +9,6 @@ concurrency: group: ${{ github.workflow }}-${{ github.event.inputs.buildargs }} cancel-in-progress: true permissions: {} -defaults: - run: - working-directory: /dev/shm - shell: sh jobs: prep: outputs: diff --git a/.github/workflows/dietpi-software-build.yml b/.github/workflows/dietpi-software-build.yml index f8fcdb2c05..0570711301 100644 --- a/.github/workflows/dietpi-software-build.yml +++ b/.github/workflows/dietpi-software-build.yml @@ -67,7 +67,6 @@ jobs: exclude: - { arch: riscv64, dist: bullseye } - { arch: riscv64, dist: bookworm } - - { arch: armv6l, dist: trixie } - { arch: armv7l, name: gogs } - { arch: aarch64, name: gogs } - { arch: x86_64, name: gogs } diff --git a/.github/workflows/dietpi-software.yml b/.github/workflows/dietpi-software.yml index b0ce11cb13..d1419f9ea4 100644 --- a/.github/workflows/dietpi-software.yml +++ b/.github/workflows/dietpi-software.yml @@ -33,10 +33,6 @@ concurrency: group: ${{ github.workflow }}-${{ github.event.inputs.arch }}-${{ github.event.inputs.dist }}-${{ github.event.inputs.soft }} cancel-in-progress: true permissions: {} -defaults: - run: - shell: sh - #working-directory: /dev/shm # uses too much RAM which can lead to OOM kills jobs: prep: # https://github.com/actions/runner-images @@ -70,7 +66,6 @@ jobs: exclude: - { arch: riscv64, dist: bullseye } - { arch: riscv64, dist: bookworm } - - { arch: armv6l, dist: trixie } fail-fast: false name: "${{ matrix.arch }} - ${{ matrix.dist }} - ${{ github.event.inputs.soft }}" runs-on: ubuntu-22.04 diff --git a/.github/workflows/quartz64.yml b/.github/workflows/quartz64.yml index bc397ce3d7..a176196e67 100644 --- a/.github/workflows/quartz64.yml +++ b/.github/workflows/quartz64.yml @@ -4,10 +4,6 @@ concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true permissions: {} -defaults: - run: - shell: sh - working-directory: /dev/shm jobs: build: # https://github.com/actions/runner-images diff --git a/.github/workflows/raspberrypi-sys-mods.yml b/.github/workflows/raspberrypi-sys-mods.yml index 528c7080f4..ea4e845776 100644 --- a/.github/workflows/raspberrypi-sys-mods.yml +++ b/.github/workflows/raspberrypi-sys-mods.yml @@ -4,10 +4,6 @@ concurrency: group: ${{ github.workflow }} cancel-in-progress: true permissions: {} -defaults: - run: - shell: sh - working-directory: /dev/shm jobs: build: # https://github.com/actions/runner-images diff --git a/.github/workflows/shellcheck.yml b/.github/workflows/shellcheck.yml index 133655760e..b1ad481941 100644 --- a/.github/workflows/shellcheck.yml +++ b/.github/workflows/shellcheck.yml @@ -5,17 +5,12 @@ concurrency: cancel-in-progress: true permissions: contents: read -defaults: - run: - shell: sh jobs: shellcheck: if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.owner.login != github.event.pull_request.base.repo.owner.login # https://github.com/actions/runner-images runs-on: ubuntu-22.04 steps: - - name: Setup tmpfs - run: sudo mount -t tmpfs -o "noatime,lazytime,uid=$(id -u)" tmpfs "$GITHUB_WORKSPACE" - uses: actions/checkout@v4 - name: Setup DietPi-Globals run: | @@ -25,11 +20,10 @@ jobs: echo 'G_HW_MEMORY_SIZE=1024\nG_HW_ONBOARD_WIFI=1' | sudo tee -a /boot/dietpi/.hw_model - name: Download shellcheck run: | - curl -sSfL "$(curl -sSfH 'Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' 'https://api.github.com/repos/koalaman/shellcheck/releases/latest' | mawk -F\" '/"browser_download_url.*\.linux\.x86_64\.tar\.xz"/{print $4;exit}')" -o shellcheck.tar.xz + curl -sSfLo shellcheck.tar.xz "$(curl -sSfH 'Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' 'https://api.github.com/repos/koalaman/shellcheck/releases/latest' | mawk -F\" '/"browser_download_url.*\.linux\.x86_64\.tar\.xz"/{print $4;exit}')" tar --wildcards --strip-components=1 -xf shellcheck.tar.xz '*/shellcheck' rm shellcheck.tar.xz - name: Run shellcheck - shell: bash run: | mapfile -t FILES < <(find . -not \( -path './.git' -prune \) -type f) # read all files to array for i in "${!FILES[@]}" @@ -39,10 +33,10 @@ jobs: unset -v "FILES[$i]" # else remove from array done ./shellcheck -C -xo all "${FILES[@]}" + rm shellcheck - name: Check for trailing spaces if: always() run: | - rm shellcheck ! grep -rn --exclude-dir='.git' -I '[[:blank:]]$' . - name: Check for multiple newlines if: always() From e42e42004fd6b8722a8819de9cabc607821dc3e8 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 11 Feb 2024 14:01:54 +0100 Subject: [PATCH 003/266] v9.1 - CI | Fix shellcheck --- .github/workflows/shellcheck.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/shellcheck.yml b/.github/workflows/shellcheck.yml index b1ad481941..6ac2dba1c6 100644 --- a/.github/workflows/shellcheck.yml +++ b/.github/workflows/shellcheck.yml @@ -17,7 +17,7 @@ jobs: sudo mkdir -p /boot/dietpi/func sudo cp dietpi/func/dietpi-globals /boot/dietpi/func/ sudo ./dietpi/func/dietpi-obtain_hw_model - echo 'G_HW_MEMORY_SIZE=1024\nG_HW_ONBOARD_WIFI=1' | sudo tee -a /boot/dietpi/.hw_model + echo -e 'G_HW_MEMORY_SIZE=1024\nG_HW_ONBOARD_WIFI=1' | sudo tee -a /boot/dietpi/.hw_model - name: Download shellcheck run: | curl -sSfLo shellcheck.tar.xz "$(curl -sSfH 'Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' 'https://api.github.com/repos/koalaman/shellcheck/releases/latest' | mawk -F\" '/"browser_download_url.*\.linux\.x86_64\.tar\.xz"/{print $4;exit}')" From 7bde8713fda287e0b440b08d184b4e09a89a8e2b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 12 Feb 2024 23:21:44 +0100 Subject: [PATCH 004/266] v9.1 - DietPi-Drive_Manager | Recheck for required APT packages, in case a new drive got attached --- dietpi/dietpi-drive_manager | 1 + 1 file changed, 1 insertion(+) diff --git a/dietpi/dietpi-drive_manager b/dietpi/dietpi-drive_manager index 6102ab0e92..8a720cc14c 100755 --- a/dietpi/dietpi-drive_manager +++ b/dietpi/dietpi-drive_manager @@ -886,6 +886,7 @@ Do you wish to ignore this warning, and, mount the drive regardless?" || return # Refresh if [[ $G_WHIP_RETURNED_VALUE == 'Refresh' ]]; then + APT_CHECK=0 # Recheck for required APT packages, in case a new drive got attached Init_Drives_and_Refresh elif [[ $G_WHIP_RETURNED_VALUE == 'Add network drive' ]]; then From d5696757ddc9e7e4c8352413aa75df0809ad5292 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 12 Feb 2024 23:28:31 +0100 Subject: [PATCH 005/266] v9.1 - DietPi-Software | Lidarr: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index bcde590892..1f6c6bf4bc 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9629,7 +9629,7 @@ _EOF_ esac url=$(curl -sSfL 'https://api.github.com/repos/Lidarr/Lidarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}") - local fallback_url="https://github.com/Lidarr/Lidarr/releases/download/v2.0.7.3849/Lidarr.master.2.0.7.3849.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Lidarr/Lidarr/releases/download/v2.1.7.4030/Lidarr.master.2.1.7.4030.linux-core-$arch.tar.gz" fi Download_Install "$url" From c14ea6c129bf21c017a019382b87be3811116f74 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 14 Feb 2024 19:30:40 +0100 Subject: [PATCH 006/266] v9.1 - META | DietPi-Survey_report: Add RPi 5 support --- .meta/dietpi-survey_report | 1 + 1 file changed, 1 insertion(+) diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index 6a27a30d67..4467f6be2d 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -17,6 +17,7 @@ shopt -s extglob [2]='Raspberry Pi 2' [3]='Raspberry Pi 3/3+/Zero 2' [4]='Raspberry Pi 4' + [5]='Raspberry Pi 5' [10]='Odroid C1' [11]='Odroid XU3/XU4/MC1/HC1/HC2' [12]='Odroid C2' From c815a790dd5a30065c8e9735ad1353b2e7b32175 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 14 Feb 2024 20:41:31 +0100 Subject: [PATCH 007/266] v9.1 (#6912) - ROCK 4 | Fix support for ROCK 4 SE --- .build/images/dietpi-build | 3 ++- .build/images/dietpi-installer | 9 +++++++-- .github/workflows/dietpi-build.yml | 3 ++- CHANGELOG.txt | 1 + 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index d8bd5a57a2..beb1d9eb04 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -122,7 +122,8 @@ case $HW_MODEL in '68.2') iname='NanoPCT4' HW_ARCH=3 partition_start=16 root_size=880;; '68.3') iname='NanoPiNEO4' HW_ARCH=3 partition_start=16 root_size=880;; 70) iname='SparkySBC' HW_ARCH=2 partition_start=8 boot_size=48 root_size=712 boot_fstype='fat16';; - 72) iname='ROCKPi4' HW_ARCH=3 partition_start=16 root_size=880;; + '72.1') iname='ROCKPi4' HW_ARCH=3 partition_start=16 root_size=880;; + '72.2') iname='ROCK4SE' HW_ARCH=3 partition_start=16 root_size=880;; 73) iname='ROCKPiS' HW_ARCH=3 partition_start=16 root_size=880;; 74) iname='RadxaZero' HW_ARCH=3 partition_start=4 root_size=892;; 75) iname='Container' HW_ARCH=${HW_ARCH:-10} root_size=447;; diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index e1b067f719..454b88a612 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -407,7 +407,8 @@ _EOF_ '47' ': NanoPi R4S' '76' ': NanoPi R5S/R5C' '79' ': NanoPi 6 series' - '72' ': ROCK 4' + '72.1' ': ROCK 4 (all other variants)' + '72.2' ': ROCK 4 SE' '73' ': ROCK Pi S' '74' ': Radxa Zero' '77' ': ROCK 3A' @@ -1080,7 +1081,11 @@ _EOF_ 3) model='nanopineo4';; *) model='nanopct4';; esac;; - 72) model='rockpi-4b' kernel='rockchip64';; + 72) kernel='rockchip64' + case $HW_VARIANT in + 1) model='rockpi-4b';; + *) model='rock-4se';; + esac;; 73) model='rockpi-s' kernel='rockchip64';; 74) model='radxa-zero';; 77) model='rock-3a' kernel='rockchip64';; diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index 7418112793..ae9014e487 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -64,7 +64,8 @@ jobs: '"-m 68.2 -d 6", "-m 68.2 -d 7", "-m 68.2 -d 8", '\ '"-m 68.3 -d 6", "-m 68.3 -d 7", "-m 68.3 -d 8", '\ '"-m 70 -d 6 -e all", '\ - '"-m 72 -d 6", "-m 72 -d 7", "-m 72 -d 8", '\ + '"-m 72.1 -d 6", "-m 72.1 -d 7", "-m 72.1 -d 8", '\ + '"-m 72.2 -d 6", "-m 72.2 -d 7", "-m 72.2 -d 8", '\ '"-m 73 -d 6", "-m 73 -d 7", "-m 73 -d 8", '\ '"-m 74 -d 6", "-m 74 -d 7", "-m 74 -d 8", '\ '"-m 75 -a 1 -d 6", "-m 75 -a 2 -d 6", "-m 75 -a 3 -d 6", "-m 75 -a 10 -d 6", '\ diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 547d13aa72..9a23f3b82c 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,6 +2,7 @@ v9.1 (2024-02-17) New images: +- ROCK 4 SE | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4 SE variant, we provide a new image for this particular variant. Many thanks to @janno for reporting failing boot on this SBC: https://dietpi.com/forum/t/radxa-rock-4-se-supported-not-booting/19263 Enhancements: - DietPi-Software | Domoticz: Enabled for x86_64 Bookworm and Trixie systems, since the latest x86_64 builds were compiled against libssl3. From ab6b2b45598f257fe587bb578338117917da5200 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 15 Feb 2024 19:16:54 +0100 Subject: [PATCH 008/266] v9.1 - RC up --- .update/version | 2 +- dietpi/func/dietpi-globals | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.update/version b/.update/version index 64bd3428b0..44362066a1 100644 --- a/.update/version +++ b/.update/version @@ -3,7 +3,7 @@ # Available DietPi version G_REMOTE_VERSION_CORE=9 G_REMOTE_VERSION_SUB=1 -G_REMOTE_VERSION_RC=-1 +G_REMOTE_VERSION_RC=0 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 551a36c087..49892ed67e 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -55,7 +55,7 @@ # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=1 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=-1 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=0 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From 3cef6e85aad26790f57ee1a4c0a29904ff984176 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 15 Feb 2024 19:42:23 +0100 Subject: [PATCH 009/266] v9.1 - DietPi-Patches | Complement patches and merge accidentally doubled v9.0 patch function - CHANGELOG | Add missing changelog entries --- .update/patches | 16 ++++++++-------- CHANGELOG.txt | 3 +++ 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/.update/patches b/.update/patches index 1c9041d2e5..da5b34328c 100755 --- a/.update/patches +++ b/.update/patches @@ -1568,8 +1568,15 @@ Patch_9_0() fi } -Patch_9_0() +Patch_9_1() { + # Raspberry Pi + if [[ -f '/etc/kernel/postinst.d/dietpi-USBridgeSig' ]] + then + G_DIETPI-NOTIFY 2 'Removing obsolete USBridge Sig driver update script, since Allo does not provides those for revent kernel versions anymore' + G_EXEC rm /etc/kernel/postinst.d/dietpi-USBridgeSig + fi + # Software updates and migrations if [[ -f '/boot/dietpi/.installed' ]] then @@ -1587,14 +1594,7 @@ map $arg_v $asset_immutable { G_EXEC curl -sSfo /etc/nginx/sites-dietpi/dietpi-nextcloud.conf "https://raw.githubusercontent.com/$G_GITOWNER/DietPi/$G_GITBRANCH/.conf/dps_114/nginx.nextcloud.conf" [[ -f '/etc/nginx/sites-dietpi/dietpi-nextcloud.conf.dietpi-new' ]] && G_EXEC rm /etc/nginx/sites-dietpi/dietpi-nextcloud.conf.dietpi-new fi - fi -} -Patch_9_1() -{ - # Software updates and migrations - if [[ -f '/boot/dietpi/.installed' ]] - then # GMediaRender: https://dietpi.com/forum/t/gmediarender-default-args-on-allo-image-for-raspberry-pi/19205 if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[163\]=2' /boot/dietpi/.installed && grep -q ' -f -I ' /etc/default/gmediarender then diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 9a23f3b82c..2f2b793d97 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,6 +2,7 @@ v9.1 (2024-02-17) New images: +- Raspberry Pi 5 | Images for Raspberry Pi 5 and other Raspberry Pi models, based on the new Bookworm kernel and firmware package set from Raspberry Pi Ltd, are now available for testing. Note that some features, like changing screen resolution and camera module support, are not working yet: https://dietpi.com/downloads/binaries/testing/ - ROCK 4 SE | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4 SE variant, we provide a new image for this particular variant. Many thanks to @janno for reporting failing boot on this SBC: https://dietpi.com/forum/t/radxa-rock-4-se-supported-not-booting/19263 Enhancements: @@ -10,10 +11,12 @@ Enhancements: - DietPi-Software | Home Assistant: The Python version installed with Home Assistant has been raised to 3.12.1, to align with official appliances. Many thanks to @whyisthisbroken for making us aware if it: https://github.com/MichaIng/DietPi/issues/6906 Bug fixes: +- DietPi-FS_partition_resize | Resolved an issue where on Bullseye images, the root partition and filesystem was not expanded on first boot. Many thanks to @naddel91 and others for reporting this issue: https://dietpi.com/forum/t/increase-partition-size/19015 - DietPi-Software | Mosquitto: Resolved an issue where the global software password was accidentally applied as username instead of as password: https://github.com/MichaIng/DietPi/issues/6886 - DietPi-Software | Amiberry: Resolved an issue where the installation failed on 64-bit RPi systems. Many thanks to @JerichoCross for reporting this issue: https://github.com/MichaIng/DietPi/issues/6893 - DietPi-Software | GMediaRender: Resolved an issue where the default command arguments were not set correctly on a fresh install. Many thanks to @ransur0t for reporting this issue: https://dietpi.com/forum/t/gmediarender-default-args-on-allo-image-for-raspberry-pi/19205 - DietPi-Software | Samba Server: Resolved an issue where our configuration file was not installed if the Samba Client was installed as well, or an SMB/CIFS mount done. Many thanks to @TheCrystalGipsy for reporting this issue: https://dietpi.com/forum/t/samba-share-issues-need-help/19224 +- DietPi-Software | Pydio: Resolved an issue where web access via Apache webserver did not work, due to an invalid config entry. However, Pydio 8 is not maintained since years, does not support PHP 8 and hence can only work on Bullseye systems. We will migrate to Pydio Cells, once someone finds time to work on this: https://github.com/MichaIng/DietPi/issues/3469 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME From 0d018772e37b350ce943fcf3e726503f79505a68 Mon Sep 17 00:00:00 2001 From: zuble <67658465+zuble@users.noreply.github.com> Date: Sat, 17 Feb 2024 19:41:54 +0000 Subject: [PATCH 010/266] v9.1 (#6918) - DietPi-Backup/Sync | Both scripts do now only error out when the "rsync" process is already running, rather than on any process which has the term "rsync" in its name --- CHANGELOG.txt | 1 + dietpi/dietpi-backup | 4 ++-- dietpi/dietpi-sync | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 2f2b793d97..3aaabf053e 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,6 +6,7 @@ New images: - ROCK 4 SE | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4 SE variant, we provide a new image for this particular variant. Many thanks to @janno for reporting failing boot on this SBC: https://dietpi.com/forum/t/radxa-rock-4-se-supported-not-booting/19263 Enhancements: +- DietPi-Backup/Sync | Both scripts do now only error out when the "rsync" process is already running, rather than on any process which has the term "rsync" in its name. Many thanks to @zuble for implementing this enhancement: https://github.com/MichaIng/DietPi/pull/6918 - DietPi-Software | Domoticz: Enabled for x86_64 Bookworm and Trixie systems, since the latest x86_64 builds were compiled against libssl3. - DietPi-Software | vaultwarden: Along with a regular update, RISC-V support has been added. - DietPi-Software | Home Assistant: The Python version installed with Home Assistant has been raised to 3.12.1, to align with official appliances. Many thanks to @whyisthisbroken for making us aware if it: https://github.com/MichaIng/DietPi/issues/6906 diff --git a/dietpi/dietpi-backup b/dietpi/dietpi-backup index 0b502b24c8..733b6d3bda 100755 --- a/dietpi/dietpi-backup +++ b/dietpi/dietpi-backup @@ -168,7 +168,7 @@ _EOF_ /boot/dietpi/dietpi-services stop # Check if rsync is already running, while the daemon should have been stopped above - pgrep 'rsync' &> /dev/null && { Error_Rsync_Already_Running 'Backup'; return 1; } + pgrep -x 'rsync' &> /dev/null && { Error_Rsync_Already_Running 'Backup'; return 1; } # Install required rsync if missing G_AG_CHECK_INSTALL_PREREQ rsync @@ -375,7 +375,7 @@ However, this check is a rough estimation in reasonable time, thus it could be m /boot/dietpi/dietpi-services stop # Check if rsync is already running, while the daemon should have been stopped above - pgrep 'rsync' &> /dev/null && { Error_Rsync_Already_Running 'Restore'; return 1; } + pgrep -x 'rsync' &> /dev/null && { Error_Rsync_Already_Running 'Restore'; return 1; } # Install required rsync if missing G_AG_CHECK_INSTALL_PREREQ rsync diff --git a/dietpi/dietpi-sync b/dietpi/dietpi-sync index 953bcbce00..4b404c7ee5 100755 --- a/dietpi/dietpi-sync +++ b/dietpi/dietpi-sync @@ -117,7 +117,7 @@ _EOF_ echo "$(date +"%Y-%m-%d_%T") [FAILED] The chosen source directory is empty: $FP_SOURCE" >> "$FP_TARGET/$FP_LOG" # Error: Rsync still running - elif pgrep '[r]sync' &> /dev/null; then + elif pgrep -x 'rsync' &> /dev/null; then G_WHIP_MSG '[FAILED] Rsync is already running and failed to stop gracefully\n\nPlease check active rsync processes e.g. via "htop" and finish or kill them.' # Log to target dir directly, preserve previous rsync log From a0fcf01d2c60cefee38bffa57689a808cdac0389 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 17 Feb 2024 20:49:29 +0100 Subject: [PATCH 011/266] v9.1 - DietPi-Sync | Spelling --- dietpi/dietpi-sync | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-sync b/dietpi/dietpi-sync index 4b404c7ee5..de6968305d 100755 --- a/dietpi/dietpi-sync +++ b/dietpi/dietpi-sync @@ -112,7 +112,7 @@ _EOF_ # Error: Empty source dir elif [[ ! $(ls -A "$FP_SOURCE") ]]; then - G_WHIP_MSG "[FAILED] The chosen source directory is empty: $FP_SOURCE\n\nPlease check it's path and in case verify that it's mount is active." + G_WHIP_MSG "[FAILED] The chosen source directory is empty: $FP_SOURCE\n\nPlease check its path and in case verify that its mount is active." # Log to target dir directly, preserve previous rsync log echo "$(date +"%Y-%m-%d_%T") [FAILED] The chosen source directory is empty: $FP_SOURCE" >> "$FP_TARGET/$FP_LOG" From 867c2b550ff58002a3e9a3db2be7b7d68089fe75 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 17 Feb 2024 22:46:12 +0100 Subject: [PATCH 012/266] v9.1 - ROCK 4 SE | Install more recent rockchip64 kernel form our server, required to have the ROCK 4 SE device tree, and assure that this device tree is used. --- .build/images/dietpi-installer | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 454b88a612..1f63059bb6 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -670,6 +670,7 @@ setenv rootuuid "true"' /boot/boot.cmd 46) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3399-pinebook-pro.dtb' /boot/dietpiEnv.txt;; 55) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3328-nanopi-r2-rev00.dtb' /boot/dietpiEnv.txt;; # Not necessarily needed as rk3328-nanopi-r2s.dtb is automatically chosen, but provides more consistent /sys/class/leds/{wan,lan}_led interface and blinking instead of steady lid power LED 56) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3328-nanopi-neo3-rev02.dtb' /boot/dietpiEnv.txt;; # Loads rk3328-nanopi-r2s.dtb by default + 72) (( $HW_VARIANT == 2 )) && G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3399-rock-4se.dtb' /boot/dietpiEnv.txt;; 73) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3308-rock-pi-s.dtb' /boot/dietpiEnv.txt;; # U-Boot does not pass any ${fdtfile} 77) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3568-rock-3a.dtb' /boot/dietpiEnv.txt;; 78) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3588-rock-5b.dtb' /boot/dietpiEnv.txt;; @@ -1083,8 +1084,8 @@ _EOF_ esac;; 72) kernel='rockchip64' case $HW_VARIANT in - 1) model='rockpi-4b';; - *) model='rock-4se';; + 2) model='rock-4se';; + *) model='rockpi-4b';; esac;; 73) model='rockpi-s' kernel='rockchip64';; 74) model='radxa-zero';; @@ -1139,7 +1140,7 @@ _EOF_ G_AGI initramfs-tools u-boot-tools armbian-firmware "${zstd[@]}" [[ ${zstd[0]} ]] && G_CONFIG_INJECT 'COMPRESS=' 'COMPRESS=zstd' /etc/initramfs-tools/initramfs.conf # Download and pre-install kernel hosted on dietpi.com where the Armbian APT repo provides a too old version - if (( $G_HW_MODEL == 83 )) + if (( ( $G_HW_MODEL == 72 && ${HW_VARIANT:-1} == 2 ) || $G_HW_MODEL == 83 )) then G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb "https://dietpi.com/downloads/binaries/linux-image-$branch-$kernel.deb" G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb "https://dietpi.com/downloads/binaries/linux-dtb-$branch-$kernel.deb" @@ -1152,7 +1153,6 @@ _EOF_ if (( $G_HW_MODEL == 83 )) && (( $HW_VARIANT == 2 )) then G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-u-boot-orangepizero3-next_1.5G.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb G_AGI linux-{image,dtb}-"$branch-$kernel" ./package.deb G_EXEC rm package.deb else From 44b9c2ea51e9162dce03e0ed256b353b44f3b5d9 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 17 Feb 2024 23:34:45 +0100 Subject: [PATCH 013/266] v9.1 - DietPi-Software | Navidrome: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 1f6c6bf4bc..5f577790c3 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6171,7 +6171,7 @@ _EOF_ *) local arch='amd64';; esac - local fallback_url="https://github.com/navidrome/navidrome/releases/download/v0.50.2/navidrome_0.50.2_linux_$arch.tar.gz" + local fallback_url="https://github.com/navidrome/navidrome/releases/download/v0.51.1/navidrome_0.51.1_linux_$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/navidrome/navidrome/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/navidrome_[0-9.]*_linux_$arch\.tar\.gz\"$/{print \$4}")" /opt/navidrome # Data dir From 4cb88f8d330cf48dac9255a81ae4d838b5abc58c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 18 Feb 2024 00:23:52 +0100 Subject: [PATCH 014/266] v9.1 - DietPi-Software | OctoPrint: Resolved an issue where system restart and shutdown form the OctoPrint UI failed due to an invalid sudoers rule. Many thanks to @samjw-nz for reporting this issue: https://github.com/MichaIng/DietPi/issues/6915 - DietPi-Patches | Since we rename armbian.list to dietpi-armbian.list via pre-patch, it is not required anymore to patch both variants --- .update/patches | 12 +++++++----- CHANGELOG.txt | 1 + dietpi/dietpi-software | 4 ++-- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/.update/patches b/.update/patches index da5b34328c..7ad23f72d9 100755 --- a/.update/patches +++ b/.update/patches @@ -785,11 +785,6 @@ Patch_8_10() Patch_8_11() { # Armbian mirror director now correctly handles HTTPS requests - if [[ -f '/etc/apt/sources.list.d/armbian.list' ]] && grep -q 'http://apt.armbian.com' /etc/apt/sources.list.d/armbian.list - then - G_DIETPI-NOTIFY 2 'Connecting to apt.armbian.com via secure HTTPS since their router now handles HTTPS redirects reliably' - G_EXEC sed --follow-symlinks -i 's|http://apt.armbian.com|https://apt.armbian.com|' /etc/apt/sources.list.d/armbian.list - fi if [[ -f '/etc/apt/sources.list.d/dietpi-armbian.list' ]] && grep -q 'http://apt.armbian.com' /etc/apt/sources.list.d/dietpi-armbian.list then G_DIETPI-NOTIFY 2 'Connecting to apt.armbian.com via secure HTTPS since their router now handles HTTPS redirects reliably' @@ -1601,6 +1596,13 @@ map $arg_v $asset_immutable { G_DIETPI-NOTIFY 2 'Fixing default GMediaRender command arguments' G_EXEC sed -i "s/ -f -I / -f $HOSTNAME -I /" /etc/default/gmediarender fi + + # OctoPrint: https://github.com/MichaIng/DietPi/issues/6915 + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[153\]=2' /boot/dietpi/.installed && grep -q ', reboot, poweroff' /etc/sudoers.d/octoprint + then + G_DIETPI-NOTIFY 2 'Fixing OctoPrint sudoers rule' + G_EXEC sed -i "s|, reboot, poweroff|, $(which reboot), $(which poweroff)|" /etc/sudoers.d/octoprint + fi fi } diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 3aaabf053e..8992e0e6fe 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -18,6 +18,7 @@ Bug fixes: - DietPi-Software | GMediaRender: Resolved an issue where the default command arguments were not set correctly on a fresh install. Many thanks to @ransur0t for reporting this issue: https://dietpi.com/forum/t/gmediarender-default-args-on-allo-image-for-raspberry-pi/19205 - DietPi-Software | Samba Server: Resolved an issue where our configuration file was not installed if the Samba Client was installed as well, or an SMB/CIFS mount done. Many thanks to @TheCrystalGipsy for reporting this issue: https://dietpi.com/forum/t/samba-share-issues-need-help/19224 - DietPi-Software | Pydio: Resolved an issue where web access via Apache webserver did not work, due to an invalid config entry. However, Pydio 8 is not maintained since years, does not support PHP 8 and hence can only work on Bullseye systems. We will migrate to Pydio Cells, once someone finds time to work on this: https://github.com/MichaIng/DietPi/issues/3469 +- DietPi-Software | OctoPrint: Resolved an issue where system restart and shutdown form the OctoPrint UI failed due to an invalid sudoers rule. Many thanks to @samjw-nz for reporting this issue: https://github.com/MichaIng/DietPi/issues/6915 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 5f577790c3..58e4aab14a 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10211,8 +10211,8 @@ _EOF_ # On fresh installs, change listening port to 5001 to avoid conflict with Shairport Sync. [[ -f '/mnt/dietpi_userdata/octoprint/.octoprint/config.yaml' ]] || G_EXEC sudo -u octoprint /mnt/dietpi_userdata/octoprint/.local/bin/octoprint config set server.port '5001' - # Apply service and system commands: Allow execution via specific sudoers config - echo "octoprint ALL=NOPASSWD: $(command -v systemctl) restart octoprint, $(command -v reboot), $(command -v poweroff)" > /etc/sudoers.d/octoprint + # Apply service and system commands: Allow execution via specific sudoers config, use "which" for "reboot" and "poweroff", since we create shell functions in dietpi-globals to bypass logind calls, if logind is not running. + echo "octoprint ALL=NOPASSWD: $(command -v systemctl) restart octoprint, $(which reboot), $(which poweroff)" > /etc/sudoers.d/octoprint G_EXEC sudo -u octoprint /mnt/dietpi_userdata/octoprint/.local/bin/octoprint config set server.commands.serverRestartCommand 'sudo systemctl restart octoprint' G_EXEC sudo -u octoprint /mnt/dietpi_userdata/octoprint/.local/bin/octoprint config set server.commands.systemRestartCommand 'sudo reboot' G_EXEC sudo -u octoprint /mnt/dietpi_userdata/octoprint/.local/bin/octoprint config set server.commands.systemShutdownCommand 'sudo poweroff' From 594ab0743d3279041f2c601d58e982901c4a8d2a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 18 Feb 2024 00:29:51 +0100 Subject: [PATCH 015/266] v9.1 - META | Mute shellcheck about intended "which" call --- dietpi/dietpi-software | 1 + 1 file changed, 1 insertion(+) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 58e4aab14a..ce5476df09 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10212,6 +10212,7 @@ _EOF_ [[ -f '/mnt/dietpi_userdata/octoprint/.octoprint/config.yaml' ]] || G_EXEC sudo -u octoprint /mnt/dietpi_userdata/octoprint/.local/bin/octoprint config set server.port '5001' # Apply service and system commands: Allow execution via specific sudoers config, use "which" for "reboot" and "poweroff", since we create shell functions in dietpi-globals to bypass logind calls, if logind is not running. + # shellcheck disable=SC2230 echo "octoprint ALL=NOPASSWD: $(command -v systemctl) restart octoprint, $(which reboot), $(which poweroff)" > /etc/sudoers.d/octoprint G_EXEC sudo -u octoprint /mnt/dietpi_userdata/octoprint/.local/bin/octoprint config set server.commands.serverRestartCommand 'sudo systemctl restart octoprint' G_EXEC sudo -u octoprint /mnt/dietpi_userdata/octoprint/.local/bin/octoprint config set server.commands.systemRestartCommand 'sudo reboot' From 35756dffb3e09f39ea71dac9da7f2a9aad8e88b2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 18 Feb 2024 00:35:52 +0100 Subject: [PATCH 016/266] v9.1 - META | Mute shellcheck about intended "which" call as well in patches --- .update/patches | 1 + 1 file changed, 1 insertion(+) diff --git a/.update/patches b/.update/patches index 7ad23f72d9..58e557bd1c 100755 --- a/.update/patches +++ b/.update/patches @@ -1601,6 +1601,7 @@ map $arg_v $asset_immutable { if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[153\]=2' /boot/dietpi/.installed && grep -q ', reboot, poweroff' /etc/sudoers.d/octoprint then G_DIETPI-NOTIFY 2 'Fixing OctoPrint sudoers rule' + # shellcheck disable=SC2230 G_EXEC sed -i "s|, reboot, poweroff|, $(which reboot), $(which poweroff)|" /etc/sudoers.d/octoprint fi fi From f891ed89c68ee492d499d022253e65cadae88b2c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 18 Feb 2024 19:39:18 +0100 Subject: [PATCH 017/266] v9.1 - DietPi-Software | Squeezelite: Along with an update to v2.0.0-1466, resolved an issue where in rare cases the service could have started before the network adapter was initialised, in which case it reports a MAC address of 00:00:00:00:00:00 to LMS servers. With multiple Squeezelite players, this could have lead to conflicts among them. Many thanks to `@willefg` for reporting this issue: https://dietpi.com/forum/t/dietpi-squeezelite-players-with-same-mac-address-000000-00/19312 - RC up --- .build/software/squeezelite/build.bash | 3 ++- .update/patches | 19 +++++++++---------- .update/version | 2 +- CHANGELOG.txt | 2 ++ dietpi/dietpi-software | 2 +- dietpi/func/dietpi-globals | 2 +- 6 files changed, 16 insertions(+), 14 deletions(-) diff --git a/.build/software/squeezelite/build.bash b/.build/software/squeezelite/build.bash index b7dcf69aa5..e3f4369f0b 100755 --- a/.build/software/squeezelite/build.bash +++ b/.build/software/squeezelite/build.bash @@ -62,7 +62,8 @@ cat << '_EOF_' > "$DIR/lib/systemd/system/squeezelite.service" [Unit] Description=Squeezelite (DietPi) Documentation=man:squeezelite(1) https://ralph-irving.github.io/squeezelite.html -After=sound.target +Wants=network-online.target +After=network-online.target sound.target [Service] User=squeezelite diff --git a/.update/patches b/.update/patches index 58e557bd1c..291cad8405 100755 --- a/.update/patches +++ b/.update/patches @@ -1205,16 +1205,6 @@ Patch_8_18() [[ -f /lib/systemd/system/$i.service.disable ]] && G_EXEC mv "/lib/systemd/system/$i.service"{.disable,} && G_EXEC systemctl disable "$i" done fi - - # Inform about available software updates - if [[ -f '/boot/dietpi/.installed' ]] - then - # Squeezelite - grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed && G_WHIP_MSG '[ INFO ] Squeezelite update available -\nAn update to Squeezelite v1.9.9-1432 is available. Apply it via reinstall: -# dietpi-software reinstall 36 -\nChange log: https://github.com/ralph-irving/squeezelite/commits/575b593' - fi } Patch_8_19() @@ -1604,6 +1594,15 @@ map $arg_v $asset_immutable { # shellcheck disable=SC2230 G_EXEC sed -i "s|, reboot, poweroff|, $(which reboot), $(which poweroff)|" /etc/sudoers.d/octoprint fi + + # Squeezelite + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' squeezelite 2> /dev/null)" lt 2.0.0-1466-dietpi1 + then + G_DIETPI-NOTIFY 2 'Updating Squeezelite package ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/squeezelite_$G_HW_ARCH_NAME.deb" + G_AGI ./package.deb + G_EXEC rm package.deb + fi fi } diff --git a/.update/version b/.update/version index 44362066a1..ee25551504 100644 --- a/.update/version +++ b/.update/version @@ -3,7 +3,7 @@ # Available DietPi version G_REMOTE_VERSION_CORE=9 G_REMOTE_VERSION_SUB=1 -G_REMOTE_VERSION_RC=0 +G_REMOTE_VERSION_RC=1 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 8992e0e6fe..65617f9ddc 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -10,6 +10,7 @@ Enhancements: - DietPi-Software | Domoticz: Enabled for x86_64 Bookworm and Trixie systems, since the latest x86_64 builds were compiled against libssl3. - DietPi-Software | vaultwarden: Along with a regular update, RISC-V support has been added. - DietPi-Software | Home Assistant: The Python version installed with Home Assistant has been raised to 3.12.1, to align with official appliances. Many thanks to @whyisthisbroken for making us aware if it: https://github.com/MichaIng/DietPi/issues/6906 +- DietPI-Software | Squeezelite: An update to Squeezelite v2.0.0-1466 will be applied during the DietPi update. Bug fixes: - DietPi-FS_partition_resize | Resolved an issue where on Bullseye images, the root partition and filesystem was not expanded on first boot. Many thanks to @naddel91 and others for reporting this issue: https://dietpi.com/forum/t/increase-partition-size/19015 @@ -19,6 +20,7 @@ Bug fixes: - DietPi-Software | Samba Server: Resolved an issue where our configuration file was not installed if the Samba Client was installed as well, or an SMB/CIFS mount done. Many thanks to @TheCrystalGipsy for reporting this issue: https://dietpi.com/forum/t/samba-share-issues-need-help/19224 - DietPi-Software | Pydio: Resolved an issue where web access via Apache webserver did not work, due to an invalid config entry. However, Pydio 8 is not maintained since years, does not support PHP 8 and hence can only work on Bullseye systems. We will migrate to Pydio Cells, once someone finds time to work on this: https://github.com/MichaIng/DietPi/issues/3469 - DietPi-Software | OctoPrint: Resolved an issue where system restart and shutdown form the OctoPrint UI failed due to an invalid sudoers rule. Many thanks to @samjw-nz for reporting this issue: https://github.com/MichaIng/DietPi/issues/6915 +- DietPi-Software | Squeezelite: Resolved an issue where in rare cases the service could have started before the network adapter was initialised, in which case it reports a MAC address of 00:00:00:00:00:00 to LMS servers. With multiple Squeezelite players, this could have lead to conflicts among them. Many thanks to @willefg for reporting this issue: https://dietpi.com/forum/t/dietpi-squeezelite-players-with-same-mac-address-000000-00/19312 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index ce5476df09..b620349fe7 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10051,7 +10051,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.18.2411/Readarr.develop.0.3.18.2411.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.19.2437/Readarr.develop.0.3.19.2437.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Readarr/Readarr/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}" | head -1)" G_EXEC mv Readarr /opt/readarr fi diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 49892ed67e..76cce7eaeb 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -55,7 +55,7 @@ # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=1 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=0 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=1 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From 72240134a12d46a93a60778c1a982320f864527e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 18 Feb 2024 19:40:13 +0100 Subject: [PATCH 018/266] v9.1 - DietPi-Software | Radarr: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index b620349fe7..96117615ee 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9532,7 +9532,7 @@ _EOF_ esac url=$(curl -sSfL 'https://api.github.com/repos/Radarr/Radarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}") - local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.2.6.8376/Radarr.master.5.2.6.8376.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.3.6.8612/Radarr.master.5.3.6.8612.linux-core-$arch.tar.gz" fi Download_Install "$url" From be8465b8efd3d504ba22c8080640d8e83a767e31 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 18 Feb 2024 21:38:43 +0100 Subject: [PATCH 019/266] v9.1 - DietPi-Software | Squeezelite: Freeze commit to workaround the usage of an unmerged feature in libFLAC: https://github.com/ralph-irving/squeezelite/issues/206 --- .build/software/squeezelite/build.bash | 4 +++- .update/patches | 2 +- CHANGELOG.txt | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.build/software/squeezelite/build.bash b/.build/software/squeezelite/build.bash index e3f4369f0b..d345f3ec48 100755 --- a/.build/software/squeezelite/build.bash +++ b/.build/software/squeezelite/build.bash @@ -23,11 +23,13 @@ done G_DIETPI-NOTIFY 2 'Downloading source code...' G_EXEC cd /tmp -G_EXEC curl -sSfLO 'https://github.com/ralph-irving/squeezelite/archive/master.tar.gz' +# Freeze commit: https://github.com/ralph-irving/squeezelite/issues/206 +G_EXEC curl -sSfLO 'https://github.com/ralph-irving/squeezelite/archive/6de9e229aa4cc7c3131ff855f3ead39581127090.tar.gz' [[ -d 'squeezelite-master' ]] && G_EXEC rm -R squeezelite-master G_EXEC tar xf master.tar.gz G_EXEC rm master.tar.gz G_DIETPI-NOTIFY 2 'Compiling binary...' +G_EXEC mv squeezelite-{6de9e229aa4cc7c3131ff855f3ead39581127090,master} G_EXEC cd squeezelite-master G_EXEC_OUTPUT=1 G_EXEC make CFLAGS='-g0 -O3' OPTS='-DDSD -DFFMPEG -DRESAMPLE -DVISEXPORT -DLINKALL -DIR -DUSE_SSL' G_EXEC strip --remove-section=.comment --remove-section=.note squeezelite diff --git a/.update/patches b/.update/patches index 291cad8405..28fb9e81ec 100755 --- a/.update/patches +++ b/.update/patches @@ -1596,7 +1596,7 @@ map $arg_v $asset_immutable { fi # Squeezelite - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' squeezelite 2> /dev/null)" lt 2.0.0-1466-dietpi1 + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' squeezelite 2> /dev/null)" lt 2.0.0-1465-dietpi1 then G_DIETPI-NOTIFY 2 'Updating Squeezelite package ...' G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/squeezelite_$G_HW_ARCH_NAME.deb" diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 65617f9ddc..4ac0d98653 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -10,7 +10,7 @@ Enhancements: - DietPi-Software | Domoticz: Enabled for x86_64 Bookworm and Trixie systems, since the latest x86_64 builds were compiled against libssl3. - DietPi-Software | vaultwarden: Along with a regular update, RISC-V support has been added. - DietPi-Software | Home Assistant: The Python version installed with Home Assistant has been raised to 3.12.1, to align with official appliances. Many thanks to @whyisthisbroken for making us aware if it: https://github.com/MichaIng/DietPi/issues/6906 -- DietPI-Software | Squeezelite: An update to Squeezelite v2.0.0-1466 will be applied during the DietPi update. +- DietPI-Software | Squeezelite: An update to Squeezelite v2.0.0-1465 will be applied during the DietPi update. Bug fixes: - DietPi-FS_partition_resize | Resolved an issue where on Bullseye images, the root partition and filesystem was not expanded on first boot. Many thanks to @naddel91 and others for reporting this issue: https://dietpi.com/forum/t/increase-partition-size/19015 From 51ed58c95e5c65d61847e5ecd4ab911905adf3e0 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 18 Feb 2024 21:43:22 +0100 Subject: [PATCH 020/266] v9.1 - CI | Squeezelite: Fix archive name --- .build/software/squeezelite/build.bash | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.build/software/squeezelite/build.bash b/.build/software/squeezelite/build.bash index d345f3ec48..bb4e40835e 100755 --- a/.build/software/squeezelite/build.bash +++ b/.build/software/squeezelite/build.bash @@ -26,8 +26,8 @@ G_EXEC cd /tmp # Freeze commit: https://github.com/ralph-irving/squeezelite/issues/206 G_EXEC curl -sSfLO 'https://github.com/ralph-irving/squeezelite/archive/6de9e229aa4cc7c3131ff855f3ead39581127090.tar.gz' [[ -d 'squeezelite-master' ]] && G_EXEC rm -R squeezelite-master -G_EXEC tar xf master.tar.gz -G_EXEC rm master.tar.gz +G_EXEC tar xf 6de9e229aa4cc7c3131ff855f3ead39581127090.tar.gz +G_EXEC rm 6de9e229aa4cc7c3131ff855f3ead39581127090.tar.gz G_DIETPI-NOTIFY 2 'Compiling binary...' G_EXEC mv squeezelite-{6de9e229aa4cc7c3131ff855f3ead39581127090,master} G_EXEC cd squeezelite-master From 0356f33988e9aa6cd3e03d8e85e3d15119336c3b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 19 Feb 2024 01:42:09 +0100 Subject: [PATCH 021/266] v9.1 (#6902) - NanoPi R5S/R5C and 6 series | Move to Armbian kernel and bootloader builds --- .build/images/dietpi-build | 36 ++----- .build/images/dietpi-installer | 102 ++++++++++-------- .github/workflows/dietpi-build.yml | 7 +- CHANGELOG.txt | 1 + dietpi/func/dietpi-set_hardware | 2 +- .../lib/dietpi/services/dietpi-firstboot.bash | 20 ---- 6 files changed, 72 insertions(+), 96 deletions(-) mode change 100755 => 100644 .build/images/dietpi-installer diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index beb1d9eb04..d8dfbebef2 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -127,10 +127,13 @@ case $HW_MODEL in 73) iname='ROCKPiS' HW_ARCH=3 partition_start=16 root_size=880;; 74) iname='RadxaZero' HW_ARCH=3 partition_start=4 root_size=892;; 75) iname='Container' HW_ARCH=${HW_ARCH:-10} root_size=447;; - 76) iname='NanoPiR5S' HW_ARCH=3 root_size=752;; # Special case: Skips image file, partitioning and filesystem generation, but runs debootstrap only! + '76.1') iname='NanoPiR5S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + '76.2') iname='NanoPiR5C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; 77) iname='ROCK3A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; 78) iname='ROCK5B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; - 79) iname='NanoPi6' HW_ARCH=3 root_size=752;; # Special case: Skips image file, partitioning and filesystem generation, but runs debootstrap only! + '79.1') iname='NanoPiR6S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; + '79.2') iname='NanoPiR6C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; + '79.3') iname='NanoPCT6' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; 80) iname='OrangePi5' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; 81) iname='VisionFive2' HW_ARCH=11 root_size=639;; 82) iname='OrangePi5Plus' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; @@ -259,21 +262,6 @@ G_EXIT_CUSTOM(){ [[ -f $OUTPUT_IMG_NAME.img ]] && G_EXEC rm "$OUTPUT_IMG_NAME.img" } -# NanoPi 5/6: Base image download -if [[ $HW_MODEL == 7[69] ]] -then - case $HW_MODEL in - 76) series=5;; - 79) series=6;; - *) :;; - esac - G_EXEC curl -sSfO "https://dietpi.com/downloads/nanopi$series.img.xz" - G_EXEC xz -d "nanopi$series.img.xz" - G_EXEC truncate -s "$(( 140 + $root_size ))M" "nanopi$series.img" - G_EXEC_OUTPUT=1 G_EXEC sgdisk -e "nanopi$series.img" - G_EXEC_OUTPUT=1 G_EXEC eval "sfdisk -fN8 'nanopi$series.img' <<< ',+'" - G_EXEC mv "nanopi$series.img" "$OUTPUT_IMG_NAME.img" -else # Create image file G_EXEC fallocate -l "$((partition_start+efi_size+boot_size+root_size))M" "$OUTPUT_IMG_NAME.img" @@ -311,7 +299,6 @@ else # Set boot flag G_EXEC parted -s "$OUTPUT_IMG_NAME.img" set 1 boot on fi -fi # Create loop device FP_LOOP=$(losetup -f) @@ -339,19 +326,8 @@ cluster_size() # Create and mount filesystems and fstab G_EXEC mkdir rootfs -# - NanoPi 5/6 with base image -if [[ $HW_MODEL == 7[69] ]] -then - FP_ROOT_DEV=8 - G_EXEC_OUTPUT=1 G_EXEC "${afsck[@]}" "${FP_LOOP}p8" - G_EXEC_OUTPUT=1 G_EXEC "${aresize[@]}" "${FP_LOOP}p8" - G_EXEC mount "${FP_LOOP}p8" rootfs - G_EXEC mkdir rootfs/etc - cat << _EOF_ > rootfs/etc/fstab -PARTUUID=$(lsblk -no PARTUUID "${FP_LOOP}p8") / $FSTYPE noatime,lazytime 0 1 -_EOF_ # + EFI partition -elif (( $efi_size )) +if (( $efi_size )) then FP_ROOT_DEV=2 G_EXEC mkfs.fat -F 32 -S 512 -s "$(cluster_size "$efi_size")" "${FP_LOOP}p1" diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer old mode 100755 new mode 100644 index 1f63059bb6..90eacb6426 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -405,8 +405,11 @@ _EOF_ '54' ': NanoPi K2' '55' ': NanoPi R2S' '47' ': NanoPi R4S' - '76' ': NanoPi R5S/R5C' - '79' ': NanoPi 6 series' + '76.1' ': NanoPi R5S' + '76.2' ': NanoPi R5C' + '79.1' ': NanoPi R6S' + '79.2' ': NanoPi R6C' + '79.3' ': NanoPC T6' '72.1' ': ROCK 4 (all other variants)' '72.2' ': ROCK 4 SE' '73' ': ROCK Pi S' @@ -615,7 +618,7 @@ _EOF_ G_EXEC mv "DietPi-$G_GITBRANCH/.build/images/U-Boot/99-dietpi-uboot" /etc/initramfs/post-update.d/99-dietpi-uboot G_EXEC sed --follow-symlinks -i 's/arm64/arm/' /etc/initramfs/post-update.d/99-dietpi-uboot - elif [[ $G_HW_MODEL =~ ^(12|15|16|40|42|43|44|45|46|47|48|52|54|55|56|57|58|59|60|62|63|64|65|66|67|68|72|73|74|77|78|80|82|83|85|86|87)$ ]] + elif [[ $G_HW_MODEL =~ ^(12|15|16|40|42|43|44|45|46|47|48|52|54|55|56|57|58|59|60|62|63|64|65|66|67|68|72|73|74|76|77|78|79|80|82|83|85|86|87)$ ]] then armbian_repo=1 G_EXEC mv "DietPi-$G_GITBRANCH/.build/images/U-Boot/boot.cmd" /boot/boot.cmd @@ -656,14 +659,14 @@ setenv rootuuid "true"' /boot/boot.cmd (( $G_HW_MODEL == 15 )) && G_EXEC eval 'echo '\''meson_rng'\'' > /etc/modules-load.d/dietpi-hwrng.conf' # Rockchip 64-bit (configs work with Amlogic OOTB) - elif [[ $G_HW_MODEL =~ ^(42|43|46|47|55|56|58|68|72|73|77|78|80|82|85|86|87)$ ]] + elif [[ $G_HW_MODEL =~ ^(42|43|46|47|55|56|58|68|72|73|76|77|78|79|80|82|85|86|87)$ ]] then G_EXEC sed --follow-symlinks -Ei '/^setenv (kernel|fdt)_addr_r/d' /boot/boot.cmd G_CONFIG_INJECT 'setenv scriptaddr ' 'setenv scriptaddr "0x9000000"' /boot/boot.cmd G_CONFIG_INJECT 'overlay_path=' 'overlay_path=rockchip' /boot/dietpiEnv.txt case $G_HW_MODEL in 73) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=rk3308' /boot/dietpiEnv.txt;; - 78|80|82|85) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=rk3588' /boot/dietpiEnv.txt;; # ToDo: There are multiple other prefixes used in the kernel package, "rock-5b", "rock-5ab", "rockchip" (for fixup), so the boot.cmd need heavy adjustments (eliminate the prefix entirely) to work with all overlays. + 78|79|80|82|85) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=rk3588' /boot/dietpiEnv.txt;; # ToDo: There are multiple other prefixes used in the kernel package, "rock-5b", "rock-5ab", "rockchip" (for fixup), so the boot.cmd need heavy adjustments (eliminate the prefix entirely) to work with all overlays. *) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=rockchip' /boot/dietpiEnv.txt;; esac case $G_HW_MODEL in @@ -674,6 +677,7 @@ setenv rootuuid "true"' /boot/boot.cmd 73) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3308-rock-pi-s.dtb' /boot/dietpiEnv.txt;; # U-Boot does not pass any ${fdtfile} 77) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3568-rock-3a.dtb' /boot/dietpiEnv.txt;; 78) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3588-rock-5b.dtb' /boot/dietpiEnv.txt;; + 79) (( $HW_VARIANT == 2 )) && G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3588s-nanopi-r6c.dtb' /boot/dietpiEnv.txt;; 85) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3588s-rock-5a.dtb' /boot/dietpiEnv.txt;; 87) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3566-orangepi-3b.dtb' /boot/dietpiEnv.txt;; *) :;; @@ -681,7 +685,7 @@ setenv rootuuid "true"' /boot/boot.cmd case $G_HW_MODEL in 73) G_CONFIG_INJECT 'consoleargs=' 'consoleargs=console=ttyS0,1500000' /boot/dietpiEnv.txt;; # headless 47|55|56) G_CONFIG_INJECT 'consoleargs=' 'consoleargs=console=ttyS2,1500000' /boot/dietpiEnv.txt;; # headless - 78|80|82) G_EXEC sed --follow-symlinks -i 's/ttyAML0,115200/ttyFIQ0,1500000/' /boot/dietpiEnv.txt;; + 78|79|80|82|85) G_EXEC sed --follow-symlinks -i 's/ttyAML0,115200/ttyFIQ0,1500000/' /boot/dietpiEnv.txt;; # RK3588 *) G_EXEC sed --follow-symlinks -i 's/ttyAML0,115200/ttyS2,1500000/' /boot/dietpiEnv.txt;; esac @@ -1089,14 +1093,24 @@ _EOF_ esac;; 73) model='rockpi-s' kernel='rockchip64';; 74) model='radxa-zero';; + 76) kernel='rockchip64' + case $HW_VARIANT in + 2) model='nanopi-r5c';; + *) model='nanopi-r5s';; + esac;; 77) model='rock-3a' kernel='rockchip64';; 78) model='rock-5b' kernel='rk35xx' branch='legacy';; + 79) kernel='rk35xx' branch='legacy' + case $HW_VARIANT in + 3) model='nanopct6';; + *) model='nanopi-r6s';; + esac;; 80) model='orangepi5' kernel='rk35xx' branch='legacy';; 82) model='orangepi5-plus' kernel='rk35xx' branch='legacy';; 83) model='orangepizero3' kernel='sunxi64';; 85) model='rock-5a' kernel='rk35xx' branch='legacy';; 86) model='tinkerboard-2' kernel='rockchip64';; - 87) model='orangepi3b' kernel='rockchip64'; branch='edge';; + 87) model='orangepi3b' kernel='rockchip64' branch='edge';; *) :;; esac # Download and pre-install U-Boot hosted on dietpi.com where it has not been ported to the Armbian Bookworm repo or has been removed completely @@ -1140,14 +1154,15 @@ _EOF_ G_AGI initramfs-tools u-boot-tools armbian-firmware "${zstd[@]}" [[ ${zstd[0]} ]] && G_CONFIG_INJECT 'COMPRESS=' 'COMPRESS=zstd' /etc/initramfs-tools/initramfs.conf # Download and pre-install kernel hosted on dietpi.com where the Armbian APT repo provides a too old version - if (( ( $G_HW_MODEL == 72 && ${HW_VARIANT:-1} == 2 ) || $G_HW_MODEL == 83 )) + if [[ ( $G_HW_MODEL == 72 && $HW_VARIANT == 2 ) || $G_HW_MODEL =~ ^(76|83)$ ]] then G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb "https://dietpi.com/downloads/binaries/linux-image-$branch-$kernel.deb" G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb "https://dietpi.com/downloads/binaries/linux-dtb-$branch-$kernel.deb" + G_EXEC_OUTPUT=1 G_EXEC curl -fo package3.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' local uboot=() - (( $HW_VARIANT == 1 )) && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package3.deb "https://dietpi.com/downloads/binaries/linux-u-boot-$model-$branch.deb"; uboot=('package3.deb'); } - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package1.deb package2.deb "${uboot[@]}" - G_EXEC rm package1.deb package2.deb "${uboot[@]}" + [[ $G_HW_MODEL == 76 || ( $G_HW_MODEL == 83 && $HW_VARIANT == 1 ) ]] && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package4.deb "https://dietpi.com/downloads/binaries/linux-u-boot-$model-$branch.deb"; uboot=('package4.deb'); } + G_EXEC_OUTPUT=1 G_EXEC dpkg -i package1.deb package2.deb package3.deb "${uboot[@]}" + G_EXEC rm package1.deb package2.deb package3.deb "${uboot[@]}" fi # Orange Pi Zero 3 1.5G RAM variant: Install original Orange Pi bootloader if (( $G_HW_MODEL == 83 )) && (( $HW_VARIANT == 2 )) @@ -1286,22 +1301,6 @@ _EOF_ G_EXEC rm package.deb aPACKAGES_REQUIRED_INSTALL+=("firmware-$variant") - # NanoPi R5S/R5C - elif (( $G_HW_MODEL == 76 )) && { [[ ! $(find /lib/modules -mindepth 1 -maxdepth 1 -type d) ]] || dpkg-query -s 'firmware-nanopi5' &> /dev/null; } - then - G_EXEC curl -sSfo package.deb 'https://dietpi.com/downloads/binaries/firmware-nanopi5.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb - G_EXEC rm package.deb - aPACKAGES_REQUIRED_INSTALL+=('firmware-nanopi5') - - # NanoPi 6 - elif (( $G_HW_MODEL == 79 )) && { [[ ! $(find /lib/modules -mindepth 1 -maxdepth 1 -type d) ]] || dpkg-query -s 'firmware-nanopi6' &> /dev/null; } - then - G_EXEC curl -sSfo package.deb 'https://dietpi.com/downloads/binaries/firmware-nanopi6.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb - G_EXEC rm package.deb - aPACKAGES_REQUIRED_INSTALL+=('firmware-nanopi6') - # NanoPi M2/T2/Fire2 Linux 4.4: Requires dedicated boot partition, starting at 4 MiB for U-Boot, with ext4 filesystem elif [[ $G_HW_MODEL == 61 && $(findmnt -Ufnro FSTYPE -M /boot) == 'ext4' ]] && (( $(sfdisk -qlo Start "$BOOT_DEVICE" | mawk 'NR==2') >= 8192 )) then @@ -1730,7 +1729,6 @@ _EOF_ # - FriendlyELEC [[ -f 'usr/bin/lcd2usb_print' ]] && G_EXEC rm /usr/bin/lcd2usb_print - (( $G_HW_MODEL == 76 )) && G_EXEC rm -Rf /data /sdcard /udisk /oem /userdata /system /vendor /mnt/{sdcard,external_sd,usb_storage,udisk} /etc/systemd/system/{boot-complete.target.requires,ctrl-alt-del.target,wpa_supplicant-nl80211@.service,wpa_supplicant-wired@.service,wpa_supplicant@.service} [[ -f '/usr/local/bin/cputemp.sh' ]] && G_EXEC rm /usr/local/bin/cputemp.sh [[ -f '/usr/local/bin/drm-hotplug.sh' ]] && G_EXEC rm /usr/local/bin/drm-hotplug.sh [[ -f '/usr/local/bin/setup-net-smp.sh' ]] && G_EXEC rm /usr/local/bin/setup-net-smp.sh @@ -1973,8 +1971,8 @@ _EOF_' /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttySAC0 /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyGS0 - # ROCKPro64, ROCK64, Pinebook Pro, NanoPi R4S, Quartz64, ASUS Tinker Board, NanoPi R2S, NanoPi NEO3, NanoPi M4V2, NanoPi M4/T4/NEO4, ROCK 4, ROCK 3A, ASUS Tinker Board 2 - elif [[ $G_HW_MODEL =~ ^(42|43|46|47|49|52|55|56|58|68|72|77|86|87)$ ]] + # ROCKPro64, ROCK64, Pinebook Pro, NanoPi R4S, Quartz64, ASUS Tinker Board, NanoPi R2S, NanoPi NEO3, NanoPi M4V2, NanoPi M4/T4/NEO4, ROCK 4, NanoPi R5S/R5C, ROCK 3A, ASUS Tinker Board 2, Orange Pi 3B + elif [[ $G_HW_MODEL =~ ^(42|43|46|47|49|52|55|56|58|68|72|76|77|86|87)$ ]] then /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyS2 @@ -1988,8 +1986,8 @@ _EOF_' then /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyS1 - # NanoPi R5S/R5C, ROCK 5B, NanoPi 6, Orange Pi 5, Orange Pi 5 Plus, ROCK 5A - elif [[ $G_HW_MODEL =~ ^(76|78|79|80|82|85)$ ]] + # RK3588: ROCK 5B, NanoPi 6, Orange Pi 5, Orange Pi 5 Plus, ROCK 5A + elif [[ $G_HW_MODEL =~ ^(78|79|80|82|85)$ ]] then /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyFIQ0 @@ -2160,25 +2158,43 @@ _EOF_ SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0", RUN+="/bin/ip l s down dev eth0" SUBSYSTEM=="leds", KERNEL=="lan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1", RUN+="/bin/ip l s down dev eth1" _EOF_ - # NanoPi R5S/R5C: In case, will be updated for R5C on first boot - elif (( $G_HW_MODEL == 76 )) + # NanoPi R5S + elif [[ $G_HW_MODEL == 76 && $HW_VARIANT == 1 ]] then - G_DIETPI-NOTIFY 2 'Enabling NanoPi R5S/R5C Ethernet LEDs' + G_DIETPI-NOTIFY 2 'Enabling NanoPi R5S Ethernet LEDs' G_EXEC eval 'echo '\''ledtrig-netdev'\'' > /etc/modules-load.d/dietpi-eth-leds.conf' cat << '_EOF_' > /etc/udev/rules.d/dietpi-eth-leds.rules -SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0", RUN+="/bin/ip l s down dev eth0" -SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1", RUN+="/bin/ip l s down dev eth1" -SUBSYSTEM=="leds", KERNEL=="lan2_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth2", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth2", RUN+="/bin/ip l s down dev eth2" +SUBSYSTEM=="leds", KERNEL=="green:lan-1", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0", RUN+="/bin/ip l s down dev eth0" +SUBSYSTEM=="leds", KERNEL=="green:lan-2", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1", RUN+="/bin/ip l s down dev eth1" +SUBSYSTEM=="leds", KERNEL=="green:wan", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth2", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth2", RUN+="/bin/ip l s down dev eth2" _EOF_ - # NanoPi 6: These match for R6S and in case will be updated for R6C or NanoPC T6 on first boot, based on /proc/device-tree/model. - elif (( $G_HW_MODEL == 79 )) + # NanoPi R5C + elif [[ $G_HW_MODEL == 76 && $HW_VARIANT == 2 ]] then - G_DIETPI-NOTIFY 2 'Enabling NanoPi R6 Ethernet LEDs' + G_DIETPI-NOTIFY 2 'Enabling NanoPi R5C Ethernet LEDs' + G_EXEC eval 'echo '\''ledtrig-netdev'\'' > /etc/modules-load.d/dietpi-eth-leds.conf' + cat << '_EOF_' > /etc/udev/rules.d/dietpi-eth-leds.rules +SUBSYSTEM=="leds", KERNEL=="green:lan", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0", RUN+="/bin/ip l s down dev eth0" +SUBSYSTEM=="leds", KERNEL=="green:wan", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1", RUN+="/bin/ip l s down dev eth1" +_EOF_ + # NanoPi R6S + elif [[ $G_HW_MODEL == 79 && $HW_VARIANT == 1 ]] + then + G_DIETPI-NOTIFY 2 'Enabling NanoPi R6S Ethernet LEDs' G_EXEC eval 'echo '\''ledtrig-netdev'\'' > /etc/modules-load.d/dietpi-eth-leds.conf' cat << '_EOF_' > /etc/udev/rules.d/dietpi-eth-leds.rules SUBSYSTEM=="leds", KERNEL=="lan2_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0", RUN+="/bin/ip l s down dev eth0" -SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1" -SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth2", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1" +SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1" +SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth2", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1" +_EOF_ + # NanoPi R6C + elif [[ $G_HW_MODEL == 79 && $HW_VARIANT == 2 ]] + then + G_DIETPI-NOTIFY 2 'Enabling NanoPi R6C Ethernet LEDs' + G_EXEC eval 'echo '\''ledtrig-netdev'\'' > /etc/modules-load.d/dietpi-eth-leds.conf' + cat << '_EOF_' > /etc/udev/rules.d/dietpi-eth-leds.rules +SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0; /bin/ip l s down dev eth0" +SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1; /bin/ip l s down dev eth1" _EOF_ # Orange Pi 3B/Zero 3: Module does not load automatically, but we want it loaded on first boot in case firstrun setup is done via WiFi elif [[ $G_HW_MODEL =~ ^(83|87)$ ]] diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index ae9014e487..0e22d4fc7b 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -71,10 +71,13 @@ jobs: '"-m 75 -a 1 -d 6", "-m 75 -a 2 -d 6", "-m 75 -a 3 -d 6", "-m 75 -a 10 -d 6", '\ '"-m 75 -a 1 -d 7", "-m 75 -a 2 -d 7", "-m 75 -a 3 -d 7", "-m 75 -a 10 -d 7", '\ '"-m 75 -a 1 -d 8", "-m 75 -a 2 -d 8", "-m 75 -a 3 -d 8", "-m 75 -a 10 -d 8", "-m 75 -a 11 -d 8", '\ - '"-m 76 -d 6", "-m 76 -d 7", "-m 76 -d 8", '\ + '"-m 76.1 -d 6", "-m 76.1 -d 7", "-m 76.1 -d 8", '\ + '"-m 76.2 -d 6", "-m 76.2 -d 7", "-m 76.2 -d 8", '\ '"-m 77 -d 6", "-m 77 -d 7", "-m 77 -d 8", '\ '"-m 78 -d 6", "-m 78 -d 7", "-m 78 -d 8", '\ - '"-m 79 -d 6", "-m 79 -d 7", "-m 79 -d 8", '\ + '"-m 79.1 -d 6", "-m 79.1 -d 7", "-m 79.1 -d 8", '\ + '"-m 79.2 -d 6", "-m 79.2 -d 7", "-m 79.2 -d 8", '\ + '"-m 79.3 -d 6", "-m 79.3 -d 7", "-m 79.3 -d 8", '\ '"-m 80 -d 6", "-m 80 -d 7", "-m 80 -d 8", '\ '"-m 81 -d 8", '\ '"-m 82 -d 6", "-m 82 -d 7", "-m 82 -d 8", '\ diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 4ac0d98653..27dc23df62 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -4,6 +4,7 @@ v9.1 New images: - Raspberry Pi 5 | Images for Raspberry Pi 5 and other Raspberry Pi models, based on the new Bookworm kernel and firmware package set from Raspberry Pi Ltd, are now available for testing. Note that some features, like changing screen resolution and camera module support, are not working yet: https://dietpi.com/downloads/binaries/testing/ - ROCK 4 SE | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4 SE variant, we provide a new image for this particular variant. Many thanks to @janno for reporting failing boot on this SBC: https://dietpi.com/forum/t/radxa-rock-4-se-supported-not-booting/19263 +- NanoPi R5S/R5C/R6S/R6C/T6 | Our new images for these SBCs use kernel and bootloader builds generated with the Armbian build system. This means that they have a single ext4 partition with kernel image, overlays and boot configuration located below /boot as usual. The kernel command-line arguments can hence be adjusted, kernel headers installed for compiling modules, and the kernel features are more streamlined with other SBCs. The R5S/R5C images ship with a much newer mainline Linux build, which means more modern kernel features and better code quality. But some edge case hardware features which have not been upstreamed may not work, like support for Rockchip's Media Process Platform (MPP) module, used for hardware-accelerated video encoding/decoding by some media servers/players. We are also testing the migration from our old images to the new kernel and bootloader packages, and will likely offer this with next DietPi update. Enhancements: - DietPi-Backup/Sync | Both scripts do now only error out when the "rsync" process is already running, rather than on any process which has the term "rsync" in its name. Many thanks to @zuble for implementing this enhancement: https://github.com/MichaIng/DietPi/pull/6918 diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 033c42851e..597bf3b683 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -1520,7 +1520,7 @@ Do you want to continue and disable the serial login console?' || return 1 elif (( $DIETPIENV || $G_HW_MODEL == 49 || $G_HW_MODEL == 76 || $G_HW_MODEL == 79 )) then local baudrate='115200' - if [[ $G_HW_MODEL =~ ^(42|43|46|47|49|55|56|58|68|72|77|87)$ && $INPUT_ADDITIONAL == 'ttyS2' ]] || [[ $G_HW_MODEL == 73 && $INPUT_ADDITIONAL == 'ttyS'[012] ]] || [[ $G_HW_MODEL =~ ^(76|78|79|80|82|85)$ && $INPUT_ADDITIONAL == 'ttyFIQ0' ]] + if [[ $G_HW_MODEL =~ ^(42|43|46|47|49|55|56|58|68|72|76|77|87)$ && $INPUT_ADDITIONAL == 'ttyS2' ]] || [[ $G_HW_MODEL == 73 && $INPUT_ADDITIONAL == 'ttyS'[012] ]] || [[ $G_HW_MODEL =~ ^(76|78|79|80|82|85)$ && $INPUT_ADDITIONAL == 'ttyFIQ0' ]] then baudrate='1500000' [[ -d /etc/systemd/system/serial-getty@$INPUT_ADDITIONAL.service.d ]] || G_EXEC mkdir "/etc/systemd/system/serial-getty@$INPUT_ADDITIONAL.service.d" diff --git a/rootfs/var/lib/dietpi/services/dietpi-firstboot.bash b/rootfs/var/lib/dietpi/services/dietpi-firstboot.bash index 1318f83024..154914524b 100755 --- a/rootfs/var/lib/dietpi/services/dietpi-firstboot.bash +++ b/rootfs/var/lib/dietpi/services/dietpi-firstboot.bash @@ -104,26 +104,6 @@ then RPi_Set_Clock_Speeds - # NanoPi R5S/R5C/R6S/R6C/T6: Update udev rules for variants - elif [[ $G_HW_MODEL == 7[69] && -f '/proc/device-tree/model' ]] - then - local variant - read -r variant < /proc/device-tree/model - case $variant in - *'R5C'*) cat << '_EOF_' > /etc/udev/rules.d/dietpi-eth-leds.rules -SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0; /bin/ip l s down dev eth0" -SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1; /bin/ip l s down dev eth1" -_EOF_ - ;; - *'R6C'*) cat << '_EOF_' > /etc/udev/rules.d/dietpi-eth-leds.rules -SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0; /bin/ip l s down dev eth0" -SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1; /bin/ip l s down dev eth1" -_EOF_ - ;; - *'T6'*) [[ -f '/etc/udev/rules.d/dietpi-eth-leds.rules' ]] && rm /etc/udev/rules.d/dietpi-eth-leds.rules;; - *) :;; - esac - # VisionFive 2 elif [[ $G_HW_MODEL == 81 && -f '/proc/device-tree/serial-number' && -f '/boot/extlinux/extlinux.conf' ]] && ! grep -q '^[[:blank:]]*fdtoverlays[[:blank:]]' /boot/extlinux/extlinux.conf then From 83e0df581161469ac8237c8983832101abcadd9e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 19 Feb 2024 01:45:16 +0100 Subject: [PATCH 022/266] v9.1 - CHANGELOG | Add release PR URL --- CHANGELOG.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 27dc23df62..f4f23b7d4f 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -23,7 +23,7 @@ Bug fixes: - DietPi-Software | OctoPrint: Resolved an issue where system restart and shutdown form the OctoPrint UI failed due to an invalid sudoers rule. Many thanks to @samjw-nz for reporting this issue: https://github.com/MichaIng/DietPi/issues/6915 - DietPi-Software | Squeezelite: Resolved an issue where in rare cases the service could have started before the network adapter was initialised, in which case it reports a MAC address of 00:00:00:00:00:00 to LMS servers. With multiple Squeezelite players, this could have lead to conflicts among them. Many thanks to @willefg for reporting this issue: https://dietpi.com/forum/t/dietpi-squeezelite-players-with-same-mac-address-000000-00/19312 -As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME +As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/6921 ----------------------------------------------------------------------------------------------------------- From 913e53faa99a1a9119ab26509043dcd0ab65471e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 19 Feb 2024 21:33:40 +0100 Subject: [PATCH 023/266] v9.1 - DietPi-Software | RealVNC: Resolved an issue where the installation was throwing an error, as it was attempted to write to a config file shipped by TigerVNC only. --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index f4f23b7d4f..45d278fb6c 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -22,6 +22,7 @@ Bug fixes: - DietPi-Software | Pydio: Resolved an issue where web access via Apache webserver did not work, due to an invalid config entry. However, Pydio 8 is not maintained since years, does not support PHP 8 and hence can only work on Bullseye systems. We will migrate to Pydio Cells, once someone finds time to work on this: https://github.com/MichaIng/DietPi/issues/3469 - DietPi-Software | OctoPrint: Resolved an issue where system restart and shutdown form the OctoPrint UI failed due to an invalid sudoers rule. Many thanks to @samjw-nz for reporting this issue: https://github.com/MichaIng/DietPi/issues/6915 - DietPi-Software | Squeezelite: Resolved an issue where in rare cases the service could have started before the network adapter was initialised, in which case it reports a MAC address of 00:00:00:00:00:00 to LMS servers. With multiple Squeezelite players, this could have lead to conflicts among them. Many thanks to @willefg for reporting this issue: https://dietpi.com/forum/t/dietpi-squeezelite-players-with-same-mac-address-000000-00/19312 +- DietPi-Software | RealVNC: Resolved an issue where the installation was throwing an error, as it was attempted to write to a config file shipped by TigerVNC only. As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/6921 diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 96117615ee..b59c63f05f 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -7184,7 +7184,7 @@ _EOF_ # TigerVNC: Permit remote connections which implies TLSVnc authentications being enabled additionally # shellcheck disable=SC2016 - GCI_PRESERVE=1 G_CONFIG_INJECT '\$localhost[[:blank:]]*=' '$localhost = "no";' /etc/tigervnc/vncserver-config-defaults + (( ${aSOFTWARE_INSTALL_STATE[28]} == 1 )) && GCI_PRESERVE=1 G_CONFIG_INJECT '\$localhost[[:blank:]]*=' '$localhost = "no";' /etc/tigervnc/vncserver-config-defaults # TigerVNC: Set control + read-only passwords if [[ ${aSOFTWARE_INSTALL_STATE[28]} == 1 && ! -f '/root/.vnc/passwd' ]] From 545b1c6d396d2cee8d52434f9a1af2a0a2102b3c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 19 Feb 2024 22:30:27 +0100 Subject: [PATCH 024/266] v9.1 - DietPi-Patches | Move forward several kernel and software updates --- .update/patches | 104 ++++++++++++++++++++--------------------- dietpi/dietpi-software | 2 +- 2 files changed, 53 insertions(+), 53 deletions(-) diff --git a/.update/patches b/.update/patches index 28fb9e81ec..61c6925a4a 100755 --- a/.update/patches +++ b/.update/patches @@ -1477,46 +1477,9 @@ Patch_8_25() Patch_9_0() { - # Quartz64 - if (( $G_HW_MODEL == 49 )) - then - for i in quartz64{a,b} soquartz - do - dpkg --compare-versions "$(dpkg-query -Wf '${Version}' "firmware-$i" 2> /dev/null)" lt-nl 6.6.12-dietpi1 || continue - G_DIETPI-NOTIFY 2 "Updating $i kernel and bootloader ..." - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/firmware-$i.deb" - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb - break - done - - # VisionFive 2 - elif (( $G_HW_MODEL == 81 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-visionfive2 2> /dev/null)" lt-nl 6.1.73-dietpi1 - then - G_DIETPI-NOTIFY 2 'Updating RISC-V StarFive VisionFive 2 kernel ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-visionfive2.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb - - # Star64 - elif (( $G_HW_MODEL == 84 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-star64 2> /dev/null)" lt-nl 6.1.73-dietpi1 - then - G_DIETPI-NOTIFY 2 'Updating RISC-V PINE64 Star64 kernel ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-star64.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb - fi - # Software updates and migrations if [[ -f '/boot/dietpi/.installed' ]] then - # Amiberry - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[108\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' amiberry 2> /dev/null)" lt 5.6.5-dietpi1 - then - G_DIETPI-NOTIFY 2 'Preparing Amiberry upgrade to v5.6.5, including migration for RPi systems from fake KMS DispmanX to full KMS SDL2 graphics backend' - echo 108 >> /var/tmp/dietpi/dietpi-update_reinstalls - fi - # Nextcloud # - Apache if [[ -f '/etc/apache2/sites-available/dietpi-nextcloud.conf' ]] @@ -1535,21 +1498,6 @@ Patch_9_0() # Kodi [[ -f '/usr/share/applications/kodi.desktop' ]] && G_CONFIG_INJECT 'Exec=' 'Exec=kodi --standalone' /usr/share/applications/kodi.desktop - - # vaultwarden - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[183\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' vaultwarden 2> /dev/null)" lt 1.30.1-dietpi3 - then - # Pre-v8.7 cleanup - if [[ -f '/opt/vaultwarden/target/release/vaultwarden' ]] - then - G_EXEC rm -R /opt/vaultwarden - [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service - fi - G_DIETPI-NOTIFY 2 'Updating vaultwarden package ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" - G_AGI ./package.deb - G_EXEC rm package.deb - fi fi } @@ -1562,6 +1510,36 @@ Patch_9_1() G_EXEC rm /etc/kernel/postinst.d/dietpi-USBridgeSig fi + # Quartz64 + if (( $G_HW_MODEL == 49 )) + then + for i in quartz64{a,b} soquartz + do + dpkg --compare-versions "$(dpkg-query -Wf '${Version}' "firmware-$i" 2> /dev/null)" lt-nl 6.7.4-dietpi1 || continue + G_DIETPI-NOTIFY 2 "Updating $i kernel and bootloader ..." + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/firmware-$i.deb" + G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb + G_EXEC rm package.deb + break + done + + # VisionFive 2 + elif (( $G_HW_MODEL == 81 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-visionfive2 2> /dev/null)" lt-nl 6.1.78-dietpi1 + then + G_DIETPI-NOTIFY 2 'Updating RISC-V StarFive VisionFive 2 kernel ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-visionfive2.deb' + G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb + G_EXEC rm package.deb + + # Star64 + elif (( $G_HW_MODEL == 84 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-star64 2> /dev/null)" lt-nl 6.1.78-dietpi1 + then + G_DIETPI-NOTIFY 2 'Updating RISC-V PINE64 Star64 kernel ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-star64.deb' + G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb + G_EXEC rm package.deb + fi + # Software updates and migrations if [[ -f '/boot/dietpi/.installed' ]] then @@ -1603,6 +1581,28 @@ map $arg_v $asset_immutable { G_AGI ./package.deb G_EXEC rm package.deb fi + + # Amiberry + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[108\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' amiberry 2> /dev/null)" lt 5.6.6-dietpi1 + then + G_DIETPI-NOTIFY 2 'Preparing Amiberry upgrade to v5.6.6, including migration for RPi systems from fake KMS DispmanX to full KMS SDL2 graphics backend' + echo 108 >> /var/tmp/dietpi/dietpi-update_reinstalls + fi + + # vaultwarden + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[183\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' vaultwarden 2> /dev/null)" lt 1.30.3-dietpi2 + then + # Pre-v8.7 cleanup + if [[ -f '/opt/vaultwarden/target/release/vaultwarden' ]] + then + G_EXEC rm -R /opt/vaultwarden + [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service + fi + G_DIETPI-NOTIFY 2 'Updating vaultwarden package ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" + G_AGI ./package.deb + G_EXEC rm package.deb + fi fi } diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index b59c63f05f..29332d9748 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11092,7 +11092,7 @@ _EOF_ # v3 drops PHP 7.4 support: https://github.com/TasmoAdmin/TasmoAdmin/releases/tag/v3.0.0 if (( $G_DISTRO > 6 )) then - local fallback_url='https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v4.0.0/tasmoadmin_v4.0.0.tar.gz' + local fallback_url='https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v4.0.1/tasmoadmin_v4.0.1.tar.gz' Download_Install "$(curl -sSfL 'https://api.github.com/repos/TasmoAdmin/TasmoAdmin/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/tasmoadmin_v[^"\/]*\.tar\.gz"$/{print $4}')" else Download_Install 'https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v2.4.2/tasmoadmin_v2.4.2.tar.gz' From b9325acd105c60bbda7ce4c9931cdd65434bff00 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 19 Feb 2024 22:31:56 +0100 Subject: [PATCH 025/266] v9.1 - META | Add (re-)add execute bit to scripts which are intended to be executed --- .build/images/dietpi-installer | 0 .meta/dietpi-rpi-firmware-migration | 0 2 files changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 .build/images/dietpi-installer mode change 100644 => 100755 .meta/dietpi-rpi-firmware-migration diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer old mode 100644 new mode 100755 diff --git a/.meta/dietpi-rpi-firmware-migration b/.meta/dietpi-rpi-firmware-migration old mode 100644 new mode 100755 From 83fb9888e75751e7265eacee226a81ce97bdd83f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 19 Feb 2024 23:39:18 +0100 Subject: [PATCH 026/266] v9.1 - DietPi-Installer | Fix for changed gcc-base version on Trixie --- .build/images/dietpi-installer | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 90eacb6426..ff3929df36 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1545,7 +1545,7 @@ _EOF_ 5) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-8-/{print $1}');; 6) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-10-/{print $1}');; 7) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-12-/{print $1}');; - 8) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-13-/{print $1}');; + 8) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-14-/{print $1}');; *) :;; esac [[ ${apackages[0]} ]] && G_AGP "${apackages[@]}" From 7a01c8d0ab29d956ef0007fd81868781f3cc0b91 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 18:03:09 +0100 Subject: [PATCH 027/266] v9.2 - DietPi-Build | Raise size of ROCK 4 and Orange Pi Zero 3 rootfs, required for armbian-firmware installation - DietPi-Installer | Work around Raspbian Trixie being out of sync, shipping gcc-14 souce packages, but not gcc-14-base: https://bugs.launchpad.net/raspbian/+bug/2052306 --- .build/images/dietpi-build | 8 ++++---- .build/images/dietpi-installer | 5 +---- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index d8dfbebef2..349502467c 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -122,8 +122,8 @@ case $HW_MODEL in '68.2') iname='NanoPCT4' HW_ARCH=3 partition_start=16 root_size=880;; '68.3') iname='NanoPiNEO4' HW_ARCH=3 partition_start=16 root_size=880;; 70) iname='SparkySBC' HW_ARCH=2 partition_start=8 boot_size=48 root_size=712 boot_fstype='fat16';; - '72.1') iname='ROCKPi4' HW_ARCH=3 partition_start=16 root_size=880;; - '72.2') iname='ROCK4SE' HW_ARCH=3 partition_start=16 root_size=880;; + '72.1') iname='ROCKPi4' HW_ARCH=3 partition_start=16 root_size=1008;; + '72.2') iname='ROCK4SE' HW_ARCH=3 partition_start=16 root_size=1008;; 73) iname='ROCKPiS' HW_ARCH=3 partition_start=16 root_size=880;; 74) iname='RadxaZero' HW_ARCH=3 partition_start=4 root_size=892;; 75) iname='Container' HW_ARCH=${HW_ARCH:-10} root_size=447;; @@ -137,8 +137,8 @@ case $HW_MODEL in 80) iname='OrangePi5' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; 81) iname='VisionFive2' HW_ARCH=11 root_size=639;; 82) iname='OrangePi5Plus' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; - '83.1') iname='OrangePiZero3' HW_ARCH=3 partition_start=4 root_size=892;; - '83.2') iname='OrangePiZero3-1.5G' HW_ARCH=3 partition_start=4 root_size=892;; + '83.1') iname='OrangePiZero3' HW_ARCH=3 partition_start=4 root_size=1020;; + '83.2') iname='OrangePiZero3-1.5G' HW_ARCH=3 partition_start=4 root_size=1020;; 84) iname='Star64' HW_ARCH=11 root_size=639;; 85) iname='ROCK5A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; 86) iname='ASUSTB2' HW_ARCH=3 partition_start=16 root_size=880;; diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index ff3929df36..0eec949355 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -788,9 +788,6 @@ setenv rootuuid "true"' /boot/boot.cmd G_CONFIG_INJECT 'DEV_GITOWNER=' "DEV_GITOWNER=$G_GITOWNER" /boot/dietpi.txt G_VERSIONDB_SAVE - # Temporary fix for resizing on Bullseye until v9.1 has been released: https://github.com/MichaIng/DietPi/issues/6900 - (( $G_DISTRO < 7 )) && G_EXEC sed -i 's/MOUNTPOINTS/MOUNTPOINT/' /var/lib/dietpi/services/fs_partition_resize.sh - # Apply live patches G_DIETPI-NOTIFY 2 'Applying DietPi live patches to fix known bugs in this version' for i in "${!G_LIVE_PATCH[@]}" @@ -1545,7 +1542,7 @@ _EOF_ 5) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-8-/{print $1}');; 6) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-10-/{print $1}');; 7) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-12-/{print $1}');; - 8) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-14-/{print $1}');; + 8) dpkg-query -s 'gcc-14-base' &> /dev/null && mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-14-/{print $1}') || mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-13-/{print $1}');; # Temporary workaround for Raspbian Trixie not shipping gcc-14-base yet *) :;; esac [[ ${apackages[0]} ]] && G_AGP "${apackages[@]}" From c9af7ae578f315d86ab6c286190b88c012d9158a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 18:12:26 +0100 Subject: [PATCH 028/266] v9.2 - META | Satisfy shellcheck --- .build/images/dietpi-installer | 1 + 1 file changed, 1 insertion(+) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 0eec949355..88b7cfdad3 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1542,6 +1542,7 @@ _EOF_ 5) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-8-/{print $1}');; 6) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-10-/{print $1}');; 7) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-12-/{print $1}');; + # shellcheck disable=SC2015 8) dpkg-query -s 'gcc-14-base' &> /dev/null && mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-14-/{print $1}') || mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-13-/{print $1}');; # Temporary workaround for Raspbian Trixie not shipping gcc-14-base yet *) :;; esac From 76a5607b822ed734919738241317014b05d2a4c1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 18:22:04 +0100 Subject: [PATCH 029/266] v9.2 - META | Fix shellcheck annotation --- .build/images/dietpi-installer | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 88b7cfdad3..f61c460084 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1538,11 +1538,11 @@ _EOF_ dpkg-query -s usrmerge &> /dev/null && G_AGP usrmerge # Remove old gcc-*-base packages, e.g. accumulated on Raspberry Pi OS images + # shellcheck disable=SC2015 case $G_DISTRO in 5) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-8-/{print $1}');; 6) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-10-/{print $1}');; 7) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-12-/{print $1}');; - # shellcheck disable=SC2015 8) dpkg-query -s 'gcc-14-base' &> /dev/null && mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-14-/{print $1}') || mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-13-/{print $1}');; # Temporary workaround for Raspbian Trixie not shipping gcc-14-base yet *) :;; esac From facb80e35f8e542ce110704d0f5a16ec2fe3cf48 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 19:53:55 +0100 Subject: [PATCH 030/266] v9.1 - Init v9.2 - CHANGELOG | Fix v9.1 release date - DietPi-Software | PaperMC: Resolved an issue where installing the Geyser and Floodgate plugins failed due to changed download URLs, and a false syntax in the Geyser config file. Many thanks to @boterocamilo for reporting this issue: https://github.com/MichaIng/DietPi/issues/6898 --- .meta/dietpi-survey_report | 4 +++- .update/patches | 21 +++++++++++++++++++++ .update/version | 4 ++-- CHANGELOG.txt | 14 +++++++++++++- dietpi/dietpi-software | 10 +++++----- dietpi/func/dietpi-globals | 4 ++-- 6 files changed, 46 insertions(+), 11 deletions(-) diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index 4467f6be2d..4e5e3b3ccc 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -703,6 +703,7 @@ shopt -s extglob aSOFTWARE_NAME8_25=() aSOFTWARE_NAME9_0=() aSOFTWARE_NAME9_1=() + aSOFTWARE_NAME9_2=() for i in "${!aSOFTWARE_NAME8_22[@]}" do aSOFTWARE_NAME8_23[i]=${aSOFTWARE_NAME8_22[i]} @@ -710,10 +711,11 @@ shopt -s extglob aSOFTWARE_NAME8_25[i]=${aSOFTWARE_NAME8_24[i]} aSOFTWARE_NAME9_0[i]=${aSOFTWARE_NAME8_25[i]} aSOFTWARE_NAME9_1[i]=${aSOFTWARE_NAME9_0[i]} + aSOFTWARE_NAME9_2[i]=${aSOFTWARE_NAME9_1[i]} done # Pre-create software counter array so that we can see also software (available in newest version) with 0 installs - for i in "${aSOFTWARE_NAME9_1[@]}" + for i in "${aSOFTWARE_NAME9_2[@]}" do aSOFTWARE[$i]=0 done diff --git a/.update/patches b/.update/patches index 61c6925a4a..d4716dba6a 100755 --- a/.update/patches +++ b/.update/patches @@ -1606,6 +1606,27 @@ map $arg_v $asset_immutable { fi } +Patch_9_2() +{ + # Software updates and migrations + if [[ -f '/boot/dietpi/.installed' ]] + then + # PaperMC + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed + then + if [[ -f '/mnt/dietpi_userdata/papermc/plugins/floodgate-bukkit.jar' ]] + then + G_DIETPI-NOTIFY 2 'Renaming Floodgate plugin file to correct Spigot edition name ...' + G_EXEC mv /mnt/dietpi_userdata/papermc/plugins/floodgate-{bukkit,spigot}.jar + fi + if [[ -f '/mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml' ]] && grep -q '^auth-type: floodgate' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml + then + G_DIETPI-NOTIFY 2 'Fixing Geyser plugin config ...' + G_EXEC sed -i 's/^auth-type: floodgate/ auth-type: floodgate/' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml + fi + fi +} + # v6.35 => v7 migration if (( $G_DIETPI_VERSION_CORE == 6 && $G_DIETPI_VERSION_SUB > 34 )) then diff --git a/.update/version b/.update/version index ee25551504..83d5135338 100644 --- a/.update/version +++ b/.update/version @@ -2,8 +2,8 @@ # shellcheck disable=SC2034 # Available DietPi version G_REMOTE_VERSION_CORE=9 -G_REMOTE_VERSION_SUB=1 -G_REMOTE_VERSION_RC=1 +G_REMOTE_VERSION_SUB=2 +G_REMOTE_VERSION_RC=-1 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 45d278fb6c..a9985a4c0a 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,5 +1,17 @@ +v9.2 +(2024-03-16) + +Enhancements: + +Bug fixes: +- DietPi-Software | PaperMC: Resolved an issue where installing the Geyser and Floodgate plugins failed due to changed download URLs, and a false syntax in the Geyser config file. Many thanks to @boterocamilo for reporting this issue: https://github.com/MichaIng/DietPi/issues/6898 + +As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME + +----------------------------------------------------------------------------------------------------------- + v9.1 -(2024-02-17) +(2024-02-19) New images: - Raspberry Pi 5 | Images for Raspberry Pi 5 and other Raspberry Pi models, based on the new Bookworm kernel and firmware package set from Raspberry Pi Ltd, are now available for testing. Note that some features, like changing screen resolution and camera module support, are not working yet: https://dietpi.com/downloads/binaries/testing/ diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 29332d9748..40fbe22b97 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11333,8 +11333,8 @@ _EOF_ G_WHIP_BUTTON_CANCEL_TEXT='Skip' if G_WHIP_YESNO 'Would you like to install the Geyser and Floodgate plugins for compatibility with Bedrock Edition?\n\nNote that this may be buggy.' then - Download_Install 'https://ci.opencollab.dev/job/GeyserMC/job/Geyser/job/master/lastStableBuild/artifact/bootstrap/spigot/build/libs/Geyser-Spigot.jar' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot.jar - Download_Install 'https://ci.opencollab.dev/job/GeyserMC/job/Floodgate/job/master/lastStableBuild/artifact/spigot/build/libs/floodgate-spigot.jar' /mnt/dietpi_userdata/papermc/plugins/floodgate-bukkit.jar + Download_Install 'https://download.geysermc.org/v2/projects/geyser/versions/latest/builds/latest/downloads/spigot' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot.jar + Download_Install 'https://download.geysermc.org/v2/projects/floodgate/versions/latest/builds/latest/downloads/spigot' /mnt/dietpi_userdata/papermc/plugins/floodgate-spigot.jar fi # Minecraft rcon client for remote administration and server maintenance scripts @@ -11383,10 +11383,10 @@ ExecStart=/usr/bin/java -Xmx${heap_size}m -jar /opt/papermc/paperclip.jar --nogu WantedBy=multi-user.target _EOF_ # Config - if [[ -f '/mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot.jar' && -f '/mnt/dietpi_userdata/papermc/plugins/floodgate-bukkit.jar' ]] + if [[ -f '/mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot.jar' ]] then Create_Config /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml papermc 1800 1 && - G_CONFIG_INJECT 'auth-type:[[:blank:]]' 'auth-type: floodgate' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml + G_CONFIG_INJECT 'auth-type:[[:blank:]]' ' auth-type: floodgate' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml else Create_Config /mnt/dietpi_userdata/papermc/permissions.yml papermc 1800 1 fi @@ -11395,7 +11395,7 @@ _EOF_ else aSOFTWARE_INSTALL_STATE[$software_id]=0 - G_DIETPI-NOTIFY 2 "${aSOFTWARE_NAME[$software_id]} install aborted due to outstanding EULA agreement" + G_DIETPI-NOTIFY 2 "${aSOFTWARE_NAME[$software_id]} install skipped due to outstanding EULA agreement" fi fi diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 76cce7eaeb..8c510115c9 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -54,8 +54,8 @@ [[ -f '/boot/dietpi/.version' ]] && . /boot/dietpi/.version # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 - [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=1 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=1 + [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=2 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=-1 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From 07283f90884452178f4cdb6fc77caf5ba884b8d4 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 19:59:14 +0100 Subject: [PATCH 031/266] v9.2 - DietPi-Patches | Syntax --- .update/patches | 1 + 1 file changed, 1 insertion(+) diff --git a/.update/patches b/.update/patches index d4716dba6a..d64acfca1b 100755 --- a/.update/patches +++ b/.update/patches @@ -1625,6 +1625,7 @@ Patch_9_2() G_EXEC sed -i 's/^auth-type: floodgate/ auth-type: floodgate/' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml fi fi + fi } # v6.35 => v7 migration From df2e83f035c09441135fc5a925c2eaca80ed8fe1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 21:24:14 +0100 Subject: [PATCH 032/266] v9.2 - DietPi-Software | In all Java application services, treat exit code 143 as success, which is returned whenever SIGTERM was sent, which is the default stop method of systemd and gracefully handled by all applications --- dietpi/dietpi-software | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 40fbe22b97..37c6d03aad 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6147,6 +6147,7 @@ SyslogIdentifier=Airsonic User=airsonic WorkingDirectory=/mnt/dietpi_userdata/airsonic ExecStart=/usr/bin/java -Xmx${memory_limit}m -Dairsonic.home=/mnt/dietpi_userdata/airsonic -Dserver.servlet.context-path=/airsonic -Dserver.port=8080 -jar /mnt/dietpi_userdata/airsonic/airsonic.war +SuccessExitStatus=143 [Install] WantedBy=multi-user.target @@ -6769,6 +6770,7 @@ User=blynk LogsDirectory=blynk WorkingDirectory=/mnt/dietpi_userdata/blynk ExecStart=/usr/bin/java$log4shell -jar /mnt/dietpi_userdata/blynk/blynkserver.jar +SuccessExitStatus=143 # Hardening PrivateTmp=true @@ -7371,6 +7373,7 @@ User=ubooquity LogsDirectory=ubooquity WorkingDirectory=/mnt/dietpi_userdata/ubooquity ExecStart=/usr/bin/java -Xmx${memory_limit}m -jar /mnt/dietpi_userdata/ubooquity/Ubooquity.jar --headless --remoteadmin --adminport 2038 --libraryport 2039 +SuccessExitStatus=143 [Install] WantedBy=multi-user.target @@ -7432,6 +7435,7 @@ SyslogIdentifier=Komga User=komga WorkingDirectory=/mnt/dietpi_userdata/komga ExecStart=/usr/bin/java -Xmx${memory_limit}m -jar komga.jar +SuccessExitStatus=143 [Install] WantedBy=multi-user.target @@ -10537,6 +10541,7 @@ After=network-online.target SyslogIdentifier=Nukkit WorkingDirectory=/usr/local/bin/nukkit ExecStart=/usr/bin/java -jar /usr/local/bin/nukkit/nukkit.jar +SuccessExitStatus=143 [Install] WantedBy=multi-user.target @@ -11378,6 +11383,7 @@ User=papermc LogsDirectory=papermc WorkingDirectory=/mnt/dietpi_userdata/papermc ExecStart=/usr/bin/java -Xmx${heap_size}m -jar /opt/papermc/paperclip.jar --nogui --noconsole +SuccessExitStatus=143 [Install] WantedBy=multi-user.target From 149a79741135786b129c2292fd89f38504ae06b2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 21:53:39 +0100 Subject: [PATCH 033/266] v9.2 - NanoPi R4S | Resolved an issue where Ethernet adapter of the "LAN" port could disappear after a soft reboot. Many thanks to @idaanx for reporting this issue: https://github.com/MichaIng/DietPi/issues/6342 --- .build/images/dietpi-installer | 3 ++- .update/patches | 13 +++++++++++++ CHANGELOG.txt | 1 + 3 files changed, 16 insertions(+), 1 deletion(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index f61c460084..8d3750268d 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1151,7 +1151,8 @@ _EOF_ G_AGI initramfs-tools u-boot-tools armbian-firmware "${zstd[@]}" [[ ${zstd[0]} ]] && G_CONFIG_INJECT 'COMPRESS=' 'COMPRESS=zstd' /etc/initramfs-tools/initramfs.conf # Download and pre-install kernel hosted on dietpi.com where the Armbian APT repo provides a too old version - if [[ ( $G_HW_MODEL == 72 && $HW_VARIANT == 2 ) || $G_HW_MODEL =~ ^(76|83)$ ]] + # - NanoPi R4S: Solve Ethernet adapter disappearing on soft reboot: https://github.com/MichaIng/DietPi/issues/6342 + if [[ ( $G_HW_MODEL == 72 && $HW_VARIANT == 2 ) || $G_HW_MODEL =~ ^(47|76|83)$ ]] then G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb "https://dietpi.com/downloads/binaries/linux-image-$branch-$kernel.deb" G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb "https://dietpi.com/downloads/binaries/linux-dtb-$branch-$kernel.deb" diff --git a/.update/patches b/.update/patches index d64acfca1b..fb7da2df09 100755 --- a/.update/patches +++ b/.update/patches @@ -1608,6 +1608,19 @@ map $arg_v $asset_immutable { Patch_9_2() { + # NanoPi R4S: Solve Ethernet adapter disappearing on soft reboot: https://github.com/MichaIng/DietPi/issues/6342 + if (( $G_HW_MODEL == 47 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-current-rockchip64 2> /dev/null)" lt-nl 24.2.0 + then + G_DIETPI-NOTIFY 2 'Updating NanoPi R4S kernel ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb 'https://dietpi.com/downloads/binaries/linux-current-rockchip64.dtb' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb 'https://dietpi.com/downloads/binaries/linux-dtb-rockchip64.deb' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package3.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' + local headers=() + dpkg-query -s 'linux-headers-current-rockchip64' &> /dev/null && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package4.deb 'https://dietpi.com/downloads/binaries/linux-headers-rockchip64.deb'; headers=('package4.deb'); } + G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package1.deb package2.deb package3.deb "${headers[@]}" + G_EXEC rm package1.deb package2.deb package3.deb "${headers[@]}" + fi + # Software updates and migrations if [[ -f '/boot/dietpi/.installed' ]] then diff --git a/CHANGELOG.txt b/CHANGELOG.txt index a9985a4c0a..4431052217 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,6 +2,7 @@ v9.2 (2024-03-16) Enhancements: +- NanoPi R4S | Resolved an issue where Ethernet adapter of the "LAN" port could disappear after a soft reboot. Many thanks to @idaanx for reporting this issue: https://github.com/MichaIng/DietPi/issues/6342 Bug fixes: - DietPi-Software | PaperMC: Resolved an issue where installing the Geyser and Floodgate plugins failed due to changed download URLs, and a false syntax in the Geyser config file. Many thanks to @boterocamilo for reporting this issue: https://github.com/MichaIng/DietPi/issues/6898 From 79344e71d013fc8f1b179ffd35475c2cdabd4c43 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 22:03:11 +0100 Subject: [PATCH 034/266] v9.2 - DietPi-Patches | Fix URLs --- .update/patches | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.update/patches b/.update/patches index fb7da2df09..075d6fe48a 100755 --- a/.update/patches +++ b/.update/patches @@ -1612,11 +1612,11 @@ Patch_9_2() if (( $G_HW_MODEL == 47 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-current-rockchip64 2> /dev/null)" lt-nl 24.2.0 then G_DIETPI-NOTIFY 2 'Updating NanoPi R4S kernel ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb 'https://dietpi.com/downloads/binaries/linux-current-rockchip64.dtb' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb 'https://dietpi.com/downloads/binaries/linux-dtb-rockchip64.deb' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb 'https://dietpi.com/downloads/binaries/linux-image-current-rockchip64.dtb' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb 'https://dietpi.com/downloads/binaries/linux-dtb-current-rockchip64.deb' G_EXEC_OUTPUT=1 G_EXEC curl -fo package3.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' local headers=() - dpkg-query -s 'linux-headers-current-rockchip64' &> /dev/null && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package4.deb 'https://dietpi.com/downloads/binaries/linux-headers-rockchip64.deb'; headers=('package4.deb'); } + dpkg-query -s 'linux-headers-current-rockchip64' &> /dev/null && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package4.deb 'https://dietpi.com/downloads/binaries/linux-headers-current-rockchip64.deb'; headers=('package4.deb'); } G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package1.deb package2.deb package3.deb "${headers[@]}" G_EXEC rm package1.deb package2.deb package3.deb "${headers[@]}" fi From 9d7152ab309f1282fc78e00e09f6350ed7f789a2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 22:04:01 +0100 Subject: [PATCH 035/266] v9.2 - DietPi-Patches | Another URL fix --- .update/patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index 075d6fe48a..f3a73ac645 100755 --- a/.update/patches +++ b/.update/patches @@ -1612,7 +1612,7 @@ Patch_9_2() if (( $G_HW_MODEL == 47 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-current-rockchip64 2> /dev/null)" lt-nl 24.2.0 then G_DIETPI-NOTIFY 2 'Updating NanoPi R4S kernel ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb 'https://dietpi.com/downloads/binaries/linux-image-current-rockchip64.dtb' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb 'https://dietpi.com/downloads/binaries/linux-image-current-rockchip64.deb' G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb 'https://dietpi.com/downloads/binaries/linux-dtb-current-rockchip64.deb' G_EXEC_OUTPUT=1 G_EXEC curl -fo package3.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' local headers=() From 4f0b012d445a869e3ca9122f456b899ec76aa528 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 22:14:22 +0100 Subject: [PATCH 036/266] v9.2 - DietPi-Installer | Since Bookworm, Dropbear ships with a systemd service and the NO_START env var is hence obsolete. The stop we do is a noop if the setting is not present, hence we do not need to patch anything, but this conditional serves as well as marker for removal, once we remove Bullseye support from DietPi-Installer. --- .build/images/dietpi-installer | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 8d3750268d..8f8e080c82 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -2225,7 +2225,7 @@ _EOF_ then G_CONFIG_INJECT 'CONFIG_NTP_MODE=' 'CONFIG_NTP_MODE=0' /boot/dietpi.txt else - G_EXEC_DESC='Enable Dropbear autostart' G_EXEC sed --follow-symlinks -i '/NO_START=1/c\NO_START=0' /etc/default/dropbear + (( $G_DISTRO < 7 )) && G_EXEC_DESC='Enable Dropbear autostart' G_EXEC sed --follow-symlinks -i '/NO_START=1/c\NO_START=0' /etc/default/dropbear G_EXEC systemctl unmask dropbear G_EXEC systemctl enable dropbear fi From 2a04ad094382487761c571c3a803b842a849b68f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 20 Feb 2024 23:03:41 +0100 Subject: [PATCH 037/266] v9.2 - DietPi-Build | Raise rootfs size of Orange Pi Zero 3, required on Bookworm images, and merge all the Bookworm-only image size increments into base sizes. It doesn't really make a difference whether images for Bullseye are larger at first, as DietPi-Imager minimises their size afterwards anyway. --- .build/images/dietpi-build | 82 +++++++++++++++++--------------------- 1 file changed, 37 insertions(+), 45 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 349502467c..4a23d65df9 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -85,31 +85,31 @@ case $HW_MODEL in 5) iname='RPi5' HW_ARCH=3 boot_size=128 root_size=895;; 10) iname='OdroidC1' HW_ARCH=2 partition_start=4 boot_size=128 root_size=700 boot_fstype='fat16';; 11) iname='OdroidXU4' HW_ARCH=2 partition_start=4 root_size=764;; - 12) iname='OdroidC2' HW_ARCH=3 partition_start=4 root_size=892;; - 15) iname='OdroidN2' HW_ARCH=3 partition_start=4 root_size=892;; - 16) iname='OdroidC4' HW_ARCH=3 partition_start=4 root_size=892;; + 12) iname='OdroidC2' HW_ARCH=3 partition_start=4 root_size=1020;; + 15) iname='OdroidN2' HW_ARCH=3 partition_start=4 root_size=1020;; + 16) iname='OdroidC4' HW_ARCH=3 partition_start=4 root_size=1020;; 20) iname='VM' HW_ARCH=${HW_ARCH:-10} VMTYPE=${VMTYPE:-raw};; - 21) iname='NativePC-BIOS' HW_ARCH=10 root_size=1215;; + 21) iname='NativePC-BIOS' HW_ARCH=10 root_size=1663;; 40) iname='PINEA64' HW_ARCH=3 partition_start=4 root_size=892;; - 42) iname='ROCKPro64' HW_ARCH=3 partition_start=16 root_size=880;; - 43) iname='ROCK64' HW_ARCH=3 partition_start=16 root_size=880;; + 42) iname='ROCKPro64' HW_ARCH=3 partition_start=16 root_size=1008;; + 43) iname='ROCK64' HW_ARCH=3 partition_start=16 root_size=1008;; 44) iname='Pinebook' HW_ARCH=3 partition_start=4 root_size=892;; 45) iname='PINEH64' HW_ARCH=3 partition_start=4 root_size=892;; - 46) iname='PinebookPro' HW_ARCH=3 partition_start=16 root_size=880;; - 47) iname='NanoPiR4S' HW_ARCH=3 partition_start=16 root_size=880;; + 46) iname='PinebookPro' HW_ARCH=3 partition_start=16 root_size=1008;; + 47) iname='NanoPiR4S' HW_ARCH=3 partition_start=16 root_size=1008;; 48) iname='NanoPiR1' HW_ARCH=2 partition_start=4 root_size=764;; '49.1') iname='Quartz64A' HW_ARCH=3 partition_start=16 root_size=752;; '49.2') iname='Quartz64B' HW_ARCH=3 partition_start=16 root_size=752;; '49.3') iname='SOQuartz' HW_ARCH=3 partition_start=16 root_size=752;; 52) iname='ASUSTB' HW_ARCH=2 partition_start=4 root_size=764;; - 54) iname='NanoPiK2' HW_ARCH=3 partition_start=4 root_size=892;; - 55) iname='NanoPiR2S' HW_ARCH=3 partition_start=16 root_size=880;; - 56) iname='NanoPiNEO3' HW_ARCH=3 partition_start=16 root_size=880;; + 54) iname='NanoPiK2' HW_ARCH=3 partition_start=4 root_size=1020;; + 55) iname='NanoPiR2S' HW_ARCH=3 partition_start=16 root_size=1008;; + 56) iname='NanoPiNEO3' HW_ARCH=3 partition_start=16 root_size=1008;; 57) iname='NanoPiNEOPlus2' HW_ARCH=3 partition_start=4 root_size=892;; - 58) iname='NanoPiM4V2' HW_ARCH=3 partition_start=16 root_size=880;; + 58) iname='NanoPiM4V2' HW_ARCH=3 partition_start=16 root_size=1008;; 59) iname='ZeroPi' HW_ARCH=2 partition_start=4 root_size=764;; 60) iname='NanoPiNEO' HW_ARCH=2 partition_start=4 root_size=764;; - 61) iname='NanoPiM2' HW_ARCH=2 partition_start=4 boot_size=64 root_size=572 boot_fstype='ext4';; + 61) iname='NanoPiM2' HW_ARCH=2 partition_start=4 boot_size=64 root_size=700 boot_fstype='ext4';; '62.1') iname='NanoPiM3' HW_ARCH=3 partition_start=4 root_size=700;; '62.2') iname='NanoPiFire3' HW_ARCH=3 partition_start=4 root_size=700;; 63) iname='NanoPiM1' HW_ARCH=2 partition_start=4 root_size=764;; @@ -118,31 +118,31 @@ case $HW_MODEL in '65.2') iname='NanoPiNEO2Black' HW_ARCH=3 partition_start=4 root_size=892;; 66) iname='NanoPiM1Plus' HW_ARCH=2 partition_start=4 root_size=764;; 67) iname='NanoPiK1Plus' HW_ARCH=3 partition_start=4 root_size=892;; - '68.1') iname='NanoPiM4' HW_ARCH=3 partition_start=16 root_size=880;; - '68.2') iname='NanoPCT4' HW_ARCH=3 partition_start=16 root_size=880;; - '68.3') iname='NanoPiNEO4' HW_ARCH=3 partition_start=16 root_size=880;; + '68.1') iname='NanoPiM4' HW_ARCH=3 partition_start=16 root_size=1008;; + '68.2') iname='NanoPCT4' HW_ARCH=3 partition_start=16 root_size=1008;; + '68.3') iname='NanoPiNEO4' HW_ARCH=3 partition_start=16 root_size=1008;; 70) iname='SparkySBC' HW_ARCH=2 partition_start=8 boot_size=48 root_size=712 boot_fstype='fat16';; '72.1') iname='ROCKPi4' HW_ARCH=3 partition_start=16 root_size=1008;; '72.2') iname='ROCK4SE' HW_ARCH=3 partition_start=16 root_size=1008;; - 73) iname='ROCKPiS' HW_ARCH=3 partition_start=16 root_size=880;; - 74) iname='RadxaZero' HW_ARCH=3 partition_start=4 root_size=892;; - 75) iname='Container' HW_ARCH=${HW_ARCH:-10} root_size=447;; - '76.1') iname='NanoPiR5S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; - '76.2') iname='NanoPiR5C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; - 77) iname='ROCK3A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; - 78) iname='ROCK5B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; - '79.1') iname='NanoPiR6S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; - '79.2') iname='NanoPiR6C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; - '79.3') iname='NanoPCT6' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; - 80) iname='OrangePi5' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; + 73) iname='ROCKPiS' HW_ARCH=3 partition_start=16 root_size=1008;; + 74) iname='RadxaZero' HW_ARCH=3 partition_start=4 root_size=1020;; + 75) iname='Container' HW_ARCH=${HW_ARCH:-10} root_size=575;; + '76.1') iname='NanoPiR5S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; + '76.2') iname='NanoPiR5C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; + 77) iname='ROCK3A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + 78) iname='ROCK5B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + '79.1') iname='NanoPiR6S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + '79.2') iname='NanoPiR6C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + '79.3') iname='NanoPCT6' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + 80) iname='OrangePi5' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; 81) iname='VisionFive2' HW_ARCH=11 root_size=639;; - 82) iname='OrangePi5Plus' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; - '83.1') iname='OrangePiZero3' HW_ARCH=3 partition_start=4 root_size=1020;; - '83.2') iname='OrangePiZero3-1.5G' HW_ARCH=3 partition_start=4 root_size=1020;; + 82) iname='OrangePi5Plus' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + '83.1') iname='OrangePiZero3' HW_ARCH=3 partition_start=4 root_size=1148;; + '83.2') iname='OrangePiZero3-1.5G' HW_ARCH=3 partition_start=4 root_size=1148;; 84) iname='Star64' HW_ARCH=11 root_size=639;; - 85) iname='ROCK5A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; - 86) iname='ASUSTB2' HW_ARCH=3 partition_start=16 root_size=880;; - 87) iname='OrangePi3B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=880;; + 85) iname='ROCK5A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + 86) iname='ASUSTB2' HW_ARCH=3 partition_start=16 root_size=1008;; + 87) iname='OrangePi3B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; *) G_DIETPI-NOTIFY 1 "Invalid hardware model \"$HW_MODEL\" passed, aborting..."; exit 1;; esac @@ -168,20 +168,12 @@ esac exclude= case $DISTRO in - 6) distro='bullseye' exclude=',gcc-8-base,gcc-9-base';; - 7|8) - exclude=',gcc-8-base,gcc-9-base,gcc-10-base,gcc-11-base' - [[ $DISTRO == 7 ]] && distro='bookworm' || distro='trixie' exclude+=',gcc-12-base,gcc-13-base' - [[ $HW_ARCH == 11 ]] && distro='sid' # RISC-V architecture is available on Sid only - # Raise root size where required - case $HW_MODEL in - 1[256]|54|61|7[4569]) ((root_size+=128));; - 21) ((root_size+=448));; - *) [[ $partition_start == 16 ]] && ((root_size+=128));; # 64-bit Rockchip SoCs - esac - ;; + 6) distro='bullseye' exclude=',gcc-9-base';; + 7) distro='bookworm' exclude=',gcc-11-base';; + 8) distro='trixie' exclude+=',gcc-11-base,gcc-12-base,gcc-13-base';; *) G_DIETPI-NOTIFY 1 "Invalid distro \"$DISTRO\" passed, aborting..."; exit 1;; esac +[[ $HW_ARCH == 11 ]] && distro='sid' # RISC-V architecture is available on Sid only case $PTTYPE in 'msdos') :;; From bd9b374406dec9024c76e0b0c680d9d4077732c2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 21 Feb 2024 20:09:57 +0100 Subject: [PATCH 038/266] v9.2 - DietPi-Software | Nextcloud: Resolved an issue with the updated Nginx config, where assets were served with the wrong MIME type. This fix was backported to v9.1 and a live patch offered. Many thanks to @howardroark for reporting this issue: https://dietpi.com/forum/t/nextcloud-theme-broken-after-upgrade-v9-1-1/19372 --- .conf/dps_114/nginx.nextcloud.conf | 1 + .update/patches | 8 ++++++++ CHANGELOG.txt | 1 + 3 files changed, 10 insertions(+) diff --git a/.conf/dps_114/nginx.nextcloud.conf b/.conf/dps_114/nginx.nextcloud.conf index 8e38802989..2545b3aa24 100644 --- a/.conf/dps_114/nginx.nextcloud.conf +++ b/.conf/dps_114/nginx.nextcloud.conf @@ -77,6 +77,7 @@ location ^~ /nextcloud { fastcgi_max_temp_file_size 0; # Allow downloads > 1 GiB: https://github.com/nextcloud/documentation/pull/7979 } + include mime.types; types { text/javascript js mjs; application/wasm wasm; diff --git a/.update/patches b/.update/patches index f3a73ac645..a407efb1e6 100755 --- a/.update/patches +++ b/.update/patches @@ -1624,6 +1624,14 @@ Patch_9_2() # Software updates and migrations if [[ -f '/boot/dietpi/.installed' ]] then + # Nextcloud + # - Nginx + if [[ -f '/etc/nginx/sites-dietpi/dietpi-nextcloud.conf' ]] && ! grep -q 'include mime.types;' /etc/nginx/sites-dietpi/dietpi-nextcloud.conf + then + G_DIETPI-NOTIFY 2 'Fixing Nextclound Nginx config ...' + G_EXEC sed -i '/types {/i\\tinclude mime.types;' /etc/nginx/sites-dietpi/dietpi-nextcloud.conf + fi + # PaperMC if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed then diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 4431052217..8dddcac563 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,6 +6,7 @@ Enhancements: Bug fixes: - DietPi-Software | PaperMC: Resolved an issue where installing the Geyser and Floodgate plugins failed due to changed download URLs, and a false syntax in the Geyser config file. Many thanks to @boterocamilo for reporting this issue: https://github.com/MichaIng/DietPi/issues/6898 +- DietPi-Software | Nextcloud: Resolved an issue with the updated Nginx config, where assets were served with the wrong MIME type. This fix was backported to v9.1 and a live patch offered. Many thanks to @howardroark for reporting this issue: https://dietpi.com/forum/t/nextcloud-theme-broken-after-upgrade-v9-1-1/19372 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME From 81b1509bd7f1afc4dd2dded20cdab3cd6f341910 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 21 Feb 2024 20:10:45 +0100 Subject: [PATCH 039/266] v9.1 - DietPi-Software | Nextcloud: Backport fix for Nginx config, serving wrong MIME types: https://dietpi.com/forum/t/nextcloud-theme-broken-after-upgrade-v9-1-1/19372 --- .conf/dps_114/nginx.nextcloud.conf | 1 + 1 file changed, 1 insertion(+) diff --git a/.conf/dps_114/nginx.nextcloud.conf b/.conf/dps_114/nginx.nextcloud.conf index 8e38802989..2545b3aa24 100644 --- a/.conf/dps_114/nginx.nextcloud.conf +++ b/.conf/dps_114/nginx.nextcloud.conf @@ -77,6 +77,7 @@ location ^~ /nextcloud { fastcgi_max_temp_file_size 0; # Allow downloads > 1 GiB: https://github.com/nextcloud/documentation/pull/7979 } + include mime.types; types { text/javascript js mjs; application/wasm wasm; From 02592a3c0a9b33d851a5b71390c9a6571287c355 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 21 Feb 2024 21:12:28 +0100 Subject: [PATCH 040/266] Live patch 0 v9.1 (#6933) - Live patch 0 | Fix Nextcloud Nginx config, serving wrong MIME types --- .conf/dps_114/nginx.nextcloud.conf | 2 +- .update/version | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.conf/dps_114/nginx.nextcloud.conf b/.conf/dps_114/nginx.nextcloud.conf index 2545b3aa24..1f0f734733 100644 --- a/.conf/dps_114/nginx.nextcloud.conf +++ b/.conf/dps_114/nginx.nextcloud.conf @@ -79,7 +79,7 @@ location ^~ /nextcloud { include mime.types; types { - text/javascript js mjs; + text/javascript mjs; application/wasm wasm; } diff --git a/.update/version b/.update/version index ee25551504..2ed96d2b8b 100644 --- a/.update/version +++ b/.update/version @@ -14,6 +14,6 @@ G_MIN_DEBIAN=6 # Alternative Git branch to automatically migrate to when Debian version is too low G_OLD_DEBIAN_BRANCH='8' # Live patches -G_LIVE_PATCH_DESC=() -G_LIVE_PATCH_COND=() -G_LIVE_PATCH=() +G_LIVE_PATCH_DESC=('Fix Nextcloud Nginx config, serving wrong MIME types') +G_LIVE_PATCH_COND=('[[ -f /etc/nginx/sites-dietpi/dietpi-nextcloud.conf ]] && ! grep -q '\''include mime.types;'\'' /etc/nginx/sites-dietpi/dietpi-nextcloud.conf') +G_LIVE_PATCH=('sed -i '\''/types {/i\\tinclude mime.types;'\'' /etc/nginx/sites-dietpi/dietpi-nextcloud.conf; systemctl -q is-active nginx && systemctl restart nginx') From dbe95321b1f45aec020146a2c77b2362abab4697 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 21 Feb 2024 21:13:24 +0100 Subject: [PATCH 041/266] v9.2 - DietPi-Software | Nginx: Resolve visual-only warning about doubled js extension MIME type --- .conf/dps_114/nginx.nextcloud.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.conf/dps_114/nginx.nextcloud.conf b/.conf/dps_114/nginx.nextcloud.conf index 2545b3aa24..1f0f734733 100644 --- a/.conf/dps_114/nginx.nextcloud.conf +++ b/.conf/dps_114/nginx.nextcloud.conf @@ -79,7 +79,7 @@ location ^~ /nextcloud { include mime.types; types { - text/javascript js mjs; + text/javascript mjs; application/wasm wasm; } From 24e6315b7affd0380fa4cc9df07f8f35daa2c9e3 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 21 Feb 2024 22:59:34 +0100 Subject: [PATCH 042/266] v9.2 - NanoPi R5C | Add wlan0 interface trigger for WLAN ("WL" labelled) LED. It has no onbaord WiFi, but an M.2 E key slot which supports WiFi modules. And the LED is obviously intended for this. - NanoPi R6C | Fix LED udev rules to prevent Ethernet LEDs from staying lit from boot on, if the interfaces are not configured afterwards. Also add a WiFi trigger for the "LED1" labelled LED. The R6C has an M.2 M key slot, intended for NVMe SSDs, but there are also adapters to attack M.2 WiFi modules, or a USB module can be used. Making use of this LED for WiFi, if any WiFi adapter is attached, seems a good default. With own udev rules or via dietpi-led_control, the trigger can be easily changed. --- .build/images/dietpi-installer | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 8f8e080c82..8ea242dacd 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -2175,6 +2175,7 @@ _EOF_ cat << '_EOF_' > /etc/udev/rules.d/dietpi-eth-leds.rules SUBSYSTEM=="leds", KERNEL=="green:lan", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0", RUN+="/bin/ip l s down dev eth0" SUBSYSTEM=="leds", KERNEL=="green:wan", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1", RUN+="/bin/ip l s down dev eth1" +SUBSYSTEM=="leds", KERNEL=="green:wlan", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="wlan0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev wlan0", RUN+="/bin/ip l s down dev wlan0" _EOF_ # NanoPi R6S elif [[ $G_HW_MODEL == 79 && $HW_VARIANT == 1 ]] @@ -2192,8 +2193,9 @@ _EOF_ G_DIETPI-NOTIFY 2 'Enabling NanoPi R6C Ethernet LEDs' G_EXEC eval 'echo '\''ledtrig-netdev'\'' > /etc/modules-load.d/dietpi-eth-leds.conf' cat << '_EOF_' > /etc/udev/rules.d/dietpi-eth-leds.rules -SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0; /bin/ip l s down dev eth0" -SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1; /bin/ip l s down dev eth1" +SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0", RUN+="/bin/ip l s down dev eth0" +SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1", RUN+="/bin/ip l s down dev eth1" +SUBSYSTEM=="leds", KERNEL=="user_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="wlan0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev wlan0", RUN+="/bin/ip l s down dev wlan0" _EOF_ # Orange Pi 3B/Zero 3: Module does not load automatically, but we want it loaded on first boot in case firstrun setup is done via WiFi elif [[ $G_HW_MODEL =~ ^(83|87)$ ]] From 9d1398e0ea2b966d8b4532d915eb366e931588af Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 23 Feb 2024 21:13:20 +0100 Subject: [PATCH 043/266] v9.2 - CHANGELOG | Fix link to testing images --- CHANGELOG.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 8dddcac563..835727ce83 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -16,7 +16,7 @@ v9.1 (2024-02-19) New images: -- Raspberry Pi 5 | Images for Raspberry Pi 5 and other Raspberry Pi models, based on the new Bookworm kernel and firmware package set from Raspberry Pi Ltd, are now available for testing. Note that some features, like changing screen resolution and camera module support, are not working yet: https://dietpi.com/downloads/binaries/testing/ +- Raspberry Pi 5 | Images for Raspberry Pi 5 and other Raspberry Pi models, based on the new Bookworm kernel and firmware package set from Raspberry Pi Ltd, are now available for testing. Note that some features, like changing screen resolution and camera module support, are not working yet: https://dietpi.com/downloads/images/testing/ - ROCK 4 SE | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4 SE variant, we provide a new image for this particular variant. Many thanks to @janno for reporting failing boot on this SBC: https://dietpi.com/forum/t/radxa-rock-4-se-supported-not-booting/19263 - NanoPi R5S/R5C/R6S/R6C/T6 | Our new images for these SBCs use kernel and bootloader builds generated with the Armbian build system. This means that they have a single ext4 partition with kernel image, overlays and boot configuration located below /boot as usual. The kernel command-line arguments can hence be adjusted, kernel headers installed for compiling modules, and the kernel features are more streamlined with other SBCs. The R5S/R5C images ship with a much newer mainline Linux build, which means more modern kernel features and better code quality. But some edge case hardware features which have not been upstreamed may not work, like support for Rockchip's Media Process Platform (MPP) module, used for hardware-accelerated video encoding/decoding by some media servers/players. We are also testing the migration from our old images to the new kernel and bootloader packages, and will likely offer this with next DietPi update. From 898fcaa89850cfda6bb5ce281fed56f920035d6f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 23 Feb 2024 22:30:36 +0100 Subject: [PATCH 044/266] v9.2 - DietPi-Patches | Remove obsolete NanoPi R5/R6 patch --- .update/patches | 38 -------------------------------------- 1 file changed, 38 deletions(-) diff --git a/.update/patches b/.update/patches index a407efb1e6..889d67ed2c 100755 --- a/.update/patches +++ b/.update/patches @@ -1238,44 +1238,6 @@ Release notes: https://github.com/hzeller/gmrender-resurrect/releases Patch_8_20() { - # NanoPi R5S/6 kernel upgrade - case $G_HW_MODEL in - 76) local series=5 version='5.10.160-dietpi1';; - 79) local series=6 version='5.10.160-dietpi1';; - *) local series='';; - esac - - if [[ $series ]] && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' "firmware-nanopi$series" 2> /dev/null)" lt-nl "$version" - then - G_DIETPI-NOTIFY 2 "Updating NanoPi $series series kernel ..." - G_EXEC curl -sSfO "https://dietpi.com/downloads/nanopi$series.7z" - G_EXEC 7zr x "nanopi$series.7z" - G_EXEC rm "nanopi$series.7z" - local loopdev=$(losetup -f) rootdev=$(lsblk -npo PKNAME "$G_ROOTFS_DEV") - G_EXEC losetup "$loopdev" "nanopi$series.img" - G_EXEC partprobe "$loopdev" - G_EXEC partx -u "$loopdev" - if [[ ! -b ${loopdev}p8 ]] - then - G_DIETPI-NOTIFY 1 "Image invalid: ${loopdev}p8 does not exist, aborting kernel upgrade ..." - - elif [[ ${rootdev}p8 != "$G_ROOTFS_DEV" ]] - then - G_DIETPI-NOTIFY 1 "Unsupported system: ${rootdev}p8 != $G_ROOTFS_DEV, aborting kernel upgrade ..." - else - G_EXEC curl -sSfO "https://dietpi.com/downloads/binaries/firmware-nanopi$series.deb" - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold "firmware-nanopi$series.deb" - for i in {1..7} - do - G_EXEC dd if="${loopdev}p$i" of="${rootdev}p$i" bs=1M - done - G_EXEC sync - G_EXEC rm "firmware-nanopi$series.deb" - fi - G_EXEC losetup -d "$loopdev" - G_EXEC rm "nanopi$series.img" - fi - # Software updates and migrations if [[ -f '/boot/dietpi/.installed' ]] then From b83ca6986c4774e315819fc6123c7f5415895fe2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 23 Feb 2024 23:06:57 +0100 Subject: [PATCH 045/266] v9.2 - DietPi-Software | Gitea: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 37c6d03aad..f4565033af 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10557,7 +10557,7 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.5/gitea-1.21.5-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.6/gitea-1.21.6-linux-$arch.xz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/go-gitea/gitea/releases/latest' | mawk -F\" "/\"browser_download_url\": \".*\/gitea-[^\"\/]*-linux-$arch\.xz\"/{print \$4}")" /mnt/dietpi_userdata/gitea/gitea # User From e6438733847218763a36776b753716702edb7fc2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 24 Feb 2024 23:09:43 +0100 Subject: [PATCH 046/266] v9.2 - DietPi-Software | LXQt: Add config archive for Trixie and remove the one for Buster. Remove all packages from being explicitly installed, which are dependencies of the "lxqt" package anyway. Keep only xarchiver, as we set it explicitly in our PCManFM config, and the default dependency on Trixie has changed to lxqt-archiver. Do not add SpeedCrunch on Trixie, as it does not exist there at time of writing. Remove nuoveXT2 icon theme, as we do not use it. --- .conf/desktop/lxqt/lxqt-buster.7z | Bin 2717 -> 0 bytes .conf/desktop/lxqt/lxqt-trixie.7z | Bin 0 -> 938 bytes dietpi/dietpi-software | 6 +++++- 3 files changed, 5 insertions(+), 1 deletion(-) delete mode 100644 .conf/desktop/lxqt/lxqt-buster.7z create mode 100644 .conf/desktop/lxqt/lxqt-trixie.7z diff --git a/.conf/desktop/lxqt/lxqt-buster.7z b/.conf/desktop/lxqt/lxqt-buster.7z deleted file mode 100644 index 185acb2b9ead42d6768235a2c49035fcacd5dd8c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2717 zcmV;O3S#v)dc3bE8~_9joBLB*3IG5A0000Z00000000092^E>(9AybVT>veS$qe+c zc_^8Ia+uuNk&cR(4c8CZQ~Lw(KP`_D0Cals{D+%2s`td&XN%Jq^J= zc=!AF|G!Nj#(L+dRmAp_&YKu{! zswUSr?%{*xr}DIX1Pt3k9v|g^+hp~Ud>w*ZH)j*9YazAyQn(sz6M*kkVc-d&?O5=# zAH}&5$-$`b{Gxzo>^#gtROfwRQbD2@?i1JpcN1hnm}7 z9zP&6ozRGWNGc#Nt_hu%Mj5I+yj-Si)DWlN`ZDDI)h;CwlEcx{1HPr_uFr=eU~3e8 zQrTAu)tzx+W=9q08_{=BC!o(x*q~l`0am;S6KuO)zs+hg7PACF2us9I6_@H|ci){{ zs)$R=xeRlPm!o+g*H~y~KhQfB^JVNua z0tkcb{X(*^@@x^8K|Uim>o zeAR@vs>z#iwmC0=sf`tv_x8X1?j{dvMl_D6qf^=V3BFoFf05d3E|FYz1!_DuAb4jr&J zeN9^V*XH$F2NPMOi@56ly|K@bx_V^qb;$3&+Row))9udrDVgN1Lqz#B9!qg_`5z2? zBw;#Kw|!O3fv~7!NElM6te96H@TnV;*TTE^M)o7a!h-TnD9K8TOH3|0d71uQ{9{{B zViXu+KocAJ0Mq;3-(|K6_Z90Hzh+TIen!RZFodLE}`g5*kN@#U{+ z^|n{fl5jZ1boI}xM=a~fN0d6*P!1YxscoRB3z;sFUI(ou+~G1jdiinD9mhY{wfX&B zbbNc+qOt-|U+M?*+C0b26-hHg{zrdWIG5VIb59UgQBGCp5AkkS{B(};m&XJgc+yiV z(=&--8=?TWyO8ZEBb>d{DnDHK*MjGR(Ek(S21rd`Z~TAz#DE!)5y`apUU)i9>UYpG z4NgWy&X)B1+`Bl4PJ?#YV}lV-GiHm3e{g$@0TBL7TRyHe@?Y_1J5UcBbTS1|nPDZ} zypTiB^s9rj)M9UR3`;$fKHZj17n&7Sg{iddb3ZMU92n?pqE%E$k*C^m9#t~#2_euR zq$C$VUv<{gGW}>A<#u42reE6K3xN2<-A`b_Wq1Zi7vLpkA}NAl3^*v=d9^y?oXqG| zh_EGz3v1d5y;o;s1ielX$Q{_m($5Rmx8v()-Ig!I6a8;VFE$D3KGsQq9*5fjykSiF zLZBu$=Zo3fh&JWHDQMtlRHX1X(k)wcuxlBWKTDzqw~r5JL0HiE-ka3Dhgvw~hxQ$* zCM<)FUpY%pGX-U4=sw>?7rQE^_=+KJ?&AVE$*tkr`QD)0>bjqpSnfU>#yBm zPx%$uO1O4m#Nlw127GOoD{z<#R$Gy)MmPw7ga%ZB1RKkyP;k)oAkZ(lj7*dBw@4lM zx7r~6&jHKElfYT}bN6I*QRbX?6gl`j13u|epiL(%j(N2Ygoq0YE{^U{CM9GYe zCitd=qOsT}waqoYP@IUNT>f|52GQ@H!*k8*J|IVL5U6PMRpTh-zQ`6&_(;Y-s{>ck z(==OOiLfBG2dWamgwcxv{;`Qqql@s<896X!5mCsM zFvm!F4z^(>6_Zp4r^VT}! z5c!mTKO359E0lj?MB0cRB9j6BJSkZmBAx{=l<`@-UVZ;>_V+=@V_`=eH# z-1u4*8YpMIjV&$+qE~=nI!gDB!zRo62Xu__k}SH*h$HnFB2@wLMG0p0FTMpjl{yYa zElnn#oO!$1dDV|Eb&2s1q#>#$&TsB(k{ejYEZ(jM`Eh&yAU_`n&{d)+WnfrtdOZ^& zDE%Q=@+&_$Kx(-sU!Z(|?Ect*VSXu5x~tCeLN4@{vGuItAJq+DA`zDOBDSDhf?JoV zq6hVZ7GTTv=<4$qZZ+BF+A>dI=w@LShR~s>1rx8 zqKDoK?)JsNO%HFuPnU$YbI&cw$jf}yxO*~4aUA@(Vc=?WUap3|a-Vnst}Wf`?aWC( z5kOPs`j2P|e*nqM)~+s6M+oYll4+m;**gUvno_AWln8oe1|+@M+8P>=uwZV$ns2DV z-}$O*$rCCcwvp6mK=_c8xPN1;A;RFa_5V zCkH|4OqVm+b;M}bO``9w`age%P=;8RK2_2(W^Ns-oYnMHPqlIppmta9*2D>JZdt34 zYL{e-VO*~OUftv=JxeyxQ;tpBzQPt#(nAf)px~>d@~1@wBjYj?{?&K&|NKg3 z)e#*OB;zOCaeV)_k{GCc!yq#l(sJMQdka<@f%An+UG0YgQ4|3h`s`w68#f|CYDB+i2h+>5656zf@% zjOWR@dFCt}SWdh0;&s=aaT30QK45_;h?5&9a|r$;8oK}h02c;{M*#_e695Mb0RRCb X0|5aAT>uaO01Sd63IW}M#e4t&`fD{? diff --git a/.conf/desktop/lxqt/lxqt-trixie.7z b/.conf/desktop/lxqt/lxqt-trixie.7z new file mode 100644 index 0000000000000000000000000000000000000000..261a47b3b12d2b24371a62f547c155eda2952162 GIT binary patch literal 938 zcmV;b16BMtdc3bE8~_A!7^9nK0{{R30000Z0000000029uC9yV1Xu!qT>veS$qe+c zc_^(c+amxA0lrBqSoF`EZNhg4Gn37M<;KgNMH{wd+ad@-xi2$ z2GH6p=@jcC6c+aCq0o^ptv_JbSV1#oz$e%wLy5B2d@M|cBNXh#-iq-RR5v%Y-p06h z^{EhZz(kd+9=qXTB>&Qw*qcC1SPm$VT^rA$MTQW@dCT*m&`ZH^k(!WVZ_KnHFA^JW zAtutnbU9;yeP4Y5Vx)SVxO-say`f6NersTuuzNM2@lhDCWP+nE>8WfRXH~|X=TboR z+n8dFZbgbnNmIdqrp%a@@E}^fNU`sV5L%a#oJix9Js>m}ljt(7kP*^gI1@@CF2WI& z9vmb(hlL;Q^7mb=Fy9qIWFh~9I;kMl!3Tu%IIbF33l3kFc0~i%YPneM|41Dh#5)Ov zTDa*2WNO_%=6#N}^{_=LD^Orn2$6reIfwJYH~91pIdefXGOT6<;V>VW?(4Iq{*q^8 zo$&rM{X04-z}Hf*z=N#^JmO9b<;fYbieHv)%H$31vJZ_ZPQj(AwC63 z9)Zd!2~VO}>iE)DLvpEhhR8e~u&C8!hAU}-gQSB~G2NVb{S0D&_Ht`F5k)zcPiDIZ83nzgrL!h_82U<%M>!G>`}U~lzBuxk}q zoafQyJ|>=L8b!$+&*(yNlQ=TOm*ePU{JfVW<^^clAPB3eTb?eDb$!V{Y|xfatNQSSebwl8ybS5&zX$zI=T*NmTbH zApyNMl_mH6j&qp}!JcDQ)Z#Rvd|5VOE*P7XG^Gq`OaZDmjhVrc@|9>eSw5Cv9Hp)n zLqs<+6rEq>Q2Ic6sRq%PXhix%Nk=K4>Hrr8f`|bLfZqTI3jqKDBLe{e1zi9T000bu M#tH#dYIPO>04$KGsQ>@~ literal 0 HcmV?d00001 diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index f4565033af..eee7f5215b 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3146,7 +3146,11 @@ _EOF_ if To_Install 173 # LXQt then - G_AGI lxqt qterminal xarchiver lxde-icon-theme upower xscreensaver featherpad speedcrunch + # SpeedCrunch is currently not present on Trixie: https://tracker.debian.org/pkg/speedcrunch + local speedcrunch=('speedcrunch') + (( $G_DISTRO == 8 )) && speedcrunch=() + # lxqt-archiver is the default dependency from Trixie on, but our config uses Archiver=xarchiver. + G_AGI lxqt xarchiver xscreensaver "${speedcrunch[@]}" # Configs Download_Install "https://github.com/$G_GITOWNER/DietPi/raw/$G_GITBRANCH/.conf/desktop/lxqt/lxqt-$G_DISTRO_NAME.7z" /etc/xdg/ From 8449d6d4bdaaf37c29f4bf6c28748cba09c61eb0 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 24 Feb 2024 23:47:38 +0100 Subject: [PATCH 047/266] v9.2 - DietPi-Software | LXQt: Update Trixie configuration --- .conf/desktop/lxqt/lxqt-trixie.7z | Bin 938 -> 973 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/.conf/desktop/lxqt/lxqt-trixie.7z b/.conf/desktop/lxqt/lxqt-trixie.7z index 261a47b3b12d2b24371a62f547c155eda2952162..3d61376afa6f4f24cb44feeeddeddd6ede4a75d2 100644 GIT binary patch delta 845 zcmV-T1G4<82h9g1H+sCUCma9-D3f#DiUR-u00000BLDyZ00000vltqnw-mQEx-3OA(eKP zU!hrm-&=lZ|F%CGo20*OH%QMviP5QI``M}ZPtw1f7>r_v&=Jkf7r&}lb@i-Ge>bU{ z8^qTl=D+T*?{`J-cOcJ#-sjSptgDY>#;wzCCz#q}8VE*~jR+V65I&~04tX4<%!$!fg5n{<{xe=vr z>@|`Ee#on#@6Pm90IZC>s!SNzfA4ksGk#QxdKG_-ItmMTtB-^v@{f$*x{S3JChXuz zRRoB6B3y zze$!T9^?ZV30CrfvX5&4^||XWy|pS@fCVri1^@s6finlL57kC`R#zm`{ravPW!ffSN1S*dJpTeUhJfsC_-#|0PYas2qQbFv! zdD2W_Hyz^8L6(2&M{SjTSPs81QoyEm zlt#turnyt?3Df(j`ZnNmQu7mj>zFE!_!0ya{4~1+0<lq(xd&6glY`Yd8L4z`uZq X02c;=r2z?m<&%#C6$b1(^5*~m!_k!` delta 826 zcmV-A1I7H!2dW1pH+sCUCma9-a~PwWX9EBL00000BLDyZ00000v#zd--~?C#fRQDC zf0)>tKulN;D3Dzn&!R-1M8*U*c(!q2&V}N~MeE?#l zdY!m?VC21_O2U3?V3@FbHK6fP7_el5qb}*GY#V1)#+~O$9c)l4oR{@cw2caF<{9e`UB` zz5H;Nx& zM{X04-z}Hf*z=N#^JmO9b<;fYbieHv)%H$31vJZ_ZPQj(AwC639)Zd!2~VO}>iE)D zLvpEhhR8e~u&C8!hAU}-gQSB~e=*&hdF2A7mUM+zF?!vd0hH0V2y&AgEaL-No*1)7 z8Swuzu2Zwp%b_~=`EqzN3bx>_@M^LS4@}Pdbx&Ls%>E=&hrA$%r9vVFSUW>(y=@uxP%c3uCR8^O5z?hL;+a2Ne+SF_-$8Iz z0001iGY75@)kW3Q7HlaWNFAEBw_?JB%-0RRCb0|5aAT>uaO3;+y)#tH#dYIPO> E07KAo1ONa4 From c820525bf343f5064c94a21679f158ddf6b74340 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 25 Feb 2024 21:39:42 +0100 Subject: [PATCH 048/266] v9.2 - DietPi-Installer | From Bookworm on, gcc-*-base packages are not "Priority: required" anymore, but "optional" instead, hence are autoremoved. So we we need to purge the obsolete ones on Bullseye only. - DietPi-Build | Leave obsolete gcc-*-base package removals to DietPi-Installer, which are only installed on Bullseye. - DietPi-Build | Remove --rpi-new flag. Instead use hardware models 1/2/4/5 as indicator that the new firmware is needed. Remove an obsolete Raspbian Trixie workaround and add new RPi firmware models to "all" workflow. --- .build/images/dietpi-build | 33 ++++++++---------------------- .build/images/dietpi-installer | 11 +++------- .github/workflows/dietpi-build.yml | 4 ++++ 3 files changed, 16 insertions(+), 32 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 4a23d65df9..5ec82d1f09 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -47,7 +47,6 @@ EDITION= SUFFIX= ADD_DOS_PART=1 SIGN_PASS= -RPI_NEW=0 while (( $# )) do case $1 in @@ -64,7 +63,6 @@ do '-s') shift; SUFFIX=$1;; '--no-dos-part') ADD_DOS_PART=0;; '--sign') shift; SIGN_PASS=$1;; - '--rpi-new') RPI_NEW=1;; *) G_DIETPI-NOTIFY 1 "Invalid input \"$1\", aborting..."; exit 1;; esac shift @@ -166,11 +164,10 @@ case $HW_ARCH in *) G_DIETPI-NOTIFY 1 "Invalid architecture \"$HW_ARCH\" passed, aborting..."; exit 1;; esac -exclude= case $DISTRO in - 6) distro='bullseye' exclude=',gcc-9-base';; - 7) distro='bookworm' exclude=',gcc-11-base';; - 8) distro='trixie' exclude+=',gcc-11-base,gcc-12-base,gcc-13-base';; + 6) distro='bullseye';; + 7) distro='bookworm';; + 8) distro='trixie';; *) G_DIETPI-NOTIFY 1 "Invalid distro \"$DISTRO\" passed, aborting..."; exit 1;; esac [[ $HW_ARCH == 11 ]] && distro='sid' # RISC-V architecture is available on Sid only @@ -181,16 +178,6 @@ case $PTTYPE in *) G_DIETPI-NOTIFY 1 "Invalid partition table type \"$PTTYPE\" passed, aborting..."; exit 1;; esac -if (( $RPI_NEW )) -then - (( $HW_MODEL < 10 && $DISTRO > 6 )) || { G_DIETPI-NOTIFY 1 "Invalid flag \"--rpi-new\" passed for hardware model \"$HW_MODEL\" or distro \"$DISTRO\" (${distro^}), aborting..."; exit 1; } - -elif (( $HW_MODEL && $HW_MODEL < 10 )) -then - G_DIETPI-NOTIFY 1 "Invalid hardware model \"$HW_MODEL\" passed without flag \"--rpi-new\", aborting..." - exit 1 -fi - # Do not add trailing FAT partitions for VM, container and (Clonezilla) installer images, and if there is a boot FAT partition already [[ $HW_MODEL == 20 || $HW_MODEL == 75 || $ITYPE == 'Installer' ]] && ADD_DOS_PART=0 [[ $boot_size -gt 0 && $boot_fstype == 'fat'* ]] && ADD_DOS_PART=0 @@ -353,7 +340,7 @@ then G_EXEC "mkfs.$FSTYPE" "${afs_opts[@]}" "${FP_LOOP}p2" G_EXEC mount "${FP_LOOP}p2" rootfs fp_boot='boot' - (( $RPI_NEW )) && fp_boot+='/firmware' + [[ $HW_MODEL == [1245] ]] && fp_boot+='/firmware' G_EXEC mkdir -p "rootfs/$fp_boot" G_EXEC mount "${FP_LOOP}p1" "rootfs/$fp_boot" G_EXEC mkdir rootfs/etc @@ -392,7 +379,7 @@ G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/log packages='apt,bash-completion,bzip2,ca-certificates,cron,curl,fdisk,gnupg,htop,iputils-ping,locales,nano,p7zip,parted,procps,psmisc,sudo,systemd-sysv,tzdata,udev,unzip,wget,whiptail,' [[ $HW_MODEL == 75 ]] && packages+='iproute2' || packages+='console-setup,dropbear,ethtool,fake-hwclock,ifupdown,isc-dhcp-client,kmod,rfkill,systemd-timesyncd,usbutils' G_EXEC_POST_FUNC(){ [[ $exit_code == 0 ]] || cat /dev/shm/rootfs/debootstrap/debootstrap.log; } -G_EXEC_OUTPUT=1 G_EXEC debootstrap --variant=minbase --exclude="gcc-7-base$exclude" --include="$packages" --arch="$parch" --keyring="$keyring" "$distro" ./rootfs "$repo" +G_EXEC_OUTPUT=1 G_EXEC debootstrap --variant=minbase --include="$packages" --arch="$parch" --keyring="$keyring" "$distro" ./rootfs "$repo" G_EXEC umount rootfs/dev rootfs/run rootfs/var/cache/apt rootfs/var/lib/apt/lists rootfs/var/log ########################################## @@ -457,7 +444,7 @@ G_EXEC losetup -d "$FP_LOOP" export FP_ROOT_DEV CLONING_TOOL OUTPUT_IMG_NAME MOUNT_IT='Off' SKIP_ARCHIVE SKIP_FIRSTBOOT_RESIZE=1 IMAGER_ARGS=("$OUTPUT_IMG_NAME.img") (( $ADD_DOS_PART )) && IMAGER_ARGS+=('--add-dos-part') -(( $RPI_NEW )) && IMAGER_ARGS+=('--configs-to-boot') +[[ $HW_MODEL == [1245] ]] && IMAGER_ARGS+=('--configs-to-boot') [[ $SIGN_PASS ]] && IMAGER_ARGS+=('--sign' "$SIGN_PASS") if [[ ! $EDITION || $EDITION == 'all' ]] then @@ -489,7 +476,7 @@ then # Mount filesystems G_EXEC mkdir rootfs - if (( $RPI_NEW )) + if [[ $HW_MODEL == [1245] ]] then G_EXEC mount "${FP_LOOP}p2" rootfs @@ -551,9 +538,10 @@ then # Mount filesystems G_EXEC mkdir rootfs - if (( $RPI_NEW )) + if [[ $HW_MODEL == [1245] ]] then G_EXEC mount "${FP_LOOP}p2" rootfs + G_EXEC mount "${FP_LOOP}p1" rootfs/boot/firmware elif (( $boot_size )) then @@ -591,9 +579,6 @@ _EOF_ # Force ARMv6 arch on Raspbian (( $HW_ARCH == 1 )) && echo 'sed --follow-symlinks -i -e '\''/^G_HW_ARCH=/c\G_HW_ARCH=1'\'' -e '\''/^G_HW_ARCH_NAME=/c\G_HW_ARCH_NAME=armv6l'\'' /boot/dietpi/.hw_model' > rootfs/boot/Automation_Custom_PreScript.sh - # Temporary fix for failing NAA Daemon install on Trixie - (( $DISTRO == 8 )) && G_EXEC sed --follow-symlinks -i '\|www.signalyst.eu|s|bookworm/bullseye|trixie/bullseye|' rootfs/boot/dietpi/dietpi-software - # Skip filesystem expansion G_EXEC rm rootfs/etc/systemd/system/local-fs.target.wants/dietpi-fs_partition_resize.service diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 8ea242dacd..123a5320c1 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1538,16 +1538,11 @@ _EOF_ # Replace usrmerge with usr-is-merged again, in case of dist-upgraded systems dpkg-query -s usrmerge &> /dev/null && G_AGP usrmerge - # Remove old gcc-*-base packages, e.g. accumulated on Raspberry Pi OS images + # Bullseye: Remove old gcc-*-base packages, e.g. accumulated on Raspberry Pi OS images and installed by debootstrap, which are not autoremoved due to "Priority: required" # shellcheck disable=SC2015 - case $G_DISTRO in - 5) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-8-/{print $1}');; - 6) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-10-/{print $1}');; - 7) mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-12-/{print $1}');; - 8) dpkg-query -s 'gcc-14-base' &> /dev/null && mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-14-/{print $1}') || mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-13-/{print $1}');; # Temporary workaround for Raspbian Trixie not shipping gcc-14-base yet - *) :;; - esac + (( $G_DISTRO == 6 )) && mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-10-/{print $1}');; [[ ${apackages[0]} ]] && G_AGP "${apackages[@]}" + unset -v apackages G_DIETPI-NOTIFY 2 'Restoring default base files:' # shellcheck disable=SC2114 diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index 0e22d4fc7b..cb92edee03 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -24,6 +24,10 @@ jobs: '"-m 0 -a 1 -d 6 -e all", "-m 0 -a 2 -d 6 -e all", "-m 0 -a 3 -d 6 -e all", '\ '"-m 0 -a 1 -d 7 -e all", "-m 0 -a 2 -d 7 -e all", "-m 0 -a 3 -d 7 -e all", '\ '"-m 0 -a 1 -d 8 -e all", "-m 0 -a 2 -d 8 -e all", "-m 0 -a 3 -d 8 -e all", '\ + '"-m 1 -d 7 -e all", "-m 1 -d 8 -e all", '\ + '"-m 2 -d 7 -e all", "-m 2 -d 8 -e all", '\ + '"-m 4 -d 7 -e all", "-m 4 -d 8 -e all", '\ + '"-m 5 -d 7 -e all", "-m 5 -d 8 -e all", '\ '"-m 10 -d 6", "-m 10 -d 7", "-m 10 -d 8", '\ '"-m 11 -d 6", "-m 11 -d 7", "-m 11 -d 8", '\ '"-m 12 -d 6", "-m 12 -d 7", "-m 12 -d 8", '\ From f6564baa3b63f6a806475b75b503ea37334dd82b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 25 Feb 2024 21:50:09 +0100 Subject: [PATCH 049/266] v9.2 - DietPi-Installer | Syntax --- .build/images/dietpi-installer | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 123a5320c1..7254702d51 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1540,7 +1540,7 @@ _EOF_ # Bullseye: Remove old gcc-*-base packages, e.g. accumulated on Raspberry Pi OS images and installed by debootstrap, which are not autoremoved due to "Priority: required" # shellcheck disable=SC2015 - (( $G_DISTRO == 6 )) && mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-10-/{print $1}');; + (( $G_DISTRO == 6 )) && mapfile -t apackages < <(dpkg --get-selections 'gcc-*-base' | mawk '$1!~/^gcc-10-/{print $1}') [[ ${apackages[0]} ]] && G_AGP "${apackages[@]}" unset -v apackages From 6c39b1257ac36b9ae3e1821c4a4ff56268580564 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 26 Feb 2024 19:05:38 +0100 Subject: [PATCH 050/266] v9.2 - DietPi-Software | NoMachine: Remove ~/NoMachine directory for all users on uninstall and bump to latest version --- dietpi/dietpi-software | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index eee7f5215b..c6abb6d496 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3228,12 +3228,12 @@ _EOF_ if To_Install 30 # NoMachine then - local version='8.10.1_1' # https://downloads.nomachine.com/ + local version='8.11.3_3' # https://downloads.nomachine.com/ case $G_HW_ARCH in 1) local url="Raspberry/nomachine_${version}_armv6hf";; 2) local url="Arm/nomachine_${version}_armhf";; 3) local url="Arm/nomachine_${version}_arm64";; - *) local url="Linux/nomachine_${version}_amd64";; + *) local url="Linux/nomachine_${version}_amd64" version='8.11.3_4';; esac Download_Install "https://download.nomachine.com/download/${version%.*}/$url.deb" aSTART_SERVICES+=('nxserver') @@ -10561,7 +10561,7 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.6/gitea-1.21.6-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.7/gitea-1.21.7-linux-$arch.xz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/go-gitea/gitea/releases/latest' | mawk -F\" "/\"browser_download_url\": \".*\/gitea-[^\"\/]*-linux-$arch\.xz\"/{print \$4}")" /mnt/dietpi_userdata/gitea/gitea # User @@ -12163,7 +12163,7 @@ If no WireGuard (auto)start is included, but you require it, please do the follo then apt-mark auto qterminal xarchiver lxde-icon-theme upower xscreensaver leafpad featherpad speedcrunch 2> /dev/null G_AGP lxqt - rm -Rf /{root,home/*}/.config/lxqt + G_EXEC rm -Rf /{root,home/*}/.config/lxqt fi if To_Uninstall 174 # GIMP @@ -12202,6 +12202,7 @@ If no WireGuard (auto)start is included, but you require it, please do the follo if To_Uninstall 30 # NoMachine then G_AGP nomachine + G_EXEC rm -Rf /{root,home/*}/NoMachine fi if To_Uninstall 29 # XRDP From 24c05c71961c77ca832bf87af843be4ce538d2bc Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 27 Feb 2024 13:15:11 +0100 Subject: [PATCH 051/266] v9.2 - DietPi-Software | NoMachine: Fix URL development --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index c6abb6d496..6131e2a9c9 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3233,7 +3233,7 @@ _EOF_ 1) local url="Raspberry/nomachine_${version}_armv6hf";; 2) local url="Arm/nomachine_${version}_armhf";; 3) local url="Arm/nomachine_${version}_arm64";; - *) local url="Linux/nomachine_${version}_amd64" version='8.11.3_4';; + *) version='8.11.3_4'; local url="Linux/nomachine_${version}_amd64";; esac Download_Install "https://download.nomachine.com/download/${version%.*}/$url.deb" aSTART_SERVICES+=('nxserver') From a48f8269028160316c55c8a536daaf3bbb44861a Mon Sep 17 00:00:00 2001 From: Paul Mikki Sakurai <23254804+pdsakurai@users.noreply.github.com> Date: Wed, 28 Feb 2024 06:33:23 +0800 Subject: [PATCH 052/266] v9.1 (#6931) - DietPi-Software | Home Assistant: Resolved an issue on x86_64 and ARMv8 systems where some core integrations did not work if no C++ compiler was installed. If you are affected by this, "apt install g++ && systemctl restart home-assistant" will fix it. Many thanks to @pdsakurai for fixing this issue in our install code: https://github.com/MichaIng/DietPi/pull/6931 --- CHANGELOG.txt | 3 ++- dietpi/dietpi-software | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 835727ce83..d8682757c6 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,7 +6,8 @@ Enhancements: Bug fixes: - DietPi-Software | PaperMC: Resolved an issue where installing the Geyser and Floodgate plugins failed due to changed download URLs, and a false syntax in the Geyser config file. Many thanks to @boterocamilo for reporting this issue: https://github.com/MichaIng/DietPi/issues/6898 -- DietPi-Software | Nextcloud: Resolved an issue with the updated Nginx config, where assets were served with the wrong MIME type. This fix was backported to v9.1 and a live patch offered. Many thanks to @howardroark for reporting this issue: https://dietpi.com/forum/t/nextcloud-theme-broken-after-upgrade-v9-1-1/19372 +- DietPi-Software | Nextcloud: Resolved an issue with the updated Nginx config where assets were served with the wrong MIME type. This fix was backported to v9.1 and a live patch offered. Many thanks to @howardroark for reporting this issue: https://dietpi.com/forum/t/nextcloud-theme-broken-after-upgrade-v9-1-1/19372 +- DietPi-Software | Home Assistant: Resolved an issue on x86_64 and ARMv8 systems where some core integrations did not work if no C++ compiler was installed. If you are affected by this, "apt install g++ && systemctl restart home-assistant" will fix it. Many thanks to @pdsakurai for fixing this issue in our install code: https://github.com/MichaIng/DietPi/pull/6931 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 6131e2a9c9..ac5a73e619 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11214,8 +11214,8 @@ _EOF_ local custom_apt_deps=$(sed -n '/^[[:blank:]]*SOFTWARE_HOMEASSISTANT_APT_DEPS=/{s/^[^=]*=//p;q}' /boot/dietpi.txt) local custom_pip_deps=$(sed -n '/^[[:blank:]]*SOFTWARE_HOMEASSISTANT_PIP_DEPS=/{s/^[^=]*=//p;q}' /boot/dietpi.txt) # - All: gcc, libc6-dev, make, libssl-dev, zlib1g-dev for Python build and libbz2-dev, libreadline-dev, libsqlite3-dev, liblzma-dev to suppress warnings - # - All: libffi-dev to solve "ModuleNotFoundError: No module named '_ctypes'", for python-slugify==4.0.1 build on ARMv8/x86_64 and cffi build on ARMv6/7/RISC-V - aDEPS=('gcc' 'libc6-dev' 'make' 'libssl-dev' 'zlib1g-dev' 'libbz2-dev' 'libreadline-dev' 'libsqlite3-dev' 'liblzma-dev' 'libffi-dev') + # - All: libffi-dev to solve "ModuleNotFoundError: No module named '_ctypes'", for python-slugify==4.0.1 build on ARMv8/x86_64 and cffi build on ARMv6/7/RISC-V, g++ for webrtc-noise-gain + aDEPS=('gcc' 'g++' 'libc6-dev' 'make' 'libssl-dev' 'zlib1g-dev' 'libbz2-dev' 'libreadline-dev' 'libsqlite3-dev' 'liblzma-dev' 'libffi-dev') mapfile -t -d' ' -O "${#aDEPS[@]}" aDEPS < <(echo -n "$custom_apt_deps") # - ARMv6/7/RISC-V G_EXEC mkdir -p "$ha_home" @@ -11223,7 +11223,7 @@ _EOF_ if [[ $G_HW_ARCH =~ ^(1|2|11)$ ]] then # libjpeg62-turbo-dev for Pillow, libopenblas-dev and pkg-config for numpy, pkg-config for cryptography, g++ for PyTurboJPEG, SQLAlchemy and ninja > PyTurboJPEG, libavdevice-dev for ha-av, cmake for ninja > PyTurboJPEG, automake for patchelf > PyTurboJPEG - aDEPS+=('libjpeg62-turbo-dev' 'libopenblas-dev' 'pkg-config' 'g++' 'libavdevice-dev' 'cmake' 'automake') + aDEPS+=('libjpeg62-turbo-dev' 'libopenblas-dev' 'pkg-config' 'libavdevice-dev' 'cmake' 'automake') # Rust for cryptography and bcrypt G_EXEC curl -sSf 'https://sh.rustup.rs/' -o rustup-init.sh G_EXEC chmod +x rustup-init.sh From b04c67091f6df5d3acd130855f0232b8d5676272 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 3 Mar 2024 23:42:23 +0100 Subject: [PATCH 053/266] v9.2 - DietPi-Software | It is now possible to run "dietpi-software list" concurrent to other dietpi-software instances, and as non-root user. This avoids an issue in DietPi-Dashboard, where opening dietpi-software in the Terminal and switching to the Software page, caused an infinite hang. - DietPi-Globals | Resolved an issue where a concurrent DietPi script detection could have prevented the start of a script, if a previous instance was killed via SIGKILL. - DietPi-Config | Resolved an issue where a WiFi connection, configured for the first time via dietpi-config from a local terminal session, was automatically stopped when exiting or logging out from the terminal session. --- CHANGELOG.txt | 3 +++ dietpi/dietpi-config | 29 ++++++++++++++++------------- dietpi/dietpi-software | 11 +++++++---- dietpi/func/dietpi-globals | 24 ++++++++++-------------- 4 files changed, 36 insertions(+), 31 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index d8682757c6..ccbe616934 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -3,8 +3,11 @@ v9.2 Enhancements: - NanoPi R4S | Resolved an issue where Ethernet adapter of the "LAN" port could disappear after a soft reboot. Many thanks to @idaanx for reporting this issue: https://github.com/MichaIng/DietPi/issues/6342 +- DietPi-Software | It is now possible to run "dietpi-software list" concurrent to other dietpi-software instances, and as non-root user. This avoids an issue in DietPi-Dashboard, where opening dietpi-software in the Terminal and switching to the Software page, caused an infinite hang. Bug fixes: +- DietPi-Globals | Resolved an issue where a concurrent DietPi script detection could have prevented the start of a script, if a previous instance was killed via SIGKILL. +- DietPi-Config | Resolved an issue where a WiFi connection, configured for the first time via dietpi-config from a local terminal session, was automatically stopped when exiting or logging out from the terminal session. - DietPi-Software | PaperMC: Resolved an issue where installing the Geyser and Floodgate plugins failed due to changed download URLs, and a false syntax in the Geyser config file. Many thanks to @boterocamilo for reporting this issue: https://github.com/MichaIng/DietPi/issues/6898 - DietPi-Software | Nextcloud: Resolved an issue with the updated Nginx config where assets were served with the wrong MIME type. This fix was backported to v9.1 and a live patch offered. Many thanks to @howardroark for reporting this issue: https://dietpi.com/forum/t/nextcloud-theme-broken-after-upgrade-v9-1-1/19372 - DietPi-Software | Home Assistant: Resolved an issue on x86_64 and ARMv8 systems where some core integrations did not work if no C++ compiler was installed. If you are affected by this, "apt install g++ && systemctl restart home-assistant" will fix it. Many thanks to @pdsakurai for fixing this issue in our install code: https://github.com/MichaIng/DietPi/pull/6931 diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index 28231fd14c..5ad0647fc4 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -1930,23 +1930,26 @@ If unsure, set any value, 'Ondemand Down Factor' option on the next screen will \nThis will free up space, but an internet-capable Ethernet connection is required to re-enable WiFi functionality. \nAffected packages: iw wireless-tools wpasupplicant wireless-regdb crda' && G_AGP 'iw' 'wireless-tools' 'wpasupplicant' 'wireless-regdb' 'crda' - # Drop connections - G_DIETPI-NOTIFY 2 'Dropping network connections, please wait...' - ifdown --force "$ETH_DEV_IFACE" 2> /dev/null - ifdown --force "$WIFI_DEV_IFACE" 2> /dev/null - - # Kill DHCP client - killall dhclient 2> /dev/null - # Restart network G_DIETPI-NOTIFY 2 'Restarting network connections, please wait...' G_EXEC systemctl daemon-reload - - # Manually bring up adapters - (( $ETH_DISABLED )) || ifup --force "$ETH_DEV_IFACE" - if (( ! $WIFI_DISABLED )) + # - Ethernet + if (( ! $ETH_DISABLED )) then - (( $WIFI_HOTSPOT )) || grep -q '^network=' /etc/wpa_supplicant/wpa_supplicant.conf && ifup --force "$WIFI_DEV_IFACE" + { journalctl -fn 0 -u "ifup@$ETH_DEV_IFACE" & pid=$!; } 2> /dev/null + G_EXEC_NOHALT=1 G_EXEC_OUTPUT=1 G_EXEC systemctl restart "ifup@$ETH_DEV_IFACE" + { kill -2 %% && wait; } 2> /dev/null + else + ifdown --force "$ETH_DEV_IFACE" 2> /dev/null + fi + # - WiFi: Only try to configure if this is either a hotspot or an SSID has been configured + if (( ! $WIFI_DISABLED )) && { (( $WIFI_HOTSPOT )) || grep -q '^network=' /etc/wpa_supplicant/wpa_supplicant.conf; } + then + { journalctl -fn 0 -u "ifup@$WIFI_DEV_IFACE" & pid=$!; } 2> /dev/null + G_EXEC_NOHALT=1 G_EXEC_OUTPUT=1 G_EXEC systemctl restart "ifup@$WIFI_DEV_IFACE" + { kill -2 %% && wait; } 2> /dev/null + else + ifdown --force "$WIFI_DEV_IFACE" 2> /dev/null fi # Start WiFi hotspot diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index ac5a73e619..b836fb2d15 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -26,9 +26,12 @@ Available commands: # Import DietPi-Globals --------------------------------------------------------------- . /boot/dietpi/func/dietpi-globals readonly G_PROGRAM_NAME='DietPi-Software' - G_CHECK_ROOT_USER - G_CHECK_ROOTFS_RW - G_INIT + if [[ $1 != 'list' ]] + then + G_CHECK_ROOT_USER + G_CHECK_ROOTFS_RW + G_INIT + fi # Import DietPi-Globals --------------------------------------------------------------- [[ $1 == 'list' && $2 == '--machine-readable' ]] && MACHINE_READABLE=1 || MACHINE_READABLE= @@ -15447,7 +15450,7 @@ List of installed software and their online documentation URLs: # Main Loop #///////////////////////////////////////////////////////////////////////////////////// # Abort if a reboot is required as of missing kernel modules - if (( $G_DIETPI_INSTALL_STAGE == 2 )) && ! G_CHECK_KERNEL + if [[ $1 != 'list' && $G_DIETPI_INSTALL_STAGE == 2 ]] && ! G_CHECK_KERNEL then G_WHIP_BUTTON_CANCEL_TEXT='Abort' G_WHIP_YESNO "[ INFO ] A reboot is required \nKernel modules for the loaded kernel at /lib/modules/$(uname -r) are missing. This is most likely the case as of a recently applied kernel upgrade where a reboot is required to load the new kernel. diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 8c510115c9..c20287082d 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -102,14 +102,17 @@ G_GITOWNER='$G_GITOWNER'" > /boot/dietpi/.version readonly G_WORKING_DIR="/tmp/${G_PROGRAM_NAME}_$i" else # Concurrency not allowed: Use existing working directory as flag - local limit=${G_INIT_WAIT_CONCURRENT:-5} + readonly G_WORKING_DIR="/tmp/$G_PROGRAM_NAME" + G_INIT_WAIT_CONCURRENT=${G_INIT_WAIT_CONCURRENT:=5} - while [[ -d /tmp/$G_PROGRAM_NAME ]] + while [[ -d $G_WORKING_DIR ]] do - if (( $i < $limit )) + # SIGKILL prevents the exit trap from removing this dir. Remove it in this case and proceed. + [[ $(pidof "$0") == *' '* ]] && { rm -R "$G_WORKING_DIR"; break; } + if (( $i < $G_INIT_WAIT_CONCURRENT )) then ((i++)) - G_DIETPI-NOTIFY 2 "Concurrent execution of $G_PROGRAM_NAME detected, retrying... ($i/$limit)" + G_DIETPI-NOTIFY 2 "Concurrent execution of $G_PROGRAM_NAME detected, retrying... ($i/$G_INIT_WAIT_CONCURRENT)" G_SLEEP 1 else G_WHIP_BUTTON_OK_TEXT='Retry' @@ -121,14 +124,12 @@ Please check if one of the following applies: - You started this script from within another DietPi program, causing a loop.\n Please assure that the concurrent execution has finished, before retrying, otherwise cancel this instance.\n The following info might help: -$(ps f -eo pid,user,tty,cmd | grep -i '[d]ietpi')" && continue +$(ps f -eo pid,user,tty,cmd | grep -i 'dietpi')" && continue G_DIETPI-NOTIFY 1 "Cancelled $G_PROGRAM_NAME due to concurrent execution" exit 1 fi done - - readonly G_WORKING_DIR="/tmp/$G_PROGRAM_NAME" fi # Declare exit trap which runs on EXIT signals, including SIGINT and SIGTERM but not SIGKILL! @@ -148,13 +149,8 @@ $(ps f -eo pid,user,tty,cmd | grep -i '[d]ietpi')" && continue # Create and navigate to scripts working directory or users home if available: https://github.com/MichaIng/DietPi/issues/905#issuecomment-298223705 mkdir -p "$G_WORKING_DIR" && cd "$G_WORKING_DIR" && return - G_DIETPI-NOTIFY 1 "Failed to create or enter scripts working directory: $G_WORKING_DIR" - if [[ $HOME && -d $HOME ]] - then - cd "$HOME" && { G_DIETPI-NOTIFY 2 "Entered users home directory: $HOME"; return; } - G_DIETPI-NOTIFY 1 "Failed to enter users home directory: $HOME" - fi - G_DIETPI-NOTIFY 2 "Will stay in current directory: $PWD" + G_DIETPI-NOTIFY 1 "Failed to create or enter scripts working directory: $G_WORKING_DIR. Aborting ..." + exit 1 } From 264e07a32885879504305949511df06580ec55ff Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 3 Mar 2024 23:53:44 +0100 Subject: [PATCH 054/266] v9.2 - DietPi-Config | Remove obsolete variable --- dietpi/dietpi-config | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index 5ad0647fc4..927f7ed6c9 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -1936,7 +1936,7 @@ If unsure, set any value, 'Ondemand Down Factor' option on the next screen will # - Ethernet if (( ! $ETH_DISABLED )) then - { journalctl -fn 0 -u "ifup@$ETH_DEV_IFACE" & pid=$!; } 2> /dev/null + { journalctl -fn 0 -u "ifup@$ETH_DEV_IFACE" & } 2> /dev/null G_EXEC_NOHALT=1 G_EXEC_OUTPUT=1 G_EXEC systemctl restart "ifup@$ETH_DEV_IFACE" { kill -2 %% && wait; } 2> /dev/null else @@ -1945,7 +1945,7 @@ If unsure, set any value, 'Ondemand Down Factor' option on the next screen will # - WiFi: Only try to configure if this is either a hotspot or an SSID has been configured if (( ! $WIFI_DISABLED )) && { (( $WIFI_HOTSPOT )) || grep -q '^network=' /etc/wpa_supplicant/wpa_supplicant.conf; } then - { journalctl -fn 0 -u "ifup@$WIFI_DEV_IFACE" & pid=$!; } 2> /dev/null + { journalctl -fn 0 -u "ifup@$WIFI_DEV_IFACE" & } 2> /dev/null G_EXEC_NOHALT=1 G_EXEC_OUTPUT=1 G_EXEC systemctl restart "ifup@$WIFI_DEV_IFACE" { kill -2 %% && wait; } 2> /dev/null else From 943a16935dc60117b6604be0c776ac717d237548 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 5 Mar 2024 22:49:46 +0100 Subject: [PATCH 055/266] v9.2 - DietPi-Software | Syncthing: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index b836fb2d15..4402b570f4 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8941,7 +8941,7 @@ _EOF_ *) local arch='arm';; esac - local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.27.3/syncthing-linux-$arch-v1.27.3.tar.gz" + local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.27.4/syncthing-linux-$arch-v1.27.4.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/syncthing/syncthing/releases/latest' | mawk -F\" "/\"browser_download_url\": .*\/syncthing-linux-$arch-[^\"\/]*\.tar\.gz\"/{print \$4}")" G_EXEC mv syncthing-* /opt/syncthing fi From 8aaa078039726537c44c5fba10123c5062922c2e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 6 Mar 2024 19:13:49 +0100 Subject: [PATCH 056/266] v9.2 - DietPi-Build | Fix debootstrap log path --- .build/images/dietpi-build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 5ec82d1f09..2464c916d4 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -378,7 +378,7 @@ G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/lib/apt/lists G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/log packages='apt,bash-completion,bzip2,ca-certificates,cron,curl,fdisk,gnupg,htop,iputils-ping,locales,nano,p7zip,parted,procps,psmisc,sudo,systemd-sysv,tzdata,udev,unzip,wget,whiptail,' [[ $HW_MODEL == 75 ]] && packages+='iproute2' || packages+='console-setup,dropbear,ethtool,fake-hwclock,ifupdown,isc-dhcp-client,kmod,rfkill,systemd-timesyncd,usbutils' -G_EXEC_POST_FUNC(){ [[ $exit_code == 0 ]] || cat /dev/shm/rootfs/debootstrap/debootstrap.log; } +G_EXEC_POST_FUNC(){ [[ $exit_code == 0 ]] || cat rootfs/debootstrap/debootstrap.log; } G_EXEC_OUTPUT=1 G_EXEC debootstrap --variant=minbase --include="$packages" --arch="$parch" --keyring="$keyring" "$distro" ./rootfs "$repo" G_EXEC umount rootfs/dev rootfs/run rootfs/var/cache/apt rootfs/var/lib/apt/lists rootfs/var/log From 85e0f2ff08307d315a4322608b4a32c5c0f43b56 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 6 Mar 2024 20:53:33 +0100 Subject: [PATCH 057/266] v9.2 - CI | DietPi-Software build: Shutdown on failures before the custom script is executed, and remove obsolete workaround --- .build/software/dietpi-software-build.bash | 6 +++--- .github/workflows/dietpi-software.bash | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.build/software/dietpi-software-build.bash b/.build/software/dietpi-software-build.bash index 1ee510ef4a..b29492cb9c 100644 --- a/.build/software/dietpi-software-build.bash +++ b/.build/software/dietpi-software-build.bash @@ -116,9 +116,6 @@ fi # Install Go for Gogs [[ $NAME == 'gogs' ]] && G_CONFIG_INJECT 'AUTO_SETUP_INSTALL_SOFTWARE_ID=' 'AUTO_SETUP_INSTALL_SOFTWARE_ID=188' rootfs/boot/dietpi.txt -# Gogs on RISC-V: Temporarily switch to dev branch until DietPi v8.24 has been released, installing Go from go.dev instead of APT -[[ $NAME == 'gogs' && $ARCH == 'riscv64' ]] && G_CONFIG_INJECT 'DEV_GITBRANCH=' 'DEV_GITBRANCH=dev' rootfs/boot/dietpi.txt - # Workaround invalid TERM on login # shellcheck disable=SC2016 G_EXEC eval 'echo '\''infocmp "$TERM" > /dev/null 2>&1 || { echo "[ WARN ] Unsupported TERM=\"$TERM\", switching to TERM=\"dumb\""; export TERM=dumb; }'\'' > rootfs/etc/bashrc.d/00-dietpi-build.sh' @@ -126,6 +123,9 @@ G_EXEC eval 'echo '\''infocmp "$TERM" > /dev/null 2>&1 || { echo "[ WARN ] Unsup # Workaround for failing IPv4 network connectivity check as GitHub Actions runners do not receive external ICMP echo replies G_CONFIG_INJECT 'CONFIG_CHECK_CONNECTION_IP=' 'CONFIG_CHECK_CONNECTION_IP=127.0.0.1' rootfs/boot/dietpi.txt +# Shutdown on failures before the custom script is executed +G_EXEC sed --follow-symlinks -i 's|Prompt_on_Failure$|{ journalctl -n 50; ss -tulpn; df -h; free -h; poweroff; }|' rootfs/boot/dietpi/dietpi-login + # Avoid DietPi-Survey uploads to not mess with the statistics G_EXEC rm rootfs/root/.ssh/known_hosts diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index 69225e7e84..3c012136d2 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -413,9 +413,9 @@ done # Success flag and shutdown # shellcheck disable=SC2016 -G_EXEC eval 'echo '\''[ $exit_code = 0 ] && > /success || { journalctl -n 50; ss -tlpn; df -h; free -h; poweroff; }; poweroff'\'' >> rootfs/boot/Automation_Custom_Script.sh' +G_EXEC eval 'echo '\''[ $exit_code = 0 ] && > /success || { journalctl -n 50; ss -tulpn; df -h; free -h; }; poweroff'\'' >> rootfs/boot/Automation_Custom_Script.sh' -# Shutdown as well on failure +# Shutdown as well on failures before the custom script is executed G_EXEC sed --follow-symlinks -i 's|Prompt_on_Failure$|{ journalctl -n 50; ss -tulpn; df -h; free -h; poweroff; }|' rootfs/boot/dietpi/dietpi-login ########################################## From 87248a9f30da3ec75ebb276101f3850c5b58054a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 6 Mar 2024 21:06:25 +0100 Subject: [PATCH 058/266] v9.2 - CI | Squeezelite: Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 --- .build/software/squeezelite/build.bash | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.build/software/squeezelite/build.bash b/.build/software/squeezelite/build.bash index bb4e40835e..07788668a6 100755 --- a/.build/software/squeezelite/build.bash +++ b/.build/software/squeezelite/build.bash @@ -16,7 +16,8 @@ case $G_DISTRO in esac for i in "${adeps[@]}" do - dpkg-query -s "$i" &> /dev/null && continue + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || dpkg-query -s "${i}t64" &> /dev/null && continue G_DIETPI-NOTIFY 1 "Expected dependency package was not installed: $i" exit 1 done From 03093b9c8e715262305899358bb208052668c587 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 6 Mar 2024 21:08:33 +0100 Subject: [PATCH 059/266] v9.2 - CI | Amiberry: Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 --- .build/software/Amiberry/build.bash | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.build/software/Amiberry/build.bash b/.build/software/Amiberry/build.bash index fadbbc3d75..692dba65d3 100755 --- a/.build/software/Amiberry/build.bash +++ b/.build/software/Amiberry/build.bash @@ -21,7 +21,8 @@ G_AGUP G_AGDUG "${adeps_build[@]}" for i in "${adeps[@]}" do - dpkg-query -s "$i" &> /dev/null && continue + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || dpkg-query -s "${i}t64" &> /dev/null && continue G_DIETPI-NOTIFY 1 "Expected dependency package was not installed: $i" exit 1 done From 9ff3f870161401da0908f4fbbaee653a57da2474 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 6 Mar 2024 21:42:32 +0100 Subject: [PATCH 060/266] v9.2 - CI | Fix version string for *t64 packages --- .build/software/Amiberry/build.bash | 2 ++ .build/software/squeezelite/build.bash | 2 ++ 2 files changed, 4 insertions(+) diff --git a/.build/software/Amiberry/build.bash b/.build/software/Amiberry/build.bash index 692dba65d3..e238897a82 100755 --- a/.build/software/Amiberry/build.bash +++ b/.build/software/Amiberry/build.bash @@ -186,6 +186,8 @@ find "$DIR" ! \( -path "$DIR/DEBIAN" -prune \) -type f -exec md5sum {} + | sed " DEPS_APT_VERSIONED= for i in "${adeps[@]}" do + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || i+='t64' DEPS_APT_VERSIONED+=" $i (>= $(dpkg-query -Wf '${VERSION}' "$i"))," done DEPS_APT_VERSIONED=${DEPS_APT_VERSIONED%,} diff --git a/.build/software/squeezelite/build.bash b/.build/software/squeezelite/build.bash index 07788668a6..62dcebc265 100755 --- a/.build/software/squeezelite/build.bash +++ b/.build/software/squeezelite/build.bash @@ -144,6 +144,8 @@ find "$DIR" ! \( -path "$DIR/DEBIAN" -prune \) -type f -exec md5sum {} + | sed " DEPS_APT_VERSIONED= for i in "${adeps[@]}" do + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || i+='t64' DEPS_APT_VERSIONED+=" $i (>= $(dpkg-query -Wf '${VERSION}' "$i"))," done DEPS_APT_VERSIONED=${DEPS_APT_VERSIONED%,} From 9b4b5aa36889b0a0bd871750eca665481d8acc44 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Mar 2024 21:28:39 +0100 Subject: [PATCH 061/266] v9.2 - DietPi-Software | DarkIce: Resolved an issue where the service failed to start due to false config file permissions. --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index ccbe616934..5d481cf221 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -11,6 +11,7 @@ Bug fixes: - DietPi-Software | PaperMC: Resolved an issue where installing the Geyser and Floodgate plugins failed due to changed download URLs, and a false syntax in the Geyser config file. Many thanks to @boterocamilo for reporting this issue: https://github.com/MichaIng/DietPi/issues/6898 - DietPi-Software | Nextcloud: Resolved an issue with the updated Nginx config where assets were served with the wrong MIME type. This fix was backported to v9.1 and a live patch offered. Many thanks to @howardroark for reporting this issue: https://dietpi.com/forum/t/nextcloud-theme-broken-after-upgrade-v9-1-1/19372 - DietPi-Software | Home Assistant: Resolved an issue on x86_64 and ARMv8 systems where some core integrations did not work if no C++ compiler was installed. If you are affected by this, "apt install g++ && systemctl restart home-assistant" will fix it. Many thanks to @pdsakurai for fixing this issue in our install code: https://github.com/MichaIng/DietPi/pull/6931 +- DietPi-Software | DarkIce: Resolved an issue where the service failed to start due to false config file permissions. As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 4402b570f4..0d24cedeec 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -5559,7 +5559,8 @@ _EOF_ # DarkIce [[ -f '/etc/darkice.cfg' ]] || > /etc/darkice.cfg - G_EXEC chmod 0600 /etc/darkice.cfg + G_EXEC chown root:dietpi /etc/darkice.cfg + G_EXEC chmod 0640 /etc/darkice.cfg local input_device_index=$(arecord -l | mawk -F'[ :]' '/card/{print $2;exit}') cat << _EOF_ > /etc/darkice.cfg [general] From b075d14d3c0766916e240cd7c782ca2f7bd99896 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Mar 2024 21:55:47 +0100 Subject: [PATCH 062/266] v9.2 - DietPi-Software | DarkIce: Further tweak service permissions, to allow writing to /mnt/dietpi_userdata and listening on the audio recording device --- dietpi/dietpi-software | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 0d24cedeec..f15c4fd464 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -5557,10 +5557,13 @@ _EOF_ # - Remove default service config [[ -f '/etc/default/icecast2' ]] && G_EXEC rm /etc/default/icecast2 + # User + Create_User -g audio -G dietpi darkice + # DarkIce [[ -f '/etc/darkice.cfg' ]] || > /etc/darkice.cfg - G_EXEC chown root:dietpi /etc/darkice.cfg - G_EXEC chmod 0640 /etc/darkice.cfg + G_EXEC chown darkice:root /etc/darkice.cfg + G_EXEC chmod 0600 /etc/darkice.cfg local input_device_index=$(arecord -l | mawk -F'[ :]' '/card/{print $2;exit}') cat << _EOF_ > /etc/darkice.cfg [general] @@ -5569,7 +5572,7 @@ bufferSecs = 3 reconnect = yes [input] -device = hw:$input_device_index,0 +device = hw:${input_device_index:-0},0 sampleRate = 44100 bitsPerSample = 16 channel = 1 @@ -5597,8 +5600,7 @@ Requires=icecast2.service After=icecast2.service [Service] -User=nobody -Group=dietpi +User=darkice ExecStart=$(command -v darkice) [Install] From 155855f8c112e458674ea3178265bed3203e13f1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Mar 2024 22:12:09 +0100 Subject: [PATCH 063/266] v9.2 - DietPi-Software | DarkIce: Allow process to change its CPU scheduling priority, to mute a related warning on startup, which suggests to run DarkIce as root. We do not want that, hence we grant it via capabiliteis instead. --- dietpi/dietpi-software | 1 + 1 file changed, 1 insertion(+) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index f15c4fd464..a85a9b9ce1 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -5601,6 +5601,7 @@ After=icecast2.service [Service] User=darkice +AmbientCapabilities=CAP_SYS_NICE ExecStart=$(command -v darkice) [Install] From a17c5137c7a1f96f41660dc6aaf2b3045827d5ff Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Mar 2024 22:23:03 +0100 Subject: [PATCH 064/266] v9.2 - CI | DietPi-Software: darkice service cannot start in container as is requires audio recording device access, test CLI instead --- .github/workflows/dietpi-software.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index 3c012136d2..696928bf65 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -162,7 +162,7 @@ Process_Software() 132) aSERVICES[i]='aria2' aTCP[i]='6800';; # aTCP[i]+=' 6881-6999';; # Listens on random port 133) (( $arch == 2 || $arch == 11 )) || aSERVICES[i]='yacy' aTCP[i]='8090'; (( $arch == 10 )) && aDELAY[i]=30; (( $arch == 10 || $arch == 2 || $arch == 11)) || aDELAY[i]=60;; 134) aCOMMANDS[i]='docker compose version';; - 135) aSERVICES[i]='icecast2 darkice' aTCP[i]='8000';; + 135) aSERVICES[i]='icecast2' aTCP[i]='8000' aCOMMANDS[i]='darkice -h';; # darkice service cannot start in container as is requires audio recording device access 136) aSERVICES[i]='motioneye' aTCP[i]='8765';; 137) aCOMMANDS[i]='/opt/mjpg-streamer/mjpg_streamer -v';; # aSERVICES[i]='mjpg-streamer' aTCP[i]='8082' Service does not start without an actual video device 138) aSERVICES[i]='virtualhere' aTCP[i]='7575';; From 83f7cb1dbe64c2b8db62c8281163698a8e4e35ae Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Mar 2024 23:31:53 +0100 Subject: [PATCH 065/266] v9.2 - DietPi-Services | Icecast: Replace init.d service with native systemd service, and some minor code restructure --- dietpi/dietpi-software | 36 +++++++++++++++++++++++++----------- 1 file changed, 25 insertions(+), 11 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index a85a9b9ce1..2329e4a618 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -463,7 +463,7 @@ Available commands: aSOFTWARE_DEPS[$software_id]='88 89 128 195 webserver' #------------------ software_id=135 - aSOFTWARE_NAME[$software_id]='IceCast' + aSOFTWARE_NAME[$software_id]='Icecast' aSOFTWARE_DESC[$software_id]='Shoutcast streaming server (+DarkIce)' aSOFTWARE_CATX[$software_id]=2 aSOFTWARE_DOCS[$software_id]='https://dietpi.com/docs/software/media/#icecast' @@ -5545,22 +5545,36 @@ _EOF_ G_EXEC chown -R www-data:www-data /var/www/ompd/{tmp,stream,cache} fi - if To_Install 135 icecast2 darkice # IceCast + DarkIce + if To_Install 135 icecast2 darkice # Icecast + DarkIce then G_AGI darkice icecast2 G_EXEC systemctl stop darkice icecast2 - # IceCast: Set passwords if not yet done (default found) + # Icecast + # - Config: Set passwords if not yet done (default found) sed --follow-symlinks -i "/hackme/c\ $GLOBAL_PW" /etc/icecast2/icecast.xml sed --follow-symlinks -i "/hackme/c\ $GLOBAL_PW" /etc/icecast2/icecast.xml sed --follow-symlinks -i "/hackme/c\ $GLOBAL_PW" /etc/icecast2/icecast.xml - # - Remove default service config - [[ -f '/etc/default/icecast2' ]] && G_EXEC rm /etc/default/icecast2 + # - Service: Replace init.d service with native systemd service + Remove_SysV icecast2 1 + cat << _EOF_ > /etc/systemd/system/icecast2.service +[Unit] +Description=Icecast (DietPi) +Wants=network-online.target +After=network-online.target - # User - Create_User -g audio -G dietpi darkice +[Service] +User=icecast2 +Group=icecast +ExecStart=/usr/bin/icecast2 -c /etc/icecast2/icecast.xml +[Install] +WantedBy=multi-user.target +_EOF_ # DarkIce + # - User + Create_User -g audio -G dietpi darkice + # - Config [[ -f '/etc/darkice.cfg' ]] || > /etc/darkice.cfg G_EXEC chown darkice:root /etc/darkice.cfg G_EXEC chmod 0600 /etc/darkice.cfg @@ -5592,17 +5606,17 @@ genre = none public = no #localDumpFile = /mnt/dietpi_userdata/darkice_recording.ogg _EOF_ + # - Service: Replace init.d service with native systemd service Remove_SysV darkice 1 cat << _EOF_ > /etc/systemd/system/darkice.service [Unit] Description=DarkIce (DietPi) -Requires=icecast2.service After=icecast2.service [Service] User=darkice AmbientCapabilities=CAP_SYS_NICE -ExecStart=$(command -v darkice) +ExecStart=/usr/bin/darkice [Install] WantedBy=multi-user.target @@ -6848,7 +6862,7 @@ _EOF_ # Cleanup G_EXEC rm -R WebIOPi-master - # On fresh installs, change port to 8002 to avoid conflict with IceCast + # On fresh installs, change port to 8002 to avoid conflict with Icecast (( $reinstall )) || G_EXEC sed --follow-symlinks -i 's/^port = 8000$/port = 8002/' /etc/webiopi/config # Service @@ -9419,7 +9433,7 @@ _EOF_ G_EXEC_OUTPUT=1 G_EXEC sudo -u koel "php$PHP_VERSION" artisan koel:sync G_EXEC cd "$G_WORKING_DIR" - # Service: Run on port 8003 by default to avoid conflict with IceCast + # Service: Run on port 8003 by default to avoid conflict with Icecast cat << _EOF_ > /etc/systemd/system/koel.service [Unit] Description=Koel (DietPi) From d228ab7b22ca1c6da63624e00b77527fd081adae Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Mar 2024 23:34:49 +0100 Subject: [PATCH 066/266] v9.2 - CI | DietPi-Software: "darkice -h" returns exit code 1, hence check with grep for expected output --- .github/workflows/dietpi-software.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index 696928bf65..a5b8e36915 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -162,7 +162,7 @@ Process_Software() 132) aSERVICES[i]='aria2' aTCP[i]='6800';; # aTCP[i]+=' 6881-6999';; # Listens on random port 133) (( $arch == 2 || $arch == 11 )) || aSERVICES[i]='yacy' aTCP[i]='8090'; (( $arch == 10 )) && aDELAY[i]=30; (( $arch == 10 || $arch == 2 || $arch == 11)) || aDELAY[i]=60;; 134) aCOMMANDS[i]='docker compose version';; - 135) aSERVICES[i]='icecast2' aTCP[i]='8000' aCOMMANDS[i]='darkice -h';; # darkice service cannot start in container as is requires audio recording device access + 135) aSERVICES[i]='icecast2' aTCP[i]='8000' aCOMMANDS[i]='darkice -h | grep '\''^DarkIce\';; # darkice service cannot start in container as is requires audio recording device access 136) aSERVICES[i]='motioneye' aTCP[i]='8765';; 137) aCOMMANDS[i]='/opt/mjpg-streamer/mjpg_streamer -v';; # aSERVICES[i]='mjpg-streamer' aTCP[i]='8082' Service does not start without an actual video device 138) aSERVICES[i]='virtualhere' aTCP[i]='7575';; From 2284b4b998bc0d12aeff8ca93c1f840604deaa1f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Mar 2024 23:46:00 +0100 Subject: [PATCH 067/266] v9.2 - CI | DietPi-Software: Syntax --- .github/workflows/dietpi-software.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index a5b8e36915..f10f4e2687 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -162,7 +162,7 @@ Process_Software() 132) aSERVICES[i]='aria2' aTCP[i]='6800';; # aTCP[i]+=' 6881-6999';; # Listens on random port 133) (( $arch == 2 || $arch == 11 )) || aSERVICES[i]='yacy' aTCP[i]='8090'; (( $arch == 10 )) && aDELAY[i]=30; (( $arch == 10 || $arch == 2 || $arch == 11)) || aDELAY[i]=60;; 134) aCOMMANDS[i]='docker compose version';; - 135) aSERVICES[i]='icecast2' aTCP[i]='8000' aCOMMANDS[i]='darkice -h | grep '\''^DarkIce\';; # darkice service cannot start in container as is requires audio recording device access + 135) aSERVICES[i]='icecast2' aTCP[i]='8000' aCOMMANDS[i]='darkice -h | grep '\''^DarkIce'\';; # darkice service cannot start in container as is requires audio recording device access 136) aSERVICES[i]='motioneye' aTCP[i]='8765';; 137) aCOMMANDS[i]='/opt/mjpg-streamer/mjpg_streamer -v';; # aSERVICES[i]='mjpg-streamer' aTCP[i]='8082' Service does not start without an actual video device 138) aSERVICES[i]='virtualhere' aTCP[i]='7575';; From 3a0f8dfdadff1ee2ea3911ad499a3641cc1a5526 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 9 Mar 2024 15:55:41 +0100 Subject: [PATCH 068/266] v9.2 (#6952) - CI | Squeezelite: Use again latest commit, with a fix for upstream libFLAC: https://github.com/ralph-irving/squeezelite/commit/fd89d67 - Coding | Mute new shellcheck annotation SC2324 --- .build/software/squeezelite/build.bash | 8 +++----- dietpi/dietpi-config | 4 ++-- dietpi/dietpi-software | 4 ++-- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/.build/software/squeezelite/build.bash b/.build/software/squeezelite/build.bash index 62dcebc265..ab6c717d89 100755 --- a/.build/software/squeezelite/build.bash +++ b/.build/software/squeezelite/build.bash @@ -24,13 +24,11 @@ done G_DIETPI-NOTIFY 2 'Downloading source code...' G_EXEC cd /tmp -# Freeze commit: https://github.com/ralph-irving/squeezelite/issues/206 -G_EXEC curl -sSfLO 'https://github.com/ralph-irving/squeezelite/archive/6de9e229aa4cc7c3131ff855f3ead39581127090.tar.gz' +G_EXEC curl -sSfLO 'https://github.com/ralph-irving/squeezelite/archive/master.tar.gz' [[ -d 'squeezelite-master' ]] && G_EXEC rm -R squeezelite-master -G_EXEC tar xf 6de9e229aa4cc7c3131ff855f3ead39581127090.tar.gz -G_EXEC rm 6de9e229aa4cc7c3131ff855f3ead39581127090.tar.gz +G_EXEC tar xf master.tar.gz +G_EXEC rm master.tar.gz G_DIETPI-NOTIFY 2 'Compiling binary...' -G_EXEC mv squeezelite-{6de9e229aa4cc7c3131ff855f3ead39581127090,master} G_EXEC cd squeezelite-master G_EXEC_OUTPUT=1 G_EXEC make CFLAGS='-g0 -O3' OPTS='-DDSD -DFFMPEG -DRESAMPLE -DVISEXPORT -DLINKALL -DIR -DUSE_SSL' G_EXEC strip --remove-section=.comment --remove-section=.note squeezelite diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index 927f7ed6c9..f8f0ad85cd 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -2290,14 +2290,14 @@ NB: All Ethernet connections will be temporarily dropped!' && Network_ApplyChang do if (( $i < $full_octets )) then - mask+=255 + mask+='255' elif (( $i == $full_octets )) then mask+=$(( 256 - 2 ** ( 8 - $partial_octet ) )) else - mask+=0 + mask+='0' fi (( $i < 3 )) && mask+=. done diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 2329e4a618..38107abeeb 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -14572,13 +14572,13 @@ _EOF_ do if (( $i < $full_octets )) then - mask+=255 + mask+='255' elif (( $i == $full_octets )) then mask+=$(( 256 - 2 ** ( 8 - $partial_octet ) )) else - mask+=0 + mask+='0' fi (( $i < 3 )) && mask+=. done From 187a21f8dc7bcd8393ee0de79a72d15da5e3ded1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 9 Mar 2024 16:21:26 +0100 Subject: [PATCH 069/266] v9.2 - DietPi-Software | VNC server: Restructure code a little --- dietpi/dietpi-software | 56 ++++++++++++++++++++++++------------------ 1 file changed, 32 insertions(+), 24 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 38107abeeb..98fe62702b 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -7107,7 +7107,7 @@ _EOF_ G_AGI realvnc-vnc-server libraspberrypi0 # Depends on libbcm_host.so but does not pull libraspberrypi0 as dependency fi - # TigerVNC/RealVNC Server - Shared setup + # TigerVNC/RealVNC Server: Shared setup if (( ${aSOFTWARE_INSTALL_STATE[28]} == 1 || ${aSOFTWARE_INSTALL_STATE[120]} == 1 )) then # Service @@ -7131,9 +7131,6 @@ WantedBy=multi-user.target _EOF_ aSTART_SERVICES+=('vncserver') - # RealVNC: Assure that its services are disabled when ours is enabled - (( ${aSOFTWARE_INSTALL_STATE[120]} == 1 )) && G_EXEC systemctl --no-reload disable vncserver-virtuald vncserver-x11-serviced - cat << '_EOF_' > /usr/local/bin/vncserver #!/bin/dash @@ -7147,8 +7144,7 @@ elif [ -f '/usr/bin/tigervncserver' ] then echo '[ OK ] TigerVNC detected' FP_BINARY='/usr/bin/tigervncserver' - [ -f '/usr/bin/X0tigervnc' ] && FP_SHARED='/usr/bin/X0tigervnc' || FP_SHARED='/usr/bin/x0tigervncserver' - FP_SHARED="$FP_SHARED -display :0 -rfbauth $HOME/.vnc/passwd" + FP_SHARED="/usr/bin/X0tigervnc -display :0 -rfbauth $HOME/.vnc/passwd" else echo '[FAILED] No supported VNC server installed' exit 1 @@ -7177,9 +7173,9 @@ case "$1" in WIDTH=$(sed -n '/^[[:blank:]]*SOFTWARE_VNCSERVER_WIDTH=/{s/^[^=]*=//p;q}' /boot/dietpi.txt) HEIGHT=$(sed -n '/^[[:blank:]]*SOFTWARE_VNCSERVER_HEIGHT=/{s/^[^=]*=//p;q}' /boot/dietpi.txt) DEPTH=$(sed -n '/^[[:blank:]]*SOFTWARE_VNCSERVER_DEPTH=/{s/^[^=]*=//p;q}' /boot/dietpi.txt) - echo "[ INFO ] Starting virtual desktop at display :${DISPLAY:-1} in ${WIDTH:-1280}x${HEIGHT:-720}x${DEPTH:-16}" + echo "[ INFO ] Starting virtual desktop at display :${DISPLAY:=1} in ${WIDTH:=1280}x${HEIGHT:=720}x${DEPTH:=16}" export SHELL='/bin/bash' - exec $FP_BINARY ":${DISPLAY:-1}" -geometry "${WIDTH:-1280}x${HEIGHT:-720}" -depth "${DEPTH:-16}" + exec $FP_BINARY ":$DISPLAY" -geometry "${WIDTH}x$HEIGHT" -depth "$DEPTH" fi ;; @@ -7188,13 +7184,13 @@ case "$1" in if grep -q '^[[:blank:]]*SOFTWARE_VNCSERVER_SHARE_DESKTOP=1' /boot/dietpi.txt then echo '[ INFO ] Disconnecting from shared desktop' - killall -qw vncserver-x11-core x0tigervncserver X0tigervnc + killall -qw vncserver-x11-core X0tigervnc # Virtual desktop mode else DISPLAY=$(sed -n '/^[[:blank:]]*SOFTWARE_VNCSERVER_DISPLAY_INDEX=/{s/^[^=]*=//p;q}' /boot/dietpi.txt) - echo "[ INFO ] Stopping virtual desktop at display :${DISPLAY:-1}" - $FP_BINARY -kill ":${DISPLAY:-1}" + echo "[ INFO ] Stopping virtual desktop at display :${DISPLAY:=1}" + $FP_BINARY -kill ":$DISPLAY" fi ;; @@ -7209,26 +7205,38 @@ exit 0 _EOF_ G_EXEC chmod +x /usr/local/bin/vncserver - # TigerVNC: Permit remote connections which implies TLSVnc authentications being enabled additionally - # shellcheck disable=SC2016 - (( ${aSOFTWARE_INSTALL_STATE[28]} == 1 )) && GCI_PRESERVE=1 G_CONFIG_INJECT '\$localhost[[:blank:]]*=' '$localhost = "no";' /etc/tigervnc/vncserver-config-defaults - - # TigerVNC: Set control + read-only passwords - if [[ ${aSOFTWARE_INSTALL_STATE[28]} == 1 && ! -f '/root/.vnc/passwd' ]] + # TigerVNC + if (( ${aSOFTWARE_INSTALL_STATE[28]} == 1 )) then - G_EXEC mkdir -p /root/.vnc - tigervncpasswd -f <<< "$GLOBAL_PW + # TigerVNC: Permit remote connections which implies TLSVnc authentications being enabled additionally + # shellcheck disable=SC2016 + GCI_PRESERVE=1 G_CONFIG_INJECT '\$localhost[[:blank:]]*=' '$localhost = "no";' /etc/tigervnc/vncserver-config-defaults + + # Set control + read-only passwords + if [[ ! -f '/root/.vnc/passwd' ]] + then + G_EXEC mkdir -p /root/.vnc + tigervncpasswd -f <<< "$GLOBAL_PW $GLOBAL_PW" > /root/.vnc/passwd - G_EXEC chmod 600 /root/.vnc/passwd + G_EXEC chmod 600 /root/.vnc/passwd + fi fi - # RealVNC: Set virtual + shared desktop passwords, repeat virtual password command two times: https://github.com/MichaIng/DietPi/pull/4679#issuecomment-908196511 - if [[ ${aSOFTWARE_INSTALL_STATE[120]} == 1 && ! -s '/root/.vnc/config.d/Xvnc' ]] + # RealVNC + if (( ${aSOFTWARE_INSTALL_STATE[120]} == 1 )) then - vncpasswd -virtual <<< "$GLOBAL_PW + # Assure that its services are disabled when ours is enabled + G_EXEC systemctl --no-reload disable vncserver-virtuald vncserver-x11-serviced + + # Set (+verify) virtual + shared desktop passwords: https://github.com/MichaIng/DietPi/pull/4679#issuecomment-908196511 + if [[ ! -s '/root/.vnc/config.d/Xvnc' ]] + then + vncpasswd -virtual <<< "$GLOBAL_PW $GLOBAL_PW" - vncpasswd -service <<< "$GLOBAL_PW + vncpasswd -service <<< "$GLOBAL_PW $GLOBAL_PW" + fi + [[ -f '/root/.vnc/config.d/.Xvnc-v5-marker' ]] || > /root/.vnc/config.d/.Xvnc-v5-marker fi fi From fec381841c696449a0d747b7624ea7f9b0fbee33 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 9 Mar 2024 17:10:06 +0100 Subject: [PATCH 070/266] v9.2 - META | Remove live patches from dev --- .update/version | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.update/version b/.update/version index 0ce5df534a..83d5135338 100644 --- a/.update/version +++ b/.update/version @@ -14,6 +14,6 @@ G_MIN_DEBIAN=6 # Alternative Git branch to automatically migrate to when Debian version is too low G_OLD_DEBIAN_BRANCH='8' # Live patches -G_LIVE_PATCH_DESC=('Fix Nextcloud Nginx config, serving wrong MIME types') -G_LIVE_PATCH_COND=('[[ -f /etc/nginx/sites-dietpi/dietpi-nextcloud.conf ]] && ! grep -q '\''include mime.types;'\'' /etc/nginx/sites-dietpi/dietpi-nextcloud.conf') -G_LIVE_PATCH=('sed -i '\''/types {/i\\tinclude mime.types;'\'' /etc/nginx/sites-dietpi/dietpi-nextcloud.conf; systemctl -q is-active nginx && systemctl restart nginx') +G_LIVE_PATCH_DESC=() +G_LIVE_PATCH_COND=() +G_LIVE_PATCH=() From c5a28f15fdf9b7e0560da4f8f95f1da2728dbefc Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 9 Mar 2024 20:28:53 +0100 Subject: [PATCH 071/266] v9.2 - CI | vaultwarden: Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 --- .build/software/vaultwarden/build.bash | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.build/software/vaultwarden/build.bash b/.build/software/vaultwarden/build.bash index b141a2314d..ce68c4bc55 100755 --- a/.build/software/vaultwarden/build.bash +++ b/.build/software/vaultwarden/build.bash @@ -11,7 +11,8 @@ G_AGUP G_AGDUG "${adeps_build[@]}" for i in "${adeps[@]}" do - dpkg-query -s "$i" &> /dev/null && continue + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || dpkg-query -s "${i}t64" &> /dev/null && continue G_DIETPI-NOTIFY 1 "Expected dependency package was not installed: $i" exit 1 done @@ -205,6 +206,8 @@ find "$DIR" ! \( -path "$DIR/DEBIAN" -prune \) -type f -exec md5sum {} + | sed " DEPS_APT_VERSIONED= for i in "${adeps[@]}" do + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || i+='t64' DEPS_APT_VERSIONED+=" $i (>= $(dpkg-query -Wf '${VERSION}' "$i"))," done DEPS_APT_VERSIONED=${DEPS_APT_VERSIONED%,} From cff6c017088e338755f405b2e9723c4c9c5ca7d2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 9 Mar 2024 23:29:39 +0100 Subject: [PATCH 072/266] v9.2 - DietPi-Patches | Move forward RISC-V kernel updates --- .update/patches | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/.update/patches b/.update/patches index 889d67ed2c..155255725e 100755 --- a/.update/patches +++ b/.update/patches @@ -1484,22 +1484,6 @@ Patch_9_1() G_EXEC rm package.deb break done - - # VisionFive 2 - elif (( $G_HW_MODEL == 81 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-visionfive2 2> /dev/null)" lt-nl 6.1.78-dietpi1 - then - G_DIETPI-NOTIFY 2 'Updating RISC-V StarFive VisionFive 2 kernel ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-visionfive2.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb - - # Star64 - elif (( $G_HW_MODEL == 84 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-star64 2> /dev/null)" lt-nl 6.1.78-dietpi1 - then - G_DIETPI-NOTIFY 2 'Updating RISC-V PINE64 Star64 kernel ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-star64.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb fi # Software updates and migrations @@ -1581,6 +1565,22 @@ Patch_9_2() dpkg-query -s 'linux-headers-current-rockchip64' &> /dev/null && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package4.deb 'https://dietpi.com/downloads/binaries/linux-headers-current-rockchip64.deb'; headers=('package4.deb'); } G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package1.deb package2.deb package3.deb "${headers[@]}" G_EXEC rm package1.deb package2.deb package3.deb "${headers[@]}" + + # VisionFive 2 + elif (( $G_HW_MODEL == 81 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-visionfive2 2> /dev/null)" lt-nl 6.1.81-dietpi1 + then + G_DIETPI-NOTIFY 2 'Updating RISC-V StarFive VisionFive 2 kernel ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-visionfive2.deb' + G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb + G_EXEC rm package.deb + + # Star64 + elif (( $G_HW_MODEL == 84 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-star64 2> /dev/null)" lt-nl 6.1.81-dietpi1 + then + G_DIETPI-NOTIFY 2 'Updating RISC-V PINE64 Star64 kernel ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-star64.deb' + G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb + G_EXEC rm package.deb fi # Software updates and migrations From 7eaa07326ef73249859428481cd8a5b50968e0ea Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 9 Mar 2024 23:54:27 +0100 Subject: [PATCH 073/266] v9.2 - DietPi-Patches | Move forward further updates --- .update/patches | 75 ++++++++++++++++++++++++------------------------- 1 file changed, 37 insertions(+), 38 deletions(-) diff --git a/.update/patches b/.update/patches index 155255725e..a5cc3f36b4 100755 --- a/.update/patches +++ b/.update/patches @@ -1472,20 +1472,6 @@ Patch_9_1() G_EXEC rm /etc/kernel/postinst.d/dietpi-USBridgeSig fi - # Quartz64 - if (( $G_HW_MODEL == 49 )) - then - for i in quartz64{a,b} soquartz - do - dpkg --compare-versions "$(dpkg-query -Wf '${Version}' "firmware-$i" 2> /dev/null)" lt-nl 6.7.4-dietpi1 || continue - G_DIETPI-NOTIFY 2 "Updating $i kernel and bootloader ..." - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/firmware-$i.deb" - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb - break - done - fi - # Software updates and migrations if [[ -f '/boot/dietpi/.installed' ]] then @@ -1519,36 +1505,12 @@ map $arg_v $asset_immutable { G_EXEC sed -i "s|, reboot, poweroff|, $(which reboot), $(which poweroff)|" /etc/sudoers.d/octoprint fi - # Squeezelite - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' squeezelite 2> /dev/null)" lt 2.0.0-1465-dietpi1 - then - G_DIETPI-NOTIFY 2 'Updating Squeezelite package ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/squeezelite_$G_HW_ARCH_NAME.deb" - G_AGI ./package.deb - G_EXEC rm package.deb - fi - # Amiberry if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[108\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' amiberry 2> /dev/null)" lt 5.6.6-dietpi1 then G_DIETPI-NOTIFY 2 'Preparing Amiberry upgrade to v5.6.6, including migration for RPi systems from fake KMS DispmanX to full KMS SDL2 graphics backend' echo 108 >> /var/tmp/dietpi/dietpi-update_reinstalls fi - - # vaultwarden - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[183\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' vaultwarden 2> /dev/null)" lt 1.30.3-dietpi2 - then - # Pre-v8.7 cleanup - if [[ -f '/opt/vaultwarden/target/release/vaultwarden' ]] - then - G_EXEC rm -R /opt/vaultwarden - [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service - fi - G_DIETPI-NOTIFY 2 'Updating vaultwarden package ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" - G_AGI ./package.deb - G_EXEC rm package.deb - fi fi } @@ -1566,6 +1528,19 @@ Patch_9_2() G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package1.deb package2.deb package3.deb "${headers[@]}" G_EXEC rm package1.deb package2.deb package3.deb "${headers[@]}" + # Quartz64 + elif (( $G_HW_MODEL == 49 )) + then + for i in quartz64{a,b} soquartz + do + dpkg --compare-versions "$(dpkg-query -Wf '${Version}' "firmware-$i" 2> /dev/null)" lt-nl 6.7.4-dietpi1 || continue + G_DIETPI-NOTIFY 2 "Updating $i kernel and bootloader ..." + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/firmware-$i.deb" + G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb + G_EXEC rm package.deb + break + done + # VisionFive 2 elif (( $G_HW_MODEL == 81 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-visionfive2 2> /dev/null)" lt-nl 6.1.81-dietpi1 then @@ -1608,6 +1583,30 @@ Patch_9_2() G_EXEC sed -i 's/^auth-type: floodgate/ auth-type: floodgate/' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml fi fi + + # Squeezelite + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' squeezelite 2> /dev/null)" lt 2.0.0-1468-dietpi1 + then + G_DIETPI-NOTIFY 2 'Updating Squeezelite package ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/squeezelite_$G_HW_ARCH_NAME.deb" + G_AGI ./package.deb + G_EXEC rm package.deb + fi + + # vaultwarden + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[183\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' vaultwarden 2> /dev/null)" lt 1.30.5-dietpi1 + then + # Pre-v8.7 cleanup + if [[ -f '/opt/vaultwarden/target/release/vaultwarden' ]] + then + G_EXEC rm -R /opt/vaultwarden + [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service + fi + G_DIETPI-NOTIFY 2 'Updating vaultwarden package ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" + G_AGI ./package.deb + G_EXEC rm package.deb + fi fi } From 7be541e5512a0b6ae649e08d3f07140219e11e78 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 10 Mar 2024 00:18:47 +0100 Subject: [PATCH 074/266] v9.2 - DietPi-Config | Fix and simplify journalctl handling when restarting network connections: Job control messages are not printed within scripts, hence no need to wrap everything in command blocks and mute STDERR. SIGINT somehow does not work in this script to kill journalctl, while it does work from console. Hence use SIGTERM, which does work. --- dietpi/dietpi-config | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index f8f0ad85cd..e93be67e13 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -1936,18 +1936,18 @@ If unsure, set any value, 'Ondemand Down Factor' option on the next screen will # - Ethernet if (( ! $ETH_DISABLED )) then - { journalctl -fn 0 -u "ifup@$ETH_DEV_IFACE" & } 2> /dev/null + journalctl -fn 0 -u "ifup@$ETH_DEV_IFACE" & G_EXEC_NOHALT=1 G_EXEC_OUTPUT=1 G_EXEC systemctl restart "ifup@$ETH_DEV_IFACE" - { kill -2 %% && wait; } 2> /dev/null + kill -15 %% else ifdown --force "$ETH_DEV_IFACE" 2> /dev/null fi # - WiFi: Only try to configure if this is either a hotspot or an SSID has been configured if (( ! $WIFI_DISABLED )) && { (( $WIFI_HOTSPOT )) || grep -q '^network=' /etc/wpa_supplicant/wpa_supplicant.conf; } then - { journalctl -fn 0 -u "ifup@$WIFI_DEV_IFACE" & } 2> /dev/null + journalctl -fn 0 -u "ifup@$WIFI_DEV_IFACE" & G_EXEC_NOHALT=1 G_EXEC_OUTPUT=1 G_EXEC systemctl restart "ifup@$WIFI_DEV_IFACE" - { kill -2 %% && wait; } 2> /dev/null + kill -15 %% else ifdown --force "$WIFI_DEV_IFACE" 2> /dev/null fi From 0d9449b74216c63d2d6ccbc3d0f4bd5b2c187113 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 10 Mar 2024 00:46:44 +0100 Subject: [PATCH 075/266] v9.2 - DietPi-Globals | Fix concurrency check: Consider PIDs of shells running a matching script name, and correctly invert logic to remove stale working dir --- dietpi/func/dietpi-globals | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index c20287082d..cfbfac578f 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -108,7 +108,7 @@ G_GITOWNER='$G_GITOWNER'" > /boot/dietpi/.version while [[ -d $G_WORKING_DIR ]] do # SIGKILL prevents the exit trap from removing this dir. Remove it in this case and proceed. - [[ $(pidof "$0") == *' '* ]] && { rm -R "$G_WORKING_DIR"; break; } + [[ $(pidof -x "$0") == *' '* ]] || { rm -R "$G_WORKING_DIR"; break; } if (( $i < $G_INIT_WAIT_CONCURRENT )) then ((i++)) From 62d8e7e1d5d5e9e21d0d7a94de72cfb386342f92 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 10 Mar 2024 00:53:08 +0100 Subject: [PATCH 076/266] v9.2 - RC up --- .update/version | 2 +- dietpi/func/dietpi-globals | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.update/version b/.update/version index 83d5135338..85c98a4951 100644 --- a/.update/version +++ b/.update/version @@ -3,7 +3,7 @@ # Available DietPi version G_REMOTE_VERSION_CORE=9 G_REMOTE_VERSION_SUB=2 -G_REMOTE_VERSION_RC=-1 +G_REMOTE_VERSION_RC=0 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index cfbfac578f..76d0b380f3 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -55,7 +55,7 @@ # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=2 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=-1 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=0 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From 5d1d7987a3f8ee409173f68ade9e337e8a34c3ae Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 10 Mar 2024 00:56:54 +0100 Subject: [PATCH 077/266] v9.2 - CHANGELOG | LXQt: Resolved an issue where the installation failed on Trixie and RISC-V systems, since we did not host a config archive for those Debian versions yet. Many thanks to @jtmoon79 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6939 --- CHANGELOG.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 5d481cf221..388c25b22c 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -12,6 +12,7 @@ Bug fixes: - DietPi-Software | Nextcloud: Resolved an issue with the updated Nginx config where assets were served with the wrong MIME type. This fix was backported to v9.1 and a live patch offered. Many thanks to @howardroark for reporting this issue: https://dietpi.com/forum/t/nextcloud-theme-broken-after-upgrade-v9-1-1/19372 - DietPi-Software | Home Assistant: Resolved an issue on x86_64 and ARMv8 systems where some core integrations did not work if no C++ compiler was installed. If you are affected by this, "apt install g++ && systemctl restart home-assistant" will fix it. Many thanks to @pdsakurai for fixing this issue in our install code: https://github.com/MichaIng/DietPi/pull/6931 - DietPi-Software | DarkIce: Resolved an issue where the service failed to start due to false config file permissions. +- DietPi-Software | LXQt: Resolved an issue where the installation failed on Trixie and RISC-V systems, since we did not host a config archive for those Debian versions yet. Many thanks to @jtmoon79 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6939 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME From 6beb0c91defd8464f16afd3f975c4bff7b8272a8 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 10 Mar 2024 15:39:38 +0100 Subject: [PATCH 078/266] v9.2 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 98fe62702b..857792622a 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10088,7 +10088,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.19.2437/Readarr.develop.0.3.19.2437.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.20.2452/Readarr.develop.0.3.20.2452.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Readarr/Readarr/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}" | head -1)" G_EXEC mv Readarr /opt/readarr fi @@ -11584,7 +11584,7 @@ _EOF_ *) local arch='amd64';; esac - local fallback_url="https://github.com/rclone/rclone/releases/download/v1.65.2/rclone-v1.65.2-linux-$arch.deb" + local fallback_url="https://github.com/rclone/rclone/releases/download/v1.66.0/rclone-v1.66.0-linux-$arch.deb" Download_Install "$(curl -sSfL 'https://api.github.com/repos/rclone/rclone/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/rclone-v[^\"\/]*-linux-$arch.deb\"$/{print \$4}")" fi fi @@ -11598,7 +11598,7 @@ _EOF_ *) local arch='arm';; esac - local fallback_url="https://github.com/restic/restic/releases/download/v0.15.2/restic_0.15.2_linux_$arch.bz2" + local fallback_url="https://github.com/restic/restic/releases/download/v0.16.4/restic_0.16.4_linux_$arch.bz2" Download_Install "$(curl -sSfL 'https://api.github.com/repos/restic/restic/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/restic_[^\"\/]*_linux_$arch\.bz2\"$/{print \$4}")" /usr/local/bin/restic G_EXEC chmod +x /usr/local/bin/restic fi From 8b0e13180d90c5c941063a2de468c77979a389c2 Mon Sep 17 00:00:00 2001 From: JappeHallunken Date: Sun, 10 Mar 2024 18:06:58 +0100 Subject: [PATCH 079/266] v9.2 (#6940) - META | Simplify branch switch instructions, using `G_DEV_BRANCH `, which implies changing the `dietpi.txt` setting as well as applying the update right away --- BRANCH_SYSTEM.md | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/BRANCH_SYSTEM.md b/BRANCH_SYSTEM.md index 57c7836b22..d67502152b 100644 --- a/BRANCH_SYSTEM.md +++ b/BRANCH_SYSTEM.md @@ -14,12 +14,11 @@ By joining the Beta and reporting issues, you will be assisting DietPi (and all 1. Recommended: Backup your system with `dietpi-backup` (or backup quickly with `dietpi-backup 1`). 2. Run the following command to switch to "beta" branch: ```sh - G_CONFIG_INJECT 'DEV_GITBRANCH=' 'DEV_GITBRANCH=beta' /boot/dietpi.txt + G_DEV_BRANCH beta ``` -3. Run `dietpi-update` to update the system, then reboot (or update quickly with `dietpi-update 1`). -4. Test away, please report any issues on our GitHub page. Also ensure you mention "beta branch" in your post: https://github.com/MichaIng/DietPi/issues -5. If you want to return the system to the previous restore state, run `dietpi-backup` to restore (or restore quickly with `dietpi-backup -1`). +3. Test away, please report any issues on our GitHub page. Also ensure you mention "beta branch" in your post: https://github.com/MichaIng/DietPi/issues +4. If you want to return the system to the previous restore state, run `dietpi-backup` to restore (or restore quickly with `dietpi-backup -1`). ## Steps to use the DietPi "dev" branch #### This is the active development branch. It is potentially unstable, unsupported and should not be used by end users. -1. Same as above, however, use `DEV_GITBRANCH=dev` instead. +1. Same as above, however, use `G_DEV_BRANCH dev` instead. From bc4c63cdc37ba9865ff1a3a98f5f360eecf26a00 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 10 Mar 2024 22:25:51 +0100 Subject: [PATCH 080/266] v9.2 - CHANGELOG | Add v9.2 release PR and correctly sort solved R4S issue below bug fixes --- CHANGELOG.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 388c25b22c..eb0927320b 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,10 +2,10 @@ v9.2 (2024-03-16) Enhancements: -- NanoPi R4S | Resolved an issue where Ethernet adapter of the "LAN" port could disappear after a soft reboot. Many thanks to @idaanx for reporting this issue: https://github.com/MichaIng/DietPi/issues/6342 - DietPi-Software | It is now possible to run "dietpi-software list" concurrent to other dietpi-software instances, and as non-root user. This avoids an issue in DietPi-Dashboard, where opening dietpi-software in the Terminal and switching to the Software page, caused an infinite hang. Bug fixes: +- NanoPi R4S | Resolved an issue where Ethernet adapter of the "LAN" port could disappear after a soft reboot. Many thanks to @idaanx for reporting this issue: https://github.com/MichaIng/DietPi/issues/6342 - DietPi-Globals | Resolved an issue where a concurrent DietPi script detection could have prevented the start of a script, if a previous instance was killed via SIGKILL. - DietPi-Config | Resolved an issue where a WiFi connection, configured for the first time via dietpi-config from a local terminal session, was automatically stopped when exiting or logging out from the terminal session. - DietPi-Software | PaperMC: Resolved an issue where installing the Geyser and Floodgate plugins failed due to changed download URLs, and a false syntax in the Geyser config file. Many thanks to @boterocamilo for reporting this issue: https://github.com/MichaIng/DietPi/issues/6898 @@ -14,7 +14,7 @@ Bug fixes: - DietPi-Software | DarkIce: Resolved an issue where the service failed to start due to false config file permissions. - DietPi-Software | LXQt: Resolved an issue where the installation failed on Trixie and RISC-V systems, since we did not host a config archive for those Debian versions yet. Many thanks to @jtmoon79 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6939 -As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME +As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/6955 ----------------------------------------------------------------------------------------------------------- From 235e755b6ed51105419a7b8635b025b62e47b737 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 12 Mar 2024 19:35:25 +0100 Subject: [PATCH 081/266] v9.2 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 857792622a..a48a9bc1ac 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6501,7 +6501,7 @@ _EOF_ esac # Download - local fallback_url="https://github.com/fatedier/frp/releases/download/v0.54.0/frp_0.54.0_linux_$arch.tar.gz" + local fallback_url="https://github.com/fatedier/frp/releases/download/v0.55.1/frp_0.55.1_linux_$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/fatedier/frp/releases/latest' | mawk -F\" "/\"browser_download_url\": .*\/frp_[0-9.]*_linux_$arch\.tar\.gz\"/{print \$4}")" G_EXEC cd frp_* @@ -7425,7 +7425,7 @@ _EOF_ then Download_Install 'https://github.com/gotson/komga/releases/download/v0.165.0/komga-0.165.0.jar' /mnt/dietpi_userdata/komga/komga.jar else - local fallback_url='https://github.com/gotson/komga/releases/download/1.10.3/komga-1.10.3.jar' + local fallback_url='https://github.com/gotson/komga/releases/download/1.10.4/komga-1.10.4.jar' Download_Install "$(curl -sSfL 'https://api.github.com/repos/gotson/komga/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/komga-[^"\/]*\.jar"$/{print $4}')" /mnt/dietpi_userdata/komga/komga.jar fi From 4a1e0bf84868884e9a41bed016d8febcccfa96f1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 14 Mar 2024 17:41:48 +0100 Subject: [PATCH 082/266] v9.2 - DietPi-Software | Docker: Remove docker.io package on uninstall, installed on RISC-V (the Debian variant of the Docker package), and skip the non-existing/ancient docker-engine package instead --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index a48a9bc1ac..d8a0aaaaeb 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -13676,7 +13676,7 @@ _EOF_ Remove_Service docker # Packages, repo and key - G_AGP docker-ce docker-ce-cli docker-engine + G_AGP docker-ce docker-ce-cli docker.io [[ -f '/etc/apt/sources.list.d/docker.list' ]] && G_EXEC rm /etc/apt/sources.list.d/docker.list [[ -f '/etc/apt/trusted.gpg.d/dietpi-docker.gpg' ]] && G_EXEC rm /etc/apt/trusted.gpg.d/dietpi-docker.gpg From 0dac52bd63743da339bf7e4b3195a762311c6323 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 17 Mar 2024 02:18:46 +0100 Subject: [PATCH 083/266] v9.2 - DietPi-Patches | Bump Amiberry to v5.6.8 - DietPi-Software | Gogs/Gitea: Using repositories via SSH should now work OOTB with new installs and reinstalls. If pull or push operations via SSH fail in your case, try to give the respective user a default shell: "sudo usermod -s /bin/dash gogs" respectively "sudo usermod -s /bin/dash gitea". This is now included in our default setup. Many thanks to @din14970 for reporting this missing feature: https://github.com/MichaIng/DietPi/discussions/6964#discussioncomment-8813390 - DietPi-Config | Resolved an issue on RPi systems, where HDMI audio did not work if full KMS was enabled. The firmware/bcm2835 HDMI audio driver conflicts with the full KMS display driver, hence the VC4 HDMI driver needs to be used instead. That one however only supports the IEC958 audio format, which requires a complex ALSA config. This config is shipped with the "libasound2-data" package of the RPi APT repository, but it was overwritten by our /etc/asound.conf. For HDMI audio to work with KMS, the "default" or "sysdefault" ALSA PCM needs to be used by players. This is usually the case, but some allow to select a specific sound card, in which case the ALSA config and plugin for IEC958 conversion is bypassed, breaking HDMI audio. Many thanks to `@Lollly2997` for reporting this issue. We are working with Amiberry on a solution for Amiberry in particular. This fix is for the underlying system level: https://dietpi.com/forum/t/19568 --- .update/patches | 14 ++-- .update/version | 2 +- CHANGELOG.txt | 2 + dietpi/dietpi-software | 130 ++++++++++++++++---------------- dietpi/func/dietpi-globals | 2 +- dietpi/func/dietpi-set_hardware | 59 +++++++++------ 6 files changed, 110 insertions(+), 99 deletions(-) diff --git a/.update/patches b/.update/patches index a5cc3f36b4..737025bc6d 100755 --- a/.update/patches +++ b/.update/patches @@ -1504,13 +1504,6 @@ map $arg_v $asset_immutable { # shellcheck disable=SC2230 G_EXEC sed -i "s|, reboot, poweroff|, $(which reboot), $(which poweroff)|" /etc/sudoers.d/octoprint fi - - # Amiberry - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[108\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' amiberry 2> /dev/null)" lt 5.6.6-dietpi1 - then - G_DIETPI-NOTIFY 2 'Preparing Amiberry upgrade to v5.6.6, including migration for RPi systems from fake KMS DispmanX to full KMS SDL2 graphics backend' - echo 108 >> /var/tmp/dietpi/dietpi-update_reinstalls - fi fi } @@ -1607,6 +1600,13 @@ Patch_9_2() G_AGI ./package.deb G_EXEC rm package.deb fi + + # Amiberry + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[108\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' amiberry 2> /dev/null)" lt 5.6.8-dietpi1 + then + G_DIETPI-NOTIFY 2 'Preparing Amiberry upgrade to v5.6.6, including migration for RPi systems from fake KMS DispmanX to full KMS SDL2 graphics backend' + echo 108 >> /var/tmp/dietpi/dietpi-update_reinstalls + fi fi } diff --git a/.update/version b/.update/version index 85c98a4951..a19ad9e36f 100644 --- a/.update/version +++ b/.update/version @@ -3,7 +3,7 @@ # Available DietPi version G_REMOTE_VERSION_CORE=9 G_REMOTE_VERSION_SUB=2 -G_REMOTE_VERSION_RC=0 +G_REMOTE_VERSION_RC=1 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/CHANGELOG.txt b/CHANGELOG.txt index eb0927320b..4d48b35539 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -3,11 +3,13 @@ v9.2 Enhancements: - DietPi-Software | It is now possible to run "dietpi-software list" concurrent to other dietpi-software instances, and as non-root user. This avoids an issue in DietPi-Dashboard, where opening dietpi-software in the Terminal and switching to the Software page, caused an infinite hang. +- DietPi-Software | Gogs/Gitea: Using repositories via SSH should now work OOTB with new installs and reinstalls. If pull or push operations via SSH fail in your case, try to give the respective user a default shell: "sudo usermod -s /bin/dash gogs" respectively "sudo usermod -s /bin/dash gitea". This is now included in our default setup. Many thanks to @din14970 for reporting this missing feature: https://github.com/MichaIng/DietPi/discussions/6964#discussioncomment-8813390 Bug fixes: - NanoPi R4S | Resolved an issue where Ethernet adapter of the "LAN" port could disappear after a soft reboot. Many thanks to @idaanx for reporting this issue: https://github.com/MichaIng/DietPi/issues/6342 - DietPi-Globals | Resolved an issue where a concurrent DietPi script detection could have prevented the start of a script, if a previous instance was killed via SIGKILL. - DietPi-Config | Resolved an issue where a WiFi connection, configured for the first time via dietpi-config from a local terminal session, was automatically stopped when exiting or logging out from the terminal session. +- DietPi-Config | Resolved an issue on RPi systems, where HDMI audio did not work if full KMS was enabled. The firmware/bcm2835 HDMI audio driver conflicts with the full KMS display driver, hence the VC4 HDMI driver needs to be used instead. That one however only supports the IEC958 audio format, which requires a complex ALSA config. This config is shipped with the "libasound2-data" package of the RPi APT repository, but it was overwritten by our /etc/asound.conf. For HDMI audio to work with KMS, the "default" or "sysdefault" ALSA PCM needs to be used by players. This is usually the case, but some allow to select a specific sound card, in which case the ALSA config and plugin for IEC958 conversion is bypassed, breaking HDMI audio. Many thanks to @Lollly2997 for reporting this issue. We are working with Amiberry on a solution for Amiberry in particular. This fix is for the underlying system level: https://dietpi.com/forum/t/19568 - DietPi-Software | PaperMC: Resolved an issue where installing the Geyser and Floodgate plugins failed due to changed download URLs, and a false syntax in the Geyser config file. Many thanks to @boterocamilo for reporting this issue: https://github.com/MichaIng/DietPi/issues/6898 - DietPi-Software | Nextcloud: Resolved an issue with the updated Nginx config where assets were served with the wrong MIME type. This fix was backported to v9.1 and a live patch offered. Many thanks to @howardroark for reporting this issue: https://dietpi.com/forum/t/nextcloud-theme-broken-after-upgrade-v9-1-1/19372 - DietPi-Software | Home Assistant: Resolved an issue on x86_64 and ARMv8 systems where some core integrations did not work if no C++ compiler was installed. If you are affected by this, "apt install g++ && systemctl restart home-assistant" will fix it. Many thanks to @pdsakurai for fixing this issue in our install code: https://github.com/MichaIng/DietPi/pull/6931 diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index d8a0aaaaeb..a1cc12d8bf 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -7521,7 +7521,7 @@ _EOF_ local json=() [[ $PHP_VERSION == 8* ]] || aDEPS+=("php$PHP_VERSION-json") json=('json') - local fallback_url="https://github.com/ampache/ampache/releases/download/6.2.1/ampache-6.2.1_all_php$PHP_VERSION.zip" + local fallback_url="https://github.com/ampache/ampache/releases/download/6.3.0/ampache-6.3.0_all_php$PHP_VERSION.zip" Download_Install "$(curl -sSfL 'https://api.github.com/repos/ampache/ampache/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/ampache-[0-9\.]*_all_php$PHP_VERSION.zip\"$/{print \$4}")" ampache # Reinstall: Preserve configs from old and new paths @@ -8401,68 +8401,6 @@ Environment="SHELL=/bin/bash" "HOME=/root" ExecStart=$(command -v node) webui.js KillMode=process -[Install] -WantedBy=multi-user.target -_EOF_ - fi - - if To_Install 49 gogs # Gogs - then - # ARMv6/RISC-V: No pre-compiled binaries available, so we host our own. - if (( $G_HW_ARCH == 1 || $G_HW_ARCH == 11 )) - then - local url="https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/gogs_$G_HW_ARCH_NAME.7z" - - # Else install latest binaries from GitHub - else - case $G_HW_ARCH in - 2) local arch='armv7';; - 3) local arch='armv8';; - *) local arch='amd64';; - esac - - local fallback_url="https://github.com/gogs/gogs/releases/download/v0.13.0/gogs_0.13.0_linux_$arch.tar.gz" - local url=$(curl -sSfL 'https://api.github.com/repos/gogs/gogs/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/gogs_[^\"\/]*_linux_$arch.tar.gz\"$/{print \$4}") - fi - - Download_Install "$url" - G_EXEC mkdir -p /etc/gogs - G_EXEC mv gogs/gogs /etc/gogs/gogs - G_EXEC rm -R gogs - - # Pre-v8.14: Remove unnecessary init scripts - [[ -d '/etc/gogs/scripts' ]] && G_EXEC rm -R /etc/gogs/scripts - - # User - Create_User -d /etc/gogs gogs - - # Directories + permissions - G_EXEC mkdir -p /mnt/dietpi_userdata/gogs-repo - G_EXEC chown -R gogs:gogs /etc/gogs /mnt/dietpi_userdata/gogs-repo - - # Database - /boot/dietpi/func/create_mysql_db gogs gogs "$GLOBAL_PW" - - # Service: https://github.com/gogs/gogs/blob/main/scripts/systemd/gogs.service - cat << '_EOF_' > /etc/systemd/system/gogs.service -[Unit] -Description=Gogs (DietPi) -Wants=network-online.target -After=network-online.target mariadb.service - -[Service] -User=gogs -LogsDirectory=gogs -WorkingDirectory=/etc/gogs -ExecStart=/etc/gogs/gogs web - -# Hardening -ProtectSystem=full -PrivateDevices=yes -PrivateTmp=yes -NoNewPrivileges=true -ReadWritePaths=-/etc/gogs - [Install] WantedBy=multi-user.target _EOF_ @@ -10576,6 +10514,68 @@ WorkingDirectory=/usr/local/bin/nukkit ExecStart=/usr/bin/java -jar /usr/local/bin/nukkit/nukkit.jar SuccessExitStatus=143 +[Install] +WantedBy=multi-user.target +_EOF_ + fi + + if To_Install 49 gogs # Gogs + then + # ARMv6/RISC-V: No pre-compiled binaries available, so we host our own. + if (( $G_HW_ARCH == 1 || $G_HW_ARCH == 11 )) + then + local url="https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/gogs_$G_HW_ARCH_NAME.7z" + + # Else install latest binaries from GitHub + else + case $G_HW_ARCH in + 2) local arch='armv7';; + 3) local arch='armv8';; + *) local arch='amd64';; + esac + + local fallback_url="https://github.com/gogs/gogs/releases/download/v0.13.0/gogs_0.13.0_linux_$arch.tar.gz" + local url=$(curl -sSfL 'https://api.github.com/repos/gogs/gogs/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/gogs_[^\"\/]*_linux_$arch.tar.gz\"$/{print \$4}") + fi + + Download_Install "$url" + G_EXEC mkdir -p /etc/gogs + G_EXEC mv gogs/gogs /etc/gogs/gogs + G_EXEC rm -R gogs + + # Pre-v8.14: Remove unnecessary init scripts + [[ -d '/etc/gogs/scripts' ]] && G_EXEC rm -R /etc/gogs/scripts + + # User + Create_User -d /etc/gogs -s /bin/dash gogs + + # Directories + permissions + G_EXEC mkdir -p /mnt/dietpi_userdata/gogs-repo + G_EXEC chown -R gogs:gogs /etc/gogs /mnt/dietpi_userdata/gogs-repo + + # Database + /boot/dietpi/func/create_mysql_db gogs gogs "$GLOBAL_PW" + + # Service: https://github.com/gogs/gogs/blob/main/scripts/systemd/gogs.service + cat << '_EOF_' > /etc/systemd/system/gogs.service +[Unit] +Description=Gogs (DietPi) +Wants=network-online.target +After=network-online.target mariadb.service + +[Service] +User=gogs +LogsDirectory=gogs +WorkingDirectory=/etc/gogs +ExecStart=/etc/gogs/gogs web + +# Hardening +ProtectSystem=full +PrivateDevices=yes +PrivateTmp=yes +NoNewPrivileges=true +ReadWritePaths=-/etc/gogs + [Install] WantedBy=multi-user.target _EOF_ @@ -10590,11 +10590,11 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.7/gitea-1.21.7-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.8/gitea-1.21.8-linux-$arch.xz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/go-gitea/gitea/releases/latest' | mawk -F\" "/\"browser_download_url\": \".*\/gitea-[^\"\/]*-linux-$arch\.xz\"/{print \$4}")" /mnt/dietpi_userdata/gitea/gitea # User - Create_User -d /mnt/dietpi_userdata/gitea gitea + Create_User -d /mnt/dietpi_userdata/gitea -s /bin/dash gitea # Permissions G_EXEC chown -R gitea:gitea /mnt/dietpi_userdata/gitea diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 76d0b380f3..6f50841fce 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -55,7 +55,7 @@ # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=2 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=0 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=1 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 597bf3b683..42b75dc796 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -609,7 +609,7 @@ _EOF_ # Fake KMS supports CMA params only [[ $params ]] && params=$(mawk -F, '{for(i=1; i<=NF; i++) {if($i~/^cma-*/){print $i;exit}}}' <<< "$params") else - # Disable full KMS HDMI audio if onboard HDMI is disabled + # Disable VC4 HDMI audio if onboard HDMI is disabled [[ $params != *',noaudio'* ]] && { ! grep -q '^[[:blank:]]*dtparam=audio=on' /boot/config.txt || grep -Eq '(^|[[:blank:]])snd_bcm2835.enable_hdmi=0([[:blank:]]|$)' /boot/cmdline.txt; } && params+=',noaudio' fi @@ -1725,7 +1725,7 @@ _EOF_ # Remove kernel module options G_EXEC sed --follow-symlinks -Ei '/root=/s/[[:blank:]]*snd_bcm2835.enable_[^[:blank:]]*([[:blank:]]*$)?//g' /boot/cmdline.txt - # Disable full KMS HDMI audio + # Disable VC4 HDMI audio local kms=$(grep -Em1 '^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?(,|$)' /boot/config.txt) [[ $kms && ! $kms =~ ',noaudio'(,|$) ]] && G_EXEC sed --follow-symlinks -Ei '/^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?(,|$)/s/$/,noaudio/' /boot/config.txt @@ -1943,33 +1943,42 @@ _EOF_ # rpi-bcm2835-hdmi 'rpi-bcm2835-'*) - # Remove blacklist for onboard audio kernel module - G_EXEC rm /etc/modprobe.d/dietpi-disable_rpi_audio.conf - - # Enable onboard audio - G_CONFIG_INJECT 'dtparam=audio=' 'dtparam=audio=on' /boot/config.txt - - # Force 3.5mm output? - if [[ $INPUT_DEVICE_VALUE == *'3.5mm' ]] - then - # Disable HDMI audio via kernel module option - G_EXEC sed --follow-symlinks -i '/root=/s/$/ snd_bcm2835.enable_hdmi=0/' /boot/cmdline.txt - - # Force HDMI output? - elif [[ $INPUT_DEVICE_VALUE == *'hdmi' ]] + # Enable VC4 HDMI audio if onboard HDMI is enabled and KMS used, as the bcm2835 HDMI audio driver and KMS conflict: https://dietpi.com/forum/t/19568, https://github.com/raspberrypi/linux/issues/4651 + if [[ $INPUT_DEVICE_VALUE != *'3.5mm' ]] && grep -Eq '^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?,(noaudio|.+,noaudio)(,|$)' /boot/config.txt then - # Disable headphones via kernel module option - G_EXEC sed --follow-symlinks -i '/root=/s/$/ snd_bcm2835.enable_headphones=0/' /boot/cmdline.txt - # Force HDMI audio via config.txt option - G_CONFIG_INJECT 'hdmi_drive=' 'hdmi_drive=2' /boot/config.txt - (( $G_HW_MODEL > 3 )) && G_CONFIG_INJECT 'hdmi_drive:1=' 'hdmi_drive:1=2' /boot/config.txt 'hdmi_drive=' + G_EXEC sed --follow-symlinks -Ei '/^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?,/s/,noaudio(,|$)/\1/' /boot/config.txt fi - # Enable full KMS HDMI audio if onboard HDMI is not disabled - if [[ $INPUT_DEVICE_VALUE != *'3.5mm' ]] + # Enable bcm2835 audio driver if 3.5mm is enabled or no VC4 used + if [[ $INPUT_DEVICE_VALUE != *'hdmi' ]] || ! grep -Eq '^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?(,|$)' /boot/config.txt then - local kms=$(grep -Em1 '^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?,(noaudio|.+,noaudio)(,|$)' /boot/config.txt) - [[ $kms ]] && G_EXEC sed --follow-symlinks -Ei '/^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?,/s/,noaudio(,|$)/\1/' /boot/config.txt + # Remove blacklist for bcm2835 audio kernel module + G_EXEC rm /etc/modprobe.d/dietpi-disable_rpi_audio.conf + + # Enable bcm2835 audio via device tree parameter + G_CONFIG_INJECT 'dtparam=audio=' 'dtparam=audio=on' /boot/config.txt + + # Force 3.5mm output? + if [[ $INPUT_DEVICE_VALUE == *'3.5mm' ]] + then + # Disable HDMI audio via kernel module option + G_EXEC sed --follow-symlinks -i '/root=/s/$/ snd_bcm2835.enable_hdmi=0/' /boot/cmdline.txt + + # Force HDMI output? + elif [[ $INPUT_DEVICE_VALUE == *'hdmi' ]] + then + # Disable headphones via kernel module option + G_EXEC sed --follow-symlinks -i '/root=/s/$/ snd_bcm2835.enable_headphones=0/' /boot/cmdline.txt + + # Force HDMI audio via config.txt option + G_CONFIG_INJECT 'hdmi_drive=' 'hdmi_drive=2' /boot/config.txt + (( $G_HW_MODEL > 3 )) && G_CONFIG_INJECT 'hdmi_drive:1=' 'hdmi_drive:1=2' /boot/config.txt 'hdmi_drive=' + fi + + # If only VC4 HDMI audio is used, return here to skip /etc/asound.conf generation and remove potential root user config: https://dietpi.com/forum/t/19568 + else + [[ -f '/root/.asoundrc' ]] && G_EXEC rm /root/.asoundrc + return 0 fi ;; From 0c4116aa3c575ed960a161261fad47b471a46884 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Carvalho?= Date: Sun, 17 Mar 2024 02:39:45 +0100 Subject: [PATCH 084/266] v9.2 (#6844) - DietPi-Banner | Support for showing the current RAM usage was added. Many thanks to @Andr3Carvalh0 for the implementation: https://github.com/MichaIng/DietPi/pull/6844 --- CHANGELOG.txt | 1 + dietpi/func/dietpi-banner | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 4d48b35539..3d333f37e3 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,6 +2,7 @@ v9.2 (2024-03-16) Enhancements: +- DietPi-Banner | Support for showing the current RAM usage was added. Many thanks to @Andr3Carvalh0 for the implementation: https://github.com/MichaIng/DietPi/pull/6844 - DietPi-Software | It is now possible to run "dietpi-software list" concurrent to other dietpi-software instances, and as non-root user. This avoids an issue in DietPi-Dashboard, where opening dietpi-software in the Terminal and switching to the Software page, caused an infinite hang. - DietPi-Software | Gogs/Gitea: Using repositories via SSH should now work OOTB with new installs and reinstalls. If pull or push operations via SSH fail in your case, try to give the respective user a default shell: "sudo usermod -s /bin/dash gogs" respectively "sudo usermod -s /bin/dash gitea". This is now included in our default setup. Many thanks to @din14970 for reporting this missing feature: https://github.com/MichaIng/DietPi/discussions/6964#discussioncomment-8813390 diff --git a/dietpi/func/dietpi-banner b/dietpi/func/dietpi-banner index c77958bc4b..e119656403 100755 --- a/dietpi/func/dietpi-banner +++ b/dietpi/func/dietpi-banner @@ -57,14 +57,15 @@ 'Large hostname' 'Print credits' 'Let'\''s Encrypt cert status' + 'RAM usage' ) # Set defaults: Disable CPU temp by default in VMs if (( $G_HW_MODEL == 20 )) then - aENABLED=(1 0 0 0 0 1 0 1 0 0 0 1 1 0 0 1 0) + aENABLED=(1 0 0 0 0 1 0 1 0 0 0 1 1 0 0 1 0 0) else - aENABLED=(1 0 1 0 0 1 0 0 0 0 0 1 1 0 0 1 0) + aENABLED=(1 0 1 0 0 1 0 0 0 0 0 1 1 0 0 1 0 0) fi COLOUR_RESET='\e[0m' @@ -237,6 +238,8 @@ $GREEN_LINE" (( ${aENABLED[1]} == 1 )) && echo -e "$GREEN_BULLET ${aCOLOUR[1]}${aDESCRIPTION[1]} $GREEN_SEPARATOR $(uptime -p 2>&1)" # CPU temp (( ${aENABLED[2]} == 1 )) && echo -e "$GREEN_BULLET ${aCOLOUR[1]}${aDESCRIPTION[2]} $GREEN_SEPARATOR $(print_full_info=1 G_OBTAIN_CPU_TEMP 2>&1)" + # RAM usage + (( ${aENABLED[17]} == 1 )) && echo -e "$GREEN_BULLET ${aCOLOUR[1]}${aDESCRIPTION[17]} $GREEN_SEPARATOR $(free -b | mawk 'NR==2 {CONVFMT="%.0f"; print $3/1024^2" of "$2/1024^2" MiB ("$3/$2*100"%)"}')" # Hostname (( ${aENABLED[3]} == 1 && ${aENABLED[14]} != 1 )) && echo -e "$GREEN_BULLET ${aCOLOUR[1]}${aDESCRIPTION[3]} $GREEN_SEPARATOR $( Date: Sun, 17 Mar 2024 02:40:43 +0100 Subject: [PATCH 085/266] v9.2 - DietPi-Software | rutorrent: Update fallback version --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index a1cc12d8bf..4bab90acda 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8514,7 +8514,7 @@ _EOF_ # Install ruTorrent: Web UI for rTorrent # - Grab current version local version=$(curl -sSfL 'https://api.github.com/repos/Novik/ruTorrent/releases/latest' | mawk -F\" '/^ *"tag_name": "[^"]*",$/{print $4}') - [[ $version ]] || { version='v4.2.10'; G_DIETPI-NOTIFY 1 "Automatic latest ruTorrent version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } + [[ $version ]] || { version='v4.2.11'; G_DIETPI-NOTIFY 1 "Automatic latest ruTorrent version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } Download_Install "https://github.com/Novik/ruTorrent/archive/$version.tar.gz" # - Reinstall freshly with preserved configs and 3rd party plugins From 3d6f598ff8518b16be6e113900565de36d1c7f5e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 17 Mar 2024 02:51:38 +0100 Subject: [PATCH 086/266] v9.2 - DietPi-Patches | Fix Amiberry update text --- .update/patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index 737025bc6d..9083c42eef 100755 --- a/.update/patches +++ b/.update/patches @@ -1604,7 +1604,7 @@ Patch_9_2() # Amiberry if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[108\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' amiberry 2> /dev/null)" lt 5.6.8-dietpi1 then - G_DIETPI-NOTIFY 2 'Preparing Amiberry upgrade to v5.6.6, including migration for RPi systems from fake KMS DispmanX to full KMS SDL2 graphics backend' + G_DIETPI-NOTIFY 2 'Preparing Amiberry upgrade to v5.6.8' echo 108 >> /var/tmp/dietpi/dietpi-update_reinstalls fi fi From 316ec0aeb1201e5fe4a80a75691608fb12c39e33 Mon Sep 17 00:00:00 2001 From: StephanStS Date: Tue, 19 Mar 2024 09:03:32 +0100 Subject: [PATCH 087/266] Init v9.3 (#6972) --- .meta/dietpi-survey_report | 3 ++- .update/version | 4 ++-- CHANGELOG.txt | 13 +++++++++++++ dietpi/func/dietpi-globals | 4 ++-- 4 files changed, 19 insertions(+), 5 deletions(-) diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index 4e5e3b3ccc..c601631b40 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -712,10 +712,11 @@ shopt -s extglob aSOFTWARE_NAME9_0[i]=${aSOFTWARE_NAME8_25[i]} aSOFTWARE_NAME9_1[i]=${aSOFTWARE_NAME9_0[i]} aSOFTWARE_NAME9_2[i]=${aSOFTWARE_NAME9_1[i]} + aSOFTWARE_NAME9_3[i]=${aSOFTWARE_NAME9_2[i]} done # Pre-create software counter array so that we can see also software (available in newest version) with 0 installs - for i in "${aSOFTWARE_NAME9_2[@]}" + for i in "${aSOFTWARE_NAME9_3[@]}" do aSOFTWARE[$i]=0 done diff --git a/.update/version b/.update/version index a19ad9e36f..42b0f6b092 100644 --- a/.update/version +++ b/.update/version @@ -2,8 +2,8 @@ # shellcheck disable=SC2034 # Available DietPi version G_REMOTE_VERSION_CORE=9 -G_REMOTE_VERSION_SUB=2 -G_REMOTE_VERSION_RC=1 +G_REMOTE_VERSION_SUB=3 +G_REMOTE_VERSION_RC=-1 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 3d333f37e3..6a9676e03e 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,3 +1,16 @@ +v9.3 +(2024-04-13) + +New images: + +Enhancements: + +Bug fixes: + +As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME + +----------------------------------------------------------------------------------------------------------- + v9.2 (2024-03-16) diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 6f50841fce..7b6c58de0b 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -54,8 +54,8 @@ [[ -f '/boot/dietpi/.version' ]] && . /boot/dietpi/.version # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 - [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=2 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=1 + [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=3 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=-1 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From cbf29a01572927b7e0245c94a75c1b5e8edebc27 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 22 Mar 2024 19:27:09 +0800 Subject: [PATCH 088/266] v9.3 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 4bab90acda..0c18cc3b54 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6501,7 +6501,7 @@ _EOF_ esac # Download - local fallback_url="https://github.com/fatedier/frp/releases/download/v0.55.1/frp_0.55.1_linux_$arch.tar.gz" + local fallback_url="https://github.com/fatedier/frp/releases/download/v0.56.0/frp_0.56.0_linux_$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/fatedier/frp/releases/latest' | mawk -F\" "/\"browser_download_url\": .*\/frp_[0-9.]*_linux_$arch\.tar\.gz\"/{print \$4}")" G_EXEC cd frp_* @@ -8176,7 +8176,7 @@ _EOF_ # APT deps: https://github.com/sabre-io/Baikal/wiki/Baïkal-dependencies aDEPS=("php$PHP_VERSION-xml" "php$PHP_VERSION-mbstring" "php$PHP_VERSION-mysql") - local fallback_url='https://github.com/sabre-io/Baikal/releases/download/0.9.3/baikal-0.9.3.zip' + local fallback_url='https://github.com/sabre-io/Baikal/releases/download/0.9.5/baikal-0.9.5.zip' Download_Install "$(curl -sSfL 'https://api.github.com/repos/sabre-io/Baikal/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/baikal-[^"\/]*\.zip"$/{print $4}')" # Reinstall: https://sabre.io/baikal/upgrade/ @@ -9951,7 +9951,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.13.3.4273/Prowlarr.master.1.13.3.4273.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.14.3.4333/Prowlarr.master.1.14.3.4333.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Prowlarr/Prowlarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC mv Prowlarr /opt/prowlarr fi @@ -10590,7 +10590,7 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.8/gitea-1.21.8-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.9/gitea-1.21.9-linux-$arch.xz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/go-gitea/gitea/releases/latest' | mawk -F\" "/\"browser_download_url\": \".*\/gitea-[^\"\/]*-linux-$arch\.xz\"/{print \$4}")" /mnt/dietpi_userdata/gitea/gitea # User From 380305096c6b35b4e494b4b8af399c5efa52ebcc Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 22 Mar 2024 20:20:59 +0800 Subject: [PATCH 089/266] v9.3 - DietPi-Installer | Since Armbian dropped Bullseye support, the related APT package lists are empty. Use the Bookworm suite instead, which works well since kernel and firmware are Debian-verison-agnostic. Apply a related pre-patch, and re-assure that only kernel and firmware packages are pulled form this repo - DietPi-Patches/Pre-patches | Follow symlinks consistently with all sed calls --- .build/images/dietpi-installer | 2 +- .update/patches | 8 ++++---- .update/pre-patches | 26 +++++++++++++++++++++++--- 3 files changed, 28 insertions(+), 8 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 7254702d51..9c0b8d9a9e 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1037,7 +1037,7 @@ _EOF_ # Remove obsolete lists G_EXEC rm -Rf /etc/apt/sources.list.d/* # Add Armbian repository - G_EXEC eval "echo 'deb https://apt.armbian.com/ $DISTRO_TARGET_NAME main' > /etc/apt/sources.list.d/dietpi-armbian.list" + G_EXEC eval "echo 'deb https://apt.armbian.com/ ${DISTRO_TARGET_NAME/bullseye/bookworm} main' > /etc/apt/sources.list.d/dietpi-armbian.list" # Update APT lists G_AGUP # Install kernel, device tree, U-Boot, firmware and initramfs packages diff --git a/.update/patches b/.update/patches index 9083c42eef..f59836fc21 100755 --- a/.update/patches +++ b/.update/patches @@ -1494,7 +1494,7 @@ map $arg_v $asset_immutable { if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[163\]=2' /boot/dietpi/.installed && grep -q ' -f -I ' /etc/default/gmediarender then G_DIETPI-NOTIFY 2 'Fixing default GMediaRender command arguments' - G_EXEC sed -i "s/ -f -I / -f $HOSTNAME -I /" /etc/default/gmediarender + G_EXEC sed --follow-symlinks -i "s/ -f -I / -f $HOSTNAME -I /" /etc/default/gmediarender fi # OctoPrint: https://github.com/MichaIng/DietPi/issues/6915 @@ -1502,7 +1502,7 @@ map $arg_v $asset_immutable { then G_DIETPI-NOTIFY 2 'Fixing OctoPrint sudoers rule' # shellcheck disable=SC2230 - G_EXEC sed -i "s|, reboot, poweroff|, $(which reboot), $(which poweroff)|" /etc/sudoers.d/octoprint + G_EXEC sed --follow-symlinks -i "s|, reboot, poweroff|, $(which reboot), $(which poweroff)|" /etc/sudoers.d/octoprint fi fi } @@ -1559,7 +1559,7 @@ Patch_9_2() if [[ -f '/etc/nginx/sites-dietpi/dietpi-nextcloud.conf' ]] && ! grep -q 'include mime.types;' /etc/nginx/sites-dietpi/dietpi-nextcloud.conf then G_DIETPI-NOTIFY 2 'Fixing Nextclound Nginx config ...' - G_EXEC sed -i '/types {/i\\tinclude mime.types;' /etc/nginx/sites-dietpi/dietpi-nextcloud.conf + G_EXEC sed --follow-symlinks -i '/types {/i\\tinclude mime.types;' /etc/nginx/sites-dietpi/dietpi-nextcloud.conf fi # PaperMC @@ -1573,7 +1573,7 @@ Patch_9_2() if [[ -f '/mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml' ]] && grep -q '^auth-type: floodgate' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml then G_DIETPI-NOTIFY 2 'Fixing Geyser plugin config ...' - G_EXEC sed -i 's/^auth-type: floodgate/ auth-type: floodgate/' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml + G_EXEC sed --follow-symlinks -i 's/^auth-type: floodgate/ auth-type: floodgate/' /mnt/dietpi_userdata/papermc/plugins/Geyser-Spigot/config.yml fi fi diff --git a/.update/pre-patches b/.update/pre-patches index baf5c0d323..de6302c9bb 100755 --- a/.update/pre-patches +++ b/.update/pre-patches @@ -369,9 +369,9 @@ then if (( $G_HW_MODEL < 10 || ( $G_HW_MODEL == 75 && ${G_RASPBIAN:-0} == 1 ) )) then G_DIETPI-NOTIFY 2 'Migrating from raspberrypi.org to raspberrypi.com' - G_EXEC sed -i 's/raspberrypi.org/raspberrypi.com/' /etc/apt/sources.list /boot/dietpi.txt - find /etc/apt/sources.list.d/* &> /dev/null && G_EXEC sed -i 's/raspberrypi.org/raspberrypi.com/' /etc/apt/sources.list.d/*.list - find /etc/apt/preferences.d/* &> /dev/null && G_EXEC sed -i 's/raspberrypi.org/raspberrypi.com/' /etc/apt/preferences.d/* + G_EXEC sed --follow-symlinks -i 's/raspberrypi.org/raspberrypi.com/' /etc/apt/sources.list /boot/dietpi.txt + find /etc/apt/sources.list.d/* &> /dev/null && G_EXEC sed --follow-symlinks -i 's/raspberrypi.org/raspberrypi.com/' /etc/apt/sources.list.d/*.list + find /etc/apt/preferences.d/* &> /dev/null && G_EXEC sed --follow-symlinks -i 's/raspberrypi.org/raspberrypi.com/' /etc/apt/preferences.d/* fi GITBRANCH_TARGET=$(sed -n '/^[[:blank:]]*DEV_GITBRANCH=/{s/^[^=]*=//p;q}' /boot/dietpi.txt) GITBRANCH_TARGET=${GITBRANCH_TARGET:-master} @@ -392,5 +392,25 @@ then fi fi +# v9.3 +if (( $G_DIETPI_VERSION_CORE < 9 || ( $G_DIETPI_VERSION_CORE == 9 && $G_DIETPI_VERSION_SUB < 3 ) )) +then + # Update APT repo on Bullseye systems to Bookworm, but re-assure only kernel and firmware packages are pulled form it. Armbian dropped Bullseye support + if [[ $G_DISTRO == 6 && -f '/etc/apt/sources.list.d/dietpi-armbian.list' ]] + then + G_DIETPI-NOTIFY 2 'Moving EOL Armbian Bullseye repo to Bookworm for Debian-version-agnostic firmware and kernel upgrades' + cat << '_EOF_' > /etc/apt/preferences.d/dietpi-armbian +Package: * +Pin: origin apt.armbian.com +Pin-Priority: -1 + +Package: armbian-firmware* linux-* +Pin: origin apt.armbian.com +Pin-Priority: 500 +_EOF_ + G_EXEC sed --follow-symlinks -i 's/bullseye/bookworm/g' /etc/apt/sources.list.d/dietpi-armbian.list + fi +fi + exit 0 } From 43b8bd7b9690015b7ede9e3bf7f2501a13470b1e Mon Sep 17 00:00:00 2001 From: wiedehopf Date: Wed, 27 Mar 2024 13:17:01 +0100 Subject: [PATCH 090/266] v9.3 (#6988) - DietPi-Login | Log dietpi-update incl. network check, time sync and version check results from dietpi-update on first login, to enhance debug abilities in automated first run setup cases. This is not includes in /var/log/dietpi-update.log, but since it is the very first network check and time sync (state check) done, it is crucial for everything else. --- dietpi/dietpi-login | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-login b/dietpi/dietpi-login index f23b2cdadc..7d1d685c4d 100755 --- a/dietpi/dietpi-login +++ b/dietpi/dietpi-login @@ -185,7 +185,7 @@ Please login again as user "root" with password "dietpi", respectively the one y if (( $G_DIETPI_INSTALL_STAGE == 0 )); then # Start DietPi-Update - /boot/dietpi/dietpi-update 1 # Sets /boot/dietpi/.install_stage > G_DIETPI_INSTALL_STAGE=1 + /boot/dietpi/dietpi-update 1 2>&1 | tee "$FP_DIETPI_FIRSTRUNSETUP_LOG" # Sets /boot/dietpi/.install_stage > G_DIETPI_INSTALL_STAGE=1 # Prompt on failure (( $(&1 | tee "$FP_DIETPI_FIRSTRUNSETUP_LOG" # Sets /boot/dietpi/.install_stage > G_DIETPI_INSTALL_STAGE=2 + /boot/dietpi/dietpi-software 2>&1 | tee -a "$FP_DIETPI_FIRSTRUNSETUP_LOG" # Sets /boot/dietpi/.install_stage > G_DIETPI_INSTALL_STAGE=2 # Prompt on failure (( $( Date: Fri, 29 Mar 2024 13:19:16 +0100 Subject: [PATCH 091/266] v9.3 - DietPi-Software | Logitech Media Server: Resolved an issue where the install failed due to a changed download URL. Many thanks to @JRK0469 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6992 --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 6a9676e03e..6fb392cf24 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,6 +6,7 @@ New images: Enhancements: Bug fixes: +- DietPi-Software | Logitech Media Server: Resolved an issue where the install failed due to a changed download URL. Many thanks to @JRK0469 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6992 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 0c18cc3b54..bda49d9e62 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6990,8 +6990,8 @@ _EOF_ (( $G_HW_ARCH == 10 )) && arch='amd64' # Grab latest package URL - local fallback_url="https://downloads.slimdevices.com/nightly/logitechmediaserver_8.3.2~1702911674_$arch.deb" - Download_Install "$(curl -sSf 'https://lms-community.github.io/lms-server-repository/stable.xml' | grep -om1 "https://[^\"]*_$arch.deb")" + local fallback_url="https://downloads.lms-community.org/nightly/logitechmediaserver_8.5.1~1711624004_$arch.deb" + Download_Install "$(curl -sSf 'https://raw.githubusercontent.com/LMS-Community/lms-server-repository/master/stable.xml' | grep -om1 "https://[^\"]*_$arch.deb")" G_EXEC systemctl stop logitechmediaserver Remove_SysV logitechmediaserver From d885efcf3c4234da08219a4aa6a562829f75d958 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 29 Mar 2024 13:37:31 +0100 Subject: [PATCH 092/266] v9.3 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index bda49d9e62..d341a25ceb 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -7521,7 +7521,7 @@ _EOF_ local json=() [[ $PHP_VERSION == 8* ]] || aDEPS+=("php$PHP_VERSION-json") json=('json') - local fallback_url="https://github.com/ampache/ampache/releases/download/6.3.0/ampache-6.3.0_all_php$PHP_VERSION.zip" + local fallback_url="https://github.com/ampache/ampache/releases/download/6.3.1/ampache-6.3.1_all_php$PHP_VERSION.zip" Download_Install "$(curl -sSfL 'https://api.github.com/repos/ampache/ampache/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/ampache-[0-9\.]*_all_php$PHP_VERSION.zip\"$/{print \$4}")" ampache # Reinstall: Preserve configs from old and new paths @@ -9951,7 +9951,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.14.3.4333/Prowlarr.master.1.14.3.4333.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.15.0.4361/Prowlarr.master.1.15.0.4361.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Prowlarr/Prowlarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC mv Prowlarr /opt/prowlarr fi @@ -10026,7 +10026,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.20.2452/Readarr.develop.0.3.20.2452.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.21.2475/Readarr.develop.0.3.21.2475.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Readarr/Readarr/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}" | head -1)" G_EXEC mv Readarr /opt/readarr fi @@ -10590,7 +10590,7 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.9/gitea-1.21.9-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.10/gitea-1.21.10-linux-$arch.xz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/go-gitea/gitea/releases/latest' | mawk -F\" "/\"browser_download_url\": \".*\/gitea-[^\"\/]*-linux-$arch\.xz\"/{print \$4}")" /mnt/dietpi_userdata/gitea/gitea # User From afe0074a0e64c6c46b3ccff5166ed87c02de9b8d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 1 Apr 2024 18:16:19 +0200 Subject: [PATCH 093/266] v9.3 - DietPi-Config | Removed the 3.5mm audio option on Raspberry Pi 5, as it does not have a 3.5mm jack. Additionally, the KMS graphics driver is enabled OOTB when HDMI audio is selected, as the snd_bcm2835 driver does not work on Raspberry Pi 5. Many thanks to `@JRK0469` for making us aware of this: https://dietpi.com/forum/t/19760 - Raspberry Pi 5 | Fixed X11/desktop startup if KMS is enabled. Many thanks to `@denguido` for reporting the issue and solution: https://dietpi.com/forum/t/19760 --- CHANGELOG.txt | 2 + dietpi/dietpi-config | 95 ++++++++++++++++----------------- dietpi/dietpi-software | 34 +++++++----- dietpi/func/dietpi-set_hardware | 20 ++++++- 4 files changed, 88 insertions(+), 63 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 6fb392cf24..fb0d04eb11 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -4,8 +4,10 @@ v9.3 New images: Enhancements: +- DietPi-Config | Removed the 3.5mm audio option on Raspberry Pi 5, as it does not have a 3.5mm jack. Additionally, the KMS graphics driver is enabled OOTB when HDMI audio is selected, as the snd_bcm2835 driver does not work on Raspberry Pi 5. Many thanks to @JRK0469 for making us aware of this: https://dietpi.com/forum/t/19760 Bug fixes: +- Raspberry Pi 5 | Fixed X11/desktop startup if KMS is enabled. Many thanks to @denguido for reporting the issue and solution: https://dietpi.com/forum/t/19760 - DietPi-Software | Logitech Media Server: Resolved an issue where the install failed due to a changed download URL. Many thanks to @JRK0469 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6992 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index e93be67e13..e586907567 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -3442,39 +3442,41 @@ Additional benchmarks: # RPi if (( $G_HW_MODEL < 10 )); then - G_WHIP_MENU_ARRAY+=('rpi-bcm2835-auto' ': Onboard HDMI if plugged, else 3.5mm') - G_WHIP_MENU_ARRAY+=('rpi-bcm2835-3.5mm' ': Onboard 3.5mm output') - G_WHIP_MENU_ARRAY+=('rpi-bcm2835-hdmi' ': Onboard HDMI output') - G_WHIP_MENU_ARRAY+=('allo-boss-dac-pcm512x-audio' ': Allo Boss DAC') - G_WHIP_MENU_ARRAY+=('allo-boss2-dac-audio' ': Allo Boss2 DAC') - G_WHIP_MENU_ARRAY+=('allo-digione' ': Allo DigiOne') - G_WHIP_MENU_ARRAY+=('allo-katana-dac-audio' ': Allo Katana DAC') - G_WHIP_MENU_ARRAY+=('allo-piano-dac-pcm512x-audio' ': Allo Piano DAC') - G_WHIP_MENU_ARRAY+=('allo-piano-dac-plus-pcm512x-audio' ': Allo Piano DAC 2.1') - G_WHIP_MENU_ARRAY+=('applepi-dac' ': ApplePi DAC (Orchard Audio)') - G_WHIP_MENU_ARRAY+=('dionaudio-loco' ': Dion Audio LOCO') - G_WHIP_MENU_ARRAY+=('dionaudio-loco-v2' ': Dion Audio LOCO V2') - G_WHIP_MENU_ARRAY+=('googlevoicehat-soundcard' ': Google AIY voice kit') - G_WHIP_MENU_ARRAY+=('hifiberry-amp' ': HifiBerry AMP / AMP+') - G_WHIP_MENU_ARRAY+=('hifiberry-dac' ': HifiBerry DAC / MiniAMP') - G_WHIP_MENU_ARRAY+=('hifiberry-dacplus' ': HifiBerry DAC+ / DAC+ Pro / AMP2') - G_WHIP_MENU_ARRAY+=('hifiberry-dacplusadc' ': HifiBerry DAC+ADC') - G_WHIP_MENU_ARRAY+=('hifiberry-dacplusadcpro' ': HifiBerry DAC+ADC Pro') - G_WHIP_MENU_ARRAY+=('hifiberry-dacplusdsp' ': HifiBerry DAC+DSP') - G_WHIP_MENU_ARRAY+=('hifiberry-dacplushd' ': HifiBerry DAC+ HD') - G_WHIP_MENU_ARRAY+=('hifiberry-digi' ': HifiBerry Digi / Digi+') - G_WHIP_MENU_ARRAY+=('hifiberry-digi-pro' ': HifiBerry Digi+ Pro') - G_WHIP_MENU_ARRAY+=('i-sabre-q2m' ': AudioPhonics I-Sabre ES9028Q2M / ES9038Q2M') - G_WHIP_MENU_ARRAY+=('iqaudio-codec' ': IQaudIO Pi-Codec HAT') - G_WHIP_MENU_ARRAY+=('iqaudio-dac' ': IQaudIO DAC audio card') - G_WHIP_MENU_ARRAY+=('iqaudio-dacplus' ': Pi-DAC+, Pi-DACZero, Pi-DAC+ Pro, Pi-DigiAMP+') - G_WHIP_MENU_ARRAY+=('iqaudio-digi-wm8804-audio' ': Pi-Digi+') - G_WHIP_MENU_ARRAY+=('iqaudio-dacplus,auto_mute_amp' ': Pi-DigiAMP+') - G_WHIP_MENU_ARRAY+=('iqaudio-dacplus,unmute_amp' ': Pi-DigiAMP+') - G_WHIP_MENU_ARRAY+=('justboom-dac' ': JustBoom: DAC HAT, Amp HAT, DAC Zero and Amp Zero') - G_WHIP_MENU_ARRAY+=('justboom-digi' ': JustBoom: Digi HAT and Digi Zero') - G_WHIP_MENU_ARRAY+=('justboom-both' ': JustBoom: Simultaneous DAC and Digi usage') - G_WHIP_MENU_ARRAY+=('rpi-dac' ': Soekris DAM1021 (pcm1794a)') + # RPi 5 has no 3.5mm jack: https://dietpi.com/forum/t/19760 + (( $G_HW_MODEL == 5 )) || G_WHIP_MENU_ARRAY+=('rpi-bcm2835-auto' ': Onboard HDMI if plugged, else 3.5mm' 'rpi-bcm2835-3.5mm' ': Onboard 3.5mm output') + G_WHIP_MENU_ARRAY+=( + 'rpi-bcm2835-hdmi' ': Onboard HDMI output' + 'allo-boss-dac-pcm512x-audio' ': Allo Boss DAC' + 'allo-boss2-dac-audio' ': Allo Boss2 DAC' + 'allo-digione' ': Allo DigiOne' + 'allo-katana-dac-audio' ': Allo Katana DAC' + 'allo-piano-dac-pcm512x-audio' ': Allo Piano DAC' + 'allo-piano-dac-plus-pcm512x-audio' ': Allo Piano DAC 2.1' + 'applepi-dac' ': ApplePi DAC (Orchard Audio)' + 'dionaudio-loco' ': Dion Audio LOCO' + 'dionaudio-loco-v2' ': Dion Audio LOCO V2' + 'googlevoicehat-soundcard' ': Google AIY voice kit' + 'hifiberry-amp' ': HifiBerry AMP / AMP+' + 'hifiberry-dac' ': HifiBerry DAC / MiniAMP' + 'hifiberry-dacplus' ': HifiBerry DAC+ / DAC+ Pro / AMP2' + 'hifiberry-dacplusadc' ': HifiBerry DAC+ADC' + 'hifiberry-dacplusadcpro' ': HifiBerry DAC+ADC Pro' + 'hifiberry-dacplusdsp' ': HifiBerry DAC+DSP' + 'hifiberry-dacplushd' ': HifiBerry DAC+ HD' + 'hifiberry-digi' ': HifiBerry Digi / Digi+' + 'hifiberry-digi-pro' ': HifiBerry Digi+ Pro' + 'i-sabre-q2m' ': AudioPhonics I-Sabre ES9028Q2M / ES9038Q2M' + 'iqaudio-codec' ': IQaudIO Pi-Codec HAT' + 'iqaudio-dac' ': IQaudIO DAC audio card' + 'iqaudio-dacplus' ': Pi-DAC+, Pi-DACZero, Pi-DAC+ Pro, Pi-DigiAMP+' + 'iqaudio-digi-wm8804-audio' ': Pi-Digi+' + 'iqaudio-dacplus,auto_mute_amp' ': Pi-DigiAMP+' + 'iqaudio-dacplus,unmute_amp' ': Pi-DigiAMP+' + 'justboom-dac' ': JustBoom: DAC HAT, Amp HAT, DAC Zero and Amp Zero' + 'justboom-digi' ': JustBoom: Digi HAT and Digi Zero' + 'justboom-both' ': JustBoom: Simultaneous DAC and Digi usage' + 'rpi-dac' ': Soekris DAM1021 (pcm1794a)' + ) # Odroid C1/C2 legacy image elif [[ $G_HW_MODEL == 1[12] ]]; then @@ -3486,42 +3488,39 @@ Additional benchmarks: # NanoPi M2/M3 elif [[ $G_HW_MODEL == 6[12] ]]; then - G_WHIP_MENU_ARRAY+=('default' ': 3.5mm Analogue') - G_WHIP_MENU_ARRAY+=('s5pxx18-hdmi' ': HDMI') + G_WHIP_MENU_ARRAY+=('default' ': 3.5mm Analogue' 's5pxx18-hdmi' ': HDMI') # H3 elif (( $G_HW_CPUID == 1 )); then - G_WHIP_MENU_ARRAY+=('default' ': HDMI') - G_WHIP_MENU_ARRAY+=('h3-analogue' ': 3.5mm Analogue') + G_WHIP_MENU_ARRAY+=('default' ': HDMI' 'h3-analogue' ': 3.5mm Analogue') # Sparky SBC elif (( $G_HW_MODEL == 70 )); then - G_WHIP_MENU_ARRAY+=('default' ': HDMI') - G_WHIP_MENU_ARRAY+=('snd-soc-allo-piano-dac' ': Allo Piano DAC') - G_WHIP_MENU_ARRAY+=('snd-soc-allo-piano-dac-plus' ': Allo Piano DAC 2.1') - G_WHIP_MENU_ARRAY+=('allo-cheapo-analogue' ': Allo Cheapo (3.5mm / RCA output)') - G_WHIP_MENU_ARRAY+=('allo-cheapo-optical' ': Allo Cheapo (Optical output)') - G_WHIP_MENU_ARRAY+=('usb-dac-1.1' ': USB 1.1 Audio DAC (any)') + G_WHIP_MENU_ARRAY+=( + 'default' ': HDMI' + 'snd-soc-allo-piano-dac' ': Allo Piano DAC' + 'snd-soc-allo-piano-dac-plus' ': Allo Piano DAC 2.1' + 'allo-cheapo-analogue' ': Allo Cheapo (3.5mm / RCA output)' + 'allo-cheapo-optical' ': Allo Cheapo (Optical output)' + 'usb-dac-1.1' ': USB 1.1 Audio DAC (any)' + ) # ASUS TB elif (( $G_HW_MODEL == 52 )); then - G_WHIP_MENU_ARRAY+=('default' ': HDMI') - G_WHIP_MENU_ARRAY+=('asus-tb-analogue' ': 3.5mm Analogue') + G_WHIP_MENU_ARRAY+=('default' ': HDMI' 'asus-tb-analogue' ': 3.5mm Analogue') # Odroid N2: Modern image elif [[ $G_HW_MODEL == 15 && -f '/boot/dietpiEnv.txt' ]]; then - G_WHIP_MENU_ARRAY+=('OdroidN2_HDMI' ': Onboard digital HDMI audio (default)') - G_WHIP_MENU_ARRAY+=('OdroidN2_3.5mm' ': Onboard analogue 3.5mm audio') + G_WHIP_MENU_ARRAY+=('OdroidN2_HDMI' ': Onboard digital HDMI audio (default)' 'OdroidN2_3.5mm' ': Onboard analogue 3.5mm audio') # Odroid C4: Modern image elif [[ $G_HW_MODEL == 16 && -f '/boot/dietpiEnv.txt' ]]; then G_WHIP_MENU_ARRAY+=('OdroidC4_HDMI' ': Onboard digital HDMI audio (default)') - fi # Intel SST DSP diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index d341a25ceb..14264ef9e4 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -2662,7 +2662,15 @@ _EOF_ then # Add fbdev display driver for legacy framebuffer graphics support, as modesetting requires KMS driver overlay for /dev/dri/card0 to exists. aDEPS+=('xserver-xorg-video-fbdev') - + # RPi 5: Add config to force X11 using the correct DRM device: https://forums.raspberrypi.com/viewtopic.php?t=358853 + (( $G_HW_MODEL == 5 )) && cat << '_EOF_' > /etc/X11/xorg.conf.d/02-dietpi-rpi5.conf +Section "OutputClass" + Identifier "vc4" + MatchDriver "vc4" + Driver "modesetting" + Option "PrimaryGPU" "true" +EndSection +_EOF_ # x86_64 VM elif (( $G_HW_ARCH == 10 && $G_HW_MODEL == 20 )) then @@ -2675,20 +2683,20 @@ _EOF_ then cat << '_EOF_' > /etc/X11/xorg.conf.d/02-dietpi-aml-s905.conf Section "OutputClass" - Identifier "Amlogic" - MatchDriver "meson" - Driver "modesetting" - Option "PrimaryGPU" "true" + Identifier "Amlogic" + MatchDriver "meson" + Driver "modesetting" + Option "PrimaryGPU" "true" EndSection Section "Screen" - Identifier "Default Screen" - Device "Meson" - Monitor "foo" - DefaultDepth 24 - SubSection "Display" - Depth 24 - Modes "1920x1080" "1440x900" "1280x720" "1280x1024" "1280x960" "1024x768" "800x600" "640x480" "720x400" - EndSubSection + Identifier "Default Screen" + Device "Meson" + Monitor "foo" + DefaultDepth 24 + SubSection "Display" + Depth 24 + Modes "1920x1080" "1440x900" "1280x720" "1280x1024" "1280x960" "1024x768" "800x600" "640x480" "720x400" + EndSubSection EndSection _EOF_ fi diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 42b75dc796..d83d19f3b2 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -1729,8 +1729,21 @@ _EOF_ local kms=$(grep -Em1 '^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?(,|$)' /boot/config.txt) [[ $kms && ! $kms =~ ',noaudio'(,|$) ]] && G_EXEC sed --follow-symlinks -Ei '/^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?(,|$)/s/$/,noaudio/' /boot/config.txt - # Use "auto" as default - [[ $INPUT_DEVICE_VALUE == 'default' ]] && INPUT_DEVICE_VALUE='rpi-bcm2835-auto' + # On RPi 5, use "hdmi" by default, else "auto": https://dietpi.com/forum/t/19760 + if [[ $INPUT_DEVICE_VALUE == 'default' ]] + then + if (( $G_HW_MODEL == 5 )) + then + INPUT_DEVICE_VALUE='rpi-bcm2835-hdmi' + else + INPUT_DEVICE_VALUE='rpi-bcm2835-auto' + fi + + # RPi 5: Enforce HDMI audio if any onboard audio was selected, as it does not have a 3.5mm jack. + elif [[ $G_HW_MODEL == 5 && INPUT_DEVICE_VALUE == 'rpi-bcm2835-'* ]] + then + INPUT_DEVICE_VALUE='rpi-bcm2835-hdmi' + fi } Soundcard_Reset_Odroid() @@ -1943,6 +1956,9 @@ _EOF_ # rpi-bcm2835-hdmi 'rpi-bcm2835-'*) + # RPi 5: Enable KMS as the snd_bcm2835 driver does not work on Raspberry Pi 5. It has no 3.5mm jack, hence the only supported onboard audio is HDMI. + (( $G_HW_MODEL == 5 )) && INPUT_DEVICE_VALUE='vc4-kms-v3d' RPi_OpenGL_Main + # Enable VC4 HDMI audio if onboard HDMI is enabled and KMS used, as the bcm2835 HDMI audio driver and KMS conflict: https://dietpi.com/forum/t/19568, https://github.com/raspberrypi/linux/issues/4651 if [[ $INPUT_DEVICE_VALUE != *'3.5mm' ]] && grep -Eq '^[[:blank:]]*dtoverlay=vc4-kms-v3d(-pi4)?,(noaudio|.+,noaudio)(,|$)' /boot/config.txt then From 870b91ae1746dd652aed94e39168aa535a12e672 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 1 Apr 2024 18:26:44 +0200 Subject: [PATCH 094/266] v9.3 - dietpi-set_hardware | Syntax --- dietpi/func/dietpi-set_hardware | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index d83d19f3b2..0108f1d727 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -1740,7 +1740,7 @@ _EOF_ fi # RPi 5: Enforce HDMI audio if any onboard audio was selected, as it does not have a 3.5mm jack. - elif [[ $G_HW_MODEL == 5 && INPUT_DEVICE_VALUE == 'rpi-bcm2835-'* ]] + elif [[ $G_HW_MODEL == 5 && $INPUT_DEVICE_VALUE == 'rpi-bcm2835-'* ]] then INPUT_DEVICE_VALUE='rpi-bcm2835-hdmi' fi From fe42e9e0ed4b4191c695c8de2a2fd48cfd278fd3 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 2 Apr 2024 21:15:54 +0200 Subject: [PATCH 095/266] v9.3 - DietPi-Software | Mosquitto: The official APT repository added support for 64-bit ARM on Bookworm, which is now used for our installation. --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index fb0d04eb11..1769450b1d 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -5,6 +5,7 @@ New images: Enhancements: - DietPi-Config | Removed the 3.5mm audio option on Raspberry Pi 5, as it does not have a 3.5mm jack. Additionally, the KMS graphics driver is enabled OOTB when HDMI audio is selected, as the snd_bcm2835 driver does not work on Raspberry Pi 5. Many thanks to @JRK0469 for making us aware of this: https://dietpi.com/forum/t/19760 +- DietPi-Software | Mosquitto: The official APT repository added support for 64-bit ARM on Bookworm, which is now used for our installation. Bug fixes: - Raspberry Pi 5 | Fixed X11/desktop startup if KMS is enabled. Many thanks to @denguido for reporting the issue and solution: https://dietpi.com/forum/t/19760 diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 14264ef9e4..6a205c50eb 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6687,7 +6687,7 @@ _EOF_ then # Use official APT repository where available: https://repo.mosquitto.org/debian/pool/main/m/mosquitto/ # - Current builds are not ARMv6 compatible: https://github.com/MichaIng/DietPi/issues/5140 - if (( $G_DISTRO < 8 )) && [[ $G_HW_ARCH == 2 || $G_HW_ARCH == 10 ]] + if (( $G_DISTRO < 8 )) && [[ $G_HW_ARCH == 2 || $G_HW_ARCH == 10 || ( $G_HW_ARCH == 3 && $G_DISTRO == 7 ) ]] then # APT key local url='https://repo.mosquitto.org/debian/mosquitto-repo.gpg.key' From bdf526f41f7fadb26dd2d2a3da91e70bc0910f2d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 4 Apr 2024 23:05:24 +0200 Subject: [PATCH 096/266] v9.3 - DietPi-Patches | Purge ancient vmtouch which prevents /boot from being unmounted e.g. for RPi firmware migration: https://github.com/MichaIng/DietPi/issues/6819, https://github.com/MichaIng/DietPi/issues/6976 --- .update/patches | 6 ++++++ dietpi/func/dietpi-set_software | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index f59836fc21..8c714aa78c 100755 --- a/.update/patches +++ b/.update/patches @@ -1610,6 +1610,12 @@ Patch_9_2() fi } +Patch_9_3() +{ + # Purge ancient vmtouch which prevents /boot from being unmounted e.g. for RPi firmware migration: https://github.com/MichaIng/DietPi/issues/6819, https://github.com/MichaIng/DietPi/issues/6976 + [[ -f '/etc/default/vmtouch' ]] && grep -q '/boot/dietpi' /etc/default/vmtouch && G_AGP vmtouch +} + # v6.35 => v7 migration if (( $G_DIETPI_VERSION_CORE == 6 && $G_DIETPI_VERSION_SUB > 34 )) then diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 878f052f5d..e257ebecd4 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -96,7 +96,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R # Generate locales and set new default # - 1. this calls "locale-gen" to regenerate a fresh locale cache based on /etc/locale.gen to /usr/lib/locale/locale-archive. - # - 2. this calls "update-locale LANG=" to apply the new default locale form the debconf default assigned above. + # - 2. this calls "update-locale LANG=" to apply the new default locale from the debconf default assigned above. G_CHECK_OUTPUT=1 G_EXEC dpkg-reconfigure -f noninteractive locales # Update dietpi.txt entry From 23898ba1525d47fa02567fb89af3360214f72454 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 7 Apr 2024 21:52:25 +0200 Subject: [PATCH 097/266] v9.3 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 6a205c50eb..9a1a0c694a 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8913,7 +8913,7 @@ _EOF_ *) local arch='arm';; esac - local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.27.4/syncthing-linux-$arch-v1.27.4.tar.gz" + local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.27.5/syncthing-linux-$arch-v1.27.5.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/syncthing/syncthing/releases/latest' | mawk -F\" "/\"browser_download_url\": .*\/syncthing-linux-$arch-[^\"\/]*\.tar\.gz\"/{print \$4}")" G_EXEC mv syncthing-* /opt/syncthing fi @@ -10034,7 +10034,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.21.2475/Readarr.develop.0.3.21.2475.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.22.2499/Readarr.develop.0.3.22.2499.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Readarr/Readarr/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}" | head -1)" G_EXEC mv Readarr /opt/readarr fi @@ -11710,15 +11710,7 @@ _EOF_ if To_Install 198 filebrowser # File Browser then - case $G_HW_ARCH in - 1) local arch='armv6';; - 2) local arch='armv7';; - 3) local arch='arm64';; - 11) local arch='riscv64';; - *) local arch='amd64';; - esac - - local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.27.0/linux-$arch-filebrowser.tar.gz" + local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.28.0/linux-${G_HW_ARCH_NAME%l}-filebrowser.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/filebrowser/filebrowser/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/linux-$arch-filebrowser\.tar\.gz\"$/{print \$4}")" ./filebrowser/ # Reinstall From 22096cc4a39ad72d8234549b7c6182f059afc4b6 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 7 Apr 2024 22:05:45 +0200 Subject: [PATCH 098/266] v9.3 - DietPi-Software | File Browser: Fix URL detection --- dietpi/dietpi-software | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 9a1a0c694a..6552c05e63 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11710,8 +11710,9 @@ _EOF_ if To_Install 198 filebrowser # File Browser then - local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.28.0/linux-${G_HW_ARCH_NAME%l}-filebrowser.tar.gz" - Download_Install "$(curl -sSfL 'https://api.github.com/repos/filebrowser/filebrowser/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/linux-$arch-filebrowser\.tar\.gz\"$/{print \$4}")" ./filebrowser/ + local arch=$(dpkg --print-architecture) + local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.28.0/linux-${arch%l}-filebrowser.tar.gz" + Download_Install "$(curl -sSfL 'https://api.github.com/repos/filebrowser/filebrowser/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/linux-${arch%l}-filebrowser\.tar\.gz\"$/{print \$4}")" ./filebrowser/ # Reinstall [[ -d '/opt/filebrowser' ]] && G_EXEC rm -R /opt/filebrowser From ce4fd3c53b6bc13e1932ed6defc271e025035f86 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 7 Apr 2024 22:07:27 +0200 Subject: [PATCH 099/266] v9.3 - DietPi-Software | File Browser: Revert URL detection --- dietpi/dietpi-software | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 6552c05e63..b196aff84d 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11710,9 +11710,16 @@ _EOF_ if To_Install 198 filebrowser # File Browser then - local arch=$(dpkg --print-architecture) - local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.28.0/linux-${arch%l}-filebrowser.tar.gz" - Download_Install "$(curl -sSfL 'https://api.github.com/repos/filebrowser/filebrowser/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/linux-${arch%l}-filebrowser\.tar\.gz\"$/{print \$4}")" ./filebrowser/ + case $G_HW_ARCH in + 1) local arch='armv6';; + 2) local arch='armv7';; + 3) local arch='arm64';; + 11) local arch='riscv64';; + *) local arch='amd64';; + esac + + local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.28.0/linux-$arch-filebrowser.tar.gz" + Download_Install "$(curl -sSfL 'https://api.github.com/repos/filebrowser/filebrowser/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/linux-$arch-filebrowser\.tar\.gz\"$/{print \$4}")" ./filebrowser/ # Reinstall [[ -d '/opt/filebrowser' ]] && G_EXEC rm -R /opt/filebrowser From f58e71b19424e946bc1ed37110d01cc4575e22fe Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 8 Apr 2024 23:11:58 +0200 Subject: [PATCH 100/266] v9.3 (#7008) - DietPi-Software | SABnzbd: Skip obsolete dependencies on ARMv6/7 Bookworm systems, since piwheels does now support Bookworm/Python 3.11 --- dietpi/dietpi-software | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index b196aff84d..c60eb91df6 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6998,7 +6998,7 @@ _EOF_ (( $G_HW_ARCH == 10 )) && arch='amd64' # Grab latest package URL - local fallback_url="https://downloads.lms-community.org/nightly/logitechmediaserver_8.5.1~1711624004_$arch.deb" + local fallback_url="https://downloads.lms-community.org/nightly/logitechmediaserver_8.5.1~1712473975_$arch.deb" Download_Install "$(curl -sSf 'https://raw.githubusercontent.com/LMS-Community/lms-server-repository/master/stable.xml' | grep -om1 "https://[^\"]*_$arch.deb")" G_EXEC systemctl stop logitechmediaserver Remove_SysV logitechmediaserver @@ -9172,8 +9172,8 @@ _EOF_ then # APT deps aDEPS=('par2' 'p7zip-full') - # - ARMv6/7 on Bookworm + RISC-V: gcc and libffi-dev for cffi; pkg-config, libssl-dev and Rust for cryptography, g++ for sabctools and ujson - if (( $G_DISTRO > 6 && $G_HW_ARCH < 3 || $G_HW_ARCH == 11 )) + # - RISC-V: gcc and libffi-dev for cffi; pkg-config, libssl-dev and Rust for cryptography, g++ for sabctools and ujson + if (( $G_HW_ARCH == 11 )) then aDEPS+=('g++' 'libffi-dev' 'libssl-dev' 'pkg-config') G_EXEC curl -sSf 'https://sh.rustup.rs/' -o rustup-init.sh @@ -9181,11 +9181,6 @@ _EOF_ G_EXEC_OUTPUT=1 G_EXEC ./rustup-init.sh -y --profile minimal G_EXEC rm rustup-init.sh export PATH="/root/.cargo/bin:$PATH" - - # - ARMv6/7 temporary workaround: https://github.com/piwheels/packages/issues/358 - elif (( $G_HW_ARCH < 3 )) - then - aDEPS+=('g++') fi Download_Install 'https://github.com/sabnzbd/sabnzbd/archive/master.tar.gz' From 04589dd9f3c1e8f6c1599cbbadad421e441a9430 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 9 Apr 2024 18:26:44 +0200 Subject: [PATCH 101/266] v9.3 - dietpi-set_software | ntpd-mode: Remove obsolete condition for installing the systemd-timesyncd package --- dietpi/func/dietpi-set_software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index e257ebecd4..f5178be1c1 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -300,7 +300,7 @@ deb $INPUT_MODE_VALUE $G_DISTRO_NAME-backports main contrib non-free' > /etc/apt # Oneshot modes: Enable systemd-timesyncd to start early at boot, but stop it now elif [[ $INPUT_MODE_VALUE == [123] ]] then - [[ ${timesyncd[0]} ]] && G_AG_CHECK_INSTALL_PREREQ systemd-timesyncd + G_AG_CHECK_INSTALL_PREREQ systemd-timesyncd G_EXEC systemctl unmask systemd-timesyncd # Failsafe G_EXEC systemctl enable systemd-timesyncd G_EXEC systemctl stop systemd-timesyncd From 028369379ec44070561b87f4e28acb6a10149466 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 9 Apr 2024 19:55:17 +0200 Subject: [PATCH 102/266] v9.3 - dietpi.txt | Update default and description for CONFIG_NTP_MIRROR --- dietpi.txt | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/dietpi.txt b/dietpi.txt index a5d83c8000..d0db5bb566 100644 --- a/dietpi.txt +++ b/dietpi.txt @@ -223,10 +223,13 @@ CONFIG_APT_RASPBIAN_MIRROR=http://raspbian.raspberrypi.com/raspbian/ # - Debian: https://www.debian.org/mirror/official#list CONFIG_APT_DEBIAN_MIRROR=https://deb.debian.org/debian/ -# NTP mirror, applied to /etc/ntp.conf -# - For a full list, please see: https://www.ntppool.org/zone/@ -# - Please remove the initial integer and full stop from the value (removing "0."), eg: debian.pool.ntp.org -CONFIG_NTP_MIRROR=debian.pool.ntp.org +# NTP server(s) applied to /etc/systemd/timesyncd.conf +# - "default": Use the NTP server(s) provided via DHCP, else the debian.pool.ntp.org NTP pool. +# - "gateway": Use the router/gateway as NTP server. Recommended, if it does provide this functionality. +# - To use a public NTP pool, see the full list at: https://www.ntppool.org/zone/@ +# Use the pool domain without leading integer and dot (without "0."), like "debian.pool.ntp.org", "pool.ntp.org" or "uk.pool.ntp.org". +# - You can also use a custom IP address, hostname or any combination of space-separated IP addresses, hostnames and NTP pool domain. +CONFIG_NTP_MIRROR=default #------------------------------------------------------------------------------------------------------ ##### DietPi-Software settings ##### From c754c164d20efbbfb3bd63fc591ef725dd014821 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 9 Apr 2024 20:02:53 +0200 Subject: [PATCH 103/266] v9.3 - Minor --- dietpi.txt | 4 ++-- dietpi/func/dietpi-set_software | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dietpi.txt b/dietpi.txt index d0db5bb566..fdd5e82a8e 100644 --- a/dietpi.txt +++ b/dietpi.txt @@ -226,9 +226,9 @@ CONFIG_APT_DEBIAN_MIRROR=https://deb.debian.org/debian/ # NTP server(s) applied to /etc/systemd/timesyncd.conf # - "default": Use the NTP server(s) provided via DHCP, else the debian.pool.ntp.org NTP pool. # - "gateway": Use the router/gateway as NTP server. Recommended, if it does provide this functionality. -# - To use a public NTP pool, see the full list at: https://www.ntppool.org/zone/@ +# - To use another public NTP pool, see the full list at: https://www.ntppool.org/zone/@ # Use the pool domain without leading integer and dot (without "0."), like "debian.pool.ntp.org", "pool.ntp.org" or "uk.pool.ntp.org". -# - You can also use a custom IP address, hostname or any combination of space-separated IP addresses, hostnames and NTP pool domain. +# - You can also use a custom IP address, hostname or any combination of space-separated IP addresses, hostnames and NTP pool domains. CONFIG_NTP_MIRROR=default #------------------------------------------------------------------------------------------------------ diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index f5178be1c1..93e7b1fb27 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -245,7 +245,7 @@ deb $INPUT_MODE_VALUE $G_DISTRO_NAME-backports main contrib non-free' > /etc/apt #///////////////////////////////////////////////////////////////////////////////////// TimeSync_Main() { - if [[ ! $INPUT_MODE_VALUE || $INPUT_MODE_VALUE == [01234] ]] + if [[ ! $INPUT_MODE_VALUE || $INPUT_MODE_VALUE == [0-4] ]] then # If no input given, re-apply current dietpi.txt setting, else revert to default mode 2 [[ $INPUT_MODE_VALUE ]] || INPUT_MODE_VALUE=$(sed -n '/^[[:blank:]]*CONFIG_NTP_MODE=/{s/^[^=]*=//p;q}' /boot/dietpi.txt) From 1828eadf89f38d3306efff1cc9526e768f1b761d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 10 Apr 2024 16:03:14 +0200 Subject: [PATCH 104/266] v9.3 - CI | Packages: Remove unnecessary fields from package control files and simplify "date" command --- .build/software/Amiberry/build.bash | 5 +---- .build/software/gmediarender/build.bash | 5 +---- .build/software/raspberrypi-sys-mods/build.bash | 5 +---- .build/software/shairport-sync/build.bash | 5 +---- .build/software/squeezelite/build.bash | 5 +---- .build/software/vaultwarden/build.bash | 5 +---- .build/software/ympd/build.bash | 5 +---- 7 files changed, 7 insertions(+), 28 deletions(-) diff --git a/.build/software/Amiberry/build.bash b/.build/software/Amiberry/build.bash index e238897a82..61379b0115 100755 --- a/.build/software/Amiberry/build.bash +++ b/.build/software/Amiberry/build.bash @@ -207,15 +207,12 @@ Package: amiberry Version: $v_ami Architecture: $(dpkg --print-architecture) Maintainer: MichaIng -Date: $(date -u '+%a, %d %b %Y %T %z') -Standards-Version: 4.6.2.0 +Date: $(date -uR) Installed-Size: $(du -sk "$DIR" | mawk '{print $1}') Depends:$DEPS_APT_VERSIONED Section: games Priority: optional Homepage: https://amiberry.com/ -Vcs-Git: https://github.com/BlitterStudio/amiberry.git -Vcs-Browser: https://github.com/BlitterStudio/amiberry Description: Optimized Amiga emulator for the Raspberry Pi and other ARM boards This package ships with optimized libSDL2 and capsimg builds. _EOF_ diff --git a/.build/software/gmediarender/build.bash b/.build/software/gmediarender/build.bash index 94ef27a0bc..1b276f857f 100755 --- a/.build/software/gmediarender/build.bash +++ b/.build/software/gmediarender/build.bash @@ -182,15 +182,12 @@ Package: $name Version: $version-$suffix Architecture: $(dpkg --print-architecture) Maintainer: MichaIng -Date: $(date -u '+%a, %d %b %Y %T %z') -Standards-Version: 4.6.2.0 +Date: $(date -uR) Installed-Size: $(du -sk "$DIR" | mawk '{print $1}') Depends:$DEPS_APT_VERSIONED Section: sound Priority: optional Homepage: $repo -Vcs-Git: $repo.git -Vcs-Browser: $repo Description: Minimalist UPNP AV renderer gmrender-resurrect is a minimalist UPNP AV renderer that can be used to play music controlled by a UPNP AV control point. This package contains diff --git a/.build/software/raspberrypi-sys-mods/build.bash b/.build/software/raspberrypi-sys-mods/build.bash index ac91cd6ef2..569109ec06 100755 --- a/.build/software/raspberrypi-sys-mods/build.bash +++ b/.build/software/raspberrypi-sys-mods/build.bash @@ -54,14 +54,11 @@ Package: raspberrypi-sys-mods Version: 2:20230510-dietpi2 Architecture: all Maintainer: MichaIng -Date: $(date -u '+%a, %d %b %Y %T %z') -Standards-Version: 4.6.2.0 +Date: $(date -uR) Installed-Size: $(du -sk raspberrypi-sys-mods | mawk '{print $1}') Section: admin Priority: optional Homepage: https://github.com/RPi-Distro/raspberrypi-sys-mods -Vcs-Git: https://github.com/RPi-Distro/raspberrypi-sys-mods.git -Vcs-Browser: https://github.com/RPi-Distro/raspberrypi-sys-mods Description: System tweaks for the Raspberry Pi, DietPi edition _EOF_ G_CONFIG_INJECT 'Installed-Size: ' "Installed-Size: $(du -sk raspberrypi-sys-mods | mawk '{print $1}')" raspberrypi-sys-mods/DEBIAN/control diff --git a/.build/software/shairport-sync/build.bash b/.build/software/shairport-sync/build.bash index 37ca209a36..98437febff 100755 --- a/.build/software/shairport-sync/build.bash +++ b/.build/software/shairport-sync/build.bash @@ -539,16 +539,13 @@ Package: $name-airplay2 Version: $version-$suffix Architecture: $(dpkg --print-architecture) Maintainer: MichaIng -Date: $(date -u '+%a, %d %b %Y %T %z') -Standards-Version: 4.6.2.0 +Date: $(date -uR) Installed-Size: $(du -sk "$DIR" | mawk '{print $1}') Depends:$DEPS_APT_VERSIONED Conflicts: $name Section: sound Priority: optional Homepage: $repo -Vcs-Git: $repo.git -Vcs-Browser: $repo Description: AirPlay audio player Plays audio streamed from iTunes, iOS devices and third-party AirPlay sources such as ForkedDaapd and others. Audio played by a Shairport diff --git a/.build/software/squeezelite/build.bash b/.build/software/squeezelite/build.bash index ab6c717d89..a21169ae0b 100755 --- a/.build/software/squeezelite/build.bash +++ b/.build/software/squeezelite/build.bash @@ -164,16 +164,13 @@ Package: squeezelite Version: $version-$suffix Architecture: $(dpkg --print-architecture) Maintainer: MichaIng -Date: $(date -u '+%a, %d %b %Y %T %z') -Standards-Version: 4.6.2.0 +Date: $(date -uR) Installed-Size: $(du -sk "$DIR" | mawk '{print $1}') Depends:$DEPS_APT_VERSIONED Conflicts: squeezelite-pa, squeezelite-pulseaudio Section: sound Priority: optional Homepage: https://github.com/ralph-irving/squeezelite -Vcs-Git: https://github.com/ralph-irving/squeezelite.git -Vcs-Browser: https://github.com/ralph-irving/squeezelite Description: lightweight headless Squeezebox emulator - ALSA version Squeezelite is a small headless Squeezebox emulator. It is aimed at supporting high quality audio including USB DAC based output at multiple diff --git a/.build/software/vaultwarden/build.bash b/.build/software/vaultwarden/build.bash index ce68c4bc55..5948118d08 100755 --- a/.build/software/vaultwarden/build.bash +++ b/.build/software/vaultwarden/build.bash @@ -227,15 +227,12 @@ Package: vaultwarden Version: $version Architecture: $(dpkg --print-architecture) Maintainer: MichaIng -Date: $(date -u '+%a, %d %b %Y %T %z') -Standards-Version: 4.6.2.0 +Date: $(date -uR) Installed-Size: $(du -sk "$DIR" | mawk '{print $1}') Depends:$DEPS_APT_VERSIONED Section: misc Priority: optional Homepage: https://github.com/dani-garcia/vaultwarden -Vcs-Git: https://github.com/dani-garcia/vaultwarden.git -Vcs-Browser: https://github.com/dani-garcia/vaultwarden Description: Alternative implementation of the Bitwarden server API written in Rust and compatible with upstream Bitwarden clients, perfect for self-hosted deployment where running the official resource-heavy service might not be ideal. diff --git a/.build/software/ympd/build.bash b/.build/software/ympd/build.bash index e0a6cc11f1..824b7a4ae0 100644 --- a/.build/software/ympd/build.bash +++ b/.build/software/ympd/build.bash @@ -157,15 +157,12 @@ Package: ympd Version: $version-$suffix Architecture: $(dpkg --print-architecture) Maintainer: MichaIng -Date: $(date -u '+%a, %d %b %Y %T %z') -Standards-Version: 4.6.2.0 +Date: $(date -uR) Installed-Size: $(du -sk "$DIR" | mawk '{print $1}') Depends:$DEPS_APT_VERSIONED Section: sound Priority: optional Homepage: https://github.com/SuperBFG7/ympd -Vcs-Git: https://github.com/SuperBFG7/ympd.git -Vcs-Browser: https://github.com/SuperBFG7/ympd Description: Standalone MPD Web GUI written in C, utilizing Websockets and Bootstrap/JS _EOF_ G_CONFIG_INJECT 'Installed-Size: ' "Installed-Size: $(du -sk "$DIR" | mawk '{print $1}')" "$DIR/DEBIAN/control" From 7a7f8f9a814ce9ff4333e8661757c37317719fdf Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 12 Apr 2024 15:27:47 +0200 Subject: [PATCH 105/266] v9.3 - CI | Add support for 64-bit time_t transition on Sid for all builds: https://bugs.debian.org/1065394 --- .build/software/gmediarender/build.bash | 5 ++++- .build/software/shairport-sync/build.bash | 7 ++++++- .build/software/ympd/build.bash | 5 ++++- 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/.build/software/gmediarender/build.bash b/.build/software/gmediarender/build.bash index 1b276f857f..b6bc41ccb8 100755 --- a/.build/software/gmediarender/build.bash +++ b/.build/software/gmediarender/build.bash @@ -9,7 +9,8 @@ adeps=('libc6' 'gstreamer1.0-alsa' 'gstreamer1.0-libav' 'gstreamer1.0-plugins-go (( $G_DISTRO > 7 )) && adeps+=('libupnp17') || adeps+=('libupnp13') for i in "${adeps[@]}" do - dpkg-query -s "$i" &> /dev/null && continue + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || dpkg-query -s "${i}t64" &> /dev/null && continue G_DIETPI-NOTIFY 1 "Expected dependency package was not installed: $i" exit 1 done @@ -163,6 +164,8 @@ find "$DIR" ! \( -path "$DIR/DEBIAN" -prune \) -type f -exec md5sum {} + | sed " DEPS_APT_VERSIONED= for i in "${adeps[@]}" do + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || i+='t64' DEPS_APT_VERSIONED+=" $i (>= $(dpkg-query -Wf '${VERSION}' "$i"))," done DEPS_APT_VERSIONED=${DEPS_APT_VERSIONED%,} diff --git a/.build/software/shairport-sync/build.bash b/.build/software/shairport-sync/build.bash index 98437febff..5792ea41e4 100755 --- a/.build/software/shairport-sync/build.bash +++ b/.build/software/shairport-sync/build.bash @@ -22,7 +22,8 @@ case $G_DISTRO in esac for i in "${adeps[@]}" "${adeps2[@]}" do - dpkg-query -s "$i" &> /dev/null && continue + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || dpkg-query -s "${i}t64" &> /dev/null && continue G_DIETPI-NOTIFY 1 "Expected dependency package was not installed: $i" exit 1 done @@ -348,6 +349,8 @@ find "$DIR" ! \( -path "$DIR/DEBIAN" -prune \) -type f -exec md5sum {} + | sed " DEPS_APT_VERSIONED= for i in "${adeps[@]}" do + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || i+='t64' DEPS_APT_VERSIONED+=" $i (>= $(dpkg-query -Wf '${VERSION}' "$i"))," done DEPS_APT_VERSIONED=${DEPS_APT_VERSIONED%,} @@ -528,6 +531,8 @@ find "$DIR" ! \( -path "$DIR/DEBIAN" -prune \) -type f -exec md5sum {} + | sed " # - Obtain DEB dependency versions for i in "${adeps2[@]}" do + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || i+='t64' DEPS_APT_VERSIONED+=", $i (>= $(dpkg-query -Wf '${VERSION}' "$i"))" done # shellcheck disable=SC2001 diff --git a/.build/software/ympd/build.bash b/.build/software/ympd/build.bash index 824b7a4ae0..806c17368b 100644 --- a/.build/software/ympd/build.bash +++ b/.build/software/ympd/build.bash @@ -15,7 +15,8 @@ case $G_DISTRO in esac for i in "${adeps[@]}" do - dpkg-query -s "$i" &> /dev/null && continue + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || dpkg-query -s "${i}t64" &> /dev/null && continue G_DIETPI-NOTIFY 1 "Expected dependency package was not installed: $i" exit 1 done @@ -137,6 +138,8 @@ find "$DIR" ! \( -path "$DIR/DEBIAN" -prune \) -type f -exec md5sum {} + | sed " DEPS_APT_VERSIONED= for i in "${adeps[@]}" do + # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 + dpkg-query -s "$i" &> /dev/null || i+='t64' DEPS_APT_VERSIONED+=" $i (>= $(dpkg-query -Wf '${VERSION}' "$i"))," done DEPS_APT_VERSIONED=${DEPS_APT_VERSIONED%,} From 768a3d2c37875b35e709a8d4958983da82da128a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 12 Apr 2024 15:42:26 +0200 Subject: [PATCH 106/266] v9.3 - DietPi-Software | UnRAR: The non-free package is now available for RISC-V: https://packages.debian.org/sid/unrar --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index c60eb91df6..7d018a2383 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3082,8 +3082,8 @@ unix_socket_directories = '/run/postgresql'" > "$i/00dietpi.conf" if To_Install 170 # UnRAR then - # On Raspbian and for RISC-V, only "unrar-free" is available which does not support all RAR formats, thus we use "unrar" [non-free] from Debian on ARMv7+ models: http://raspbian.raspberrypi.com/raspbian/pool/non-free/u/unrar-nonfree/, https://deb.debian.org/debian-ports/pool/non-free/u/unrar-nonfree/ - if (( $G_HW_ARCH == 1 || $G_HW_ARCH == 11 )) + # On Raspbian, only "unrar-free" is available which does not support all RAR formats, thus we use "unrar" [non-free] from Debian on ARMv7+ models: http://raspbian.raspberrypi.com/raspbian/pool/non-free/u/unrar-nonfree/ + if (( $G_HW_ARCH == 1 )) then G_AGI unrar-free From 681cfe2d0748c6594d7e0bb1d862b3f8eabe3d1a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 13 Apr 2024 17:15:58 +0200 Subject: [PATCH 107/266] v9.3 - DietPi-Software | Update some fallback URL and versions --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 26 +++++++++++++------------- 2 files changed, 14 insertions(+), 13 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 1769450b1d..d5374390e5 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,6 +6,7 @@ New images: Enhancements: - DietPi-Config | Removed the 3.5mm audio option on Raspberry Pi 5, as it does not have a 3.5mm jack. Additionally, the KMS graphics driver is enabled OOTB when HDMI audio is selected, as the snd_bcm2835 driver does not work on Raspberry Pi 5. Many thanks to @JRK0469 for making us aware of this: https://dietpi.com/forum/t/19760 - DietPi-Software | Mosquitto: The official APT repository added support for 64-bit ARM on Bookworm, which is now used for our installation. +- DietPi-Software | UnRAR: Debian added unrar packages for RISC-V, which are now used for our installation. Bug fixes: - Raspberry Pi 5 | Fixed X11/desktop startup if KMS is enabled. Many thanks to @denguido for reporting the issue and solution: https://dietpi.com/forum/t/19760 diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 7d018a2383..6219ae9cfd 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -4140,8 +4140,8 @@ _EOF_ esac # Download latest version - local version=$(curl -sSfL 'https://dist.ipfs.io/go-ipfs/versions' | tail -1) - [[ $version ]] || { version='v0.20.0'; G_DIETPI-NOTIFY 1 "Automatic latest ${aSOFTWARE_NAME[$software_id]} version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } + local version=$(curl -sSfL 'https://dist.ipfs.io/go-ipfs/versions' | sed '/-rc[0-9]*$/d' | tail -1) + [[ $version ]] || { version='v0.27.0'; G_DIETPI-NOTIFY 1 "Automatic latest ${aSOFTWARE_NAME[$software_id]} version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } Download_Install "https://dist.ipfs.io/go-ipfs/$version/go-ipfs_${version}_linux-$arch.tar.gz" # Install @@ -4192,7 +4192,7 @@ _EOF_ if To_Install 16 # microblog.pub then local micro_name='microblog-pub' - local micro_python_version='3.11.4' # https://github.com/pyenv/pyenv/tree/master/plugins/python-build/share/python-build + local micro_python_version='3.12.3' # https://github.com/pyenv/pyenv/tree/master/plugins/python-build/share/python-build local micro_pyenv_dir="/opt/$micro_name" local micro_pyenv_activate_file="$micro_pyenv_dir/pyenv-activate.sh" local micro_virtualenv="$micro_pyenv_dir/.virtual_path" @@ -5287,7 +5287,7 @@ _EOF_ local arch=$(dpkg --print-architecture) local version=$(curl -sSfL 'https://hndl.urbackup.org/Server/' | grep -Pwo '(?<=href=")[0-9.]+(?=/")' | sort -Vr | head -1) local file=$(curl -sSfL "https://hndl.urbackup.org/Server/$version/" | grep -Pwom1 "(?<=href=\")urbackup-server_${version}_$arch\.deb(?=\")") - local fallback_url="https://hndl.urbackup.org/Server/2.5.31/urbackup-server_2.5.31_$arch.deb" + local fallback_url="https://hndl.urbackup.org/Server/2.5.33/urbackup-server_2.5.33_$arch.deb" Download_Install "${file:+https://hndl.urbackup.org/Server/$version/$file}" G_EXEC systemctl stop urbackupsrv unset -v backuppath arch version file @@ -6301,7 +6301,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.7.14/kavita-linux-$arch.tar.gz" + local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.8.0/kavita-linux-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Kareadita/Kavita/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/kavita-linux-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC chmod +x Kavita/Kavita @@ -6509,7 +6509,7 @@ _EOF_ esac # Download - local fallback_url="https://github.com/fatedier/frp/releases/download/v0.56.0/frp_0.56.0_linux_$arch.tar.gz" + local fallback_url="https://github.com/fatedier/frp/releases/download/v0.57.0/frp_0.57.0_linux_$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/fatedier/frp/releases/latest' | mawk -F\" "/\"browser_download_url\": .*\/frp_[0-9.]*_linux_$arch\.tar\.gz\"/{print \$4}")" G_EXEC cd frp_* @@ -6896,7 +6896,7 @@ _EOF_ if To_Install 98 haproxy # HAProxy then - local version='2.8.3' # https://www.haproxy.org/download/ + local version='2.9.7' # https://www.haproxy.org/download/ aDEPS=('make' 'gcc' 'libpcre3-dev' 'libssl-dev' 'zlib1g-dev' 'libsystemd-dev') Download_Install "https://www.haproxy.org/download/${version%.*}/src/haproxy-$version.tar.gz" @@ -8522,7 +8522,7 @@ _EOF_ # Install ruTorrent: Web UI for rTorrent # - Grab current version local version=$(curl -sSfL 'https://api.github.com/repos/Novik/ruTorrent/releases/latest' | mawk -F\" '/^ *"tag_name": "[^"]*",$/{print $4}') - [[ $version ]] || { version='v4.2.11'; G_DIETPI-NOTIFY 1 "Automatic latest ruTorrent version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } + [[ $version ]] || { version='v4.3.0'; G_DIETPI-NOTIFY 1 "Automatic latest ruTorrent version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } Download_Install "https://github.com/Novik/ruTorrent/archive/$version.tar.gz" # - Reinstall freshly with preserved configs and 3rd party plugins @@ -8913,7 +8913,7 @@ _EOF_ *) local arch='arm';; esac - local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.27.5/syncthing-linux-$arch-v1.27.5.tar.gz" + local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.27.6/syncthing-linux-$arch-v1.27.6.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/syncthing/syncthing/releases/latest' | mawk -F\" "/\"browser_download_url\": .*\/syncthing-linux-$arch-[^\"\/]*\.tar\.gz\"/{print \$4}")" G_EXEC mv syncthing-* /opt/syncthing fi @@ -9510,7 +9510,7 @@ _EOF_ esac url=$(curl -sSfL 'https://api.github.com/repos/Radarr/Radarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}") - local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.3.6.8612/Radarr.master.5.3.6.8612.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.4.6.8723/Radarr.master.5.4.6.8723.linux-core-$arch.tar.gz" fi Download_Install "$url" @@ -9607,7 +9607,7 @@ _EOF_ esac url=$(curl -sSfL 'https://api.github.com/repos/Lidarr/Lidarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}") - local fallback_url="https://github.com/Lidarr/Lidarr/releases/download/v2.1.7.4030/Lidarr.master.2.1.7.4030.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Lidarr/Lidarr/releases/download/v2.2.5.4141/Lidarr.master.2.2.5.4141.linux-core-$arch.tar.gz" fi Download_Install "$url" @@ -11133,7 +11133,7 @@ _EOF_ # v3 drops PHP 7.4 support: https://github.com/TasmoAdmin/TasmoAdmin/releases/tag/v3.0.0 if (( $G_DISTRO > 6 )) then - local fallback_url='https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v4.0.1/tasmoadmin_v4.0.1.tar.gz' + local fallback_url='https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v4.0.2/tasmoadmin_v4.0.2.tar.gz' Download_Install "$(curl -sSfL 'https://api.github.com/repos/TasmoAdmin/TasmoAdmin/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/tasmoadmin_v[^"\/]*\.tar\.gz"$/{print $4}')" else Download_Install 'https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v2.4.2/tasmoadmin_v2.4.2.tar.gz' @@ -11230,7 +11230,7 @@ _EOF_ local ha_user='homeassistant' local ha_home="/home/$ha_user" local ha_pyenv_activation=". $ha_home/pyenv-activate.sh" - local ha_python_version='3.12.1' # https://github.com/pyenv/pyenv/tree/master/plugins/python-build/share/python-build + local ha_python_version='3.12.3' # https://github.com/pyenv/pyenv/tree/master/plugins/python-build/share/python-build G_DIETPI-NOTIFY 2 "Home Assistant user: $ha_user" G_DIETPI-NOTIFY 2 "Home Assistant home: $ha_home" From 81791b4a809ba68cdddec21418405e174d76f420 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 13 Apr 2024 18:02:51 +0200 Subject: [PATCH 108/266] v9.3 - DietPi-Software | microblog.pub: Downgrade to latest Python 3.11 due to poetry/pyyaml error with 3.12: https://github.com/python-poetry/poetry/issues/8287 --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 6219ae9cfd..5198f0406a 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -4192,7 +4192,7 @@ _EOF_ if To_Install 16 # microblog.pub then local micro_name='microblog-pub' - local micro_python_version='3.12.3' # https://github.com/pyenv/pyenv/tree/master/plugins/python-build/share/python-build + local micro_python_version='3.11.9' # https://github.com/pyenv/pyenv/tree/master/plugins/python-build/share/python-build local micro_pyenv_dir="/opt/$micro_name" local micro_pyenv_activate_file="$micro_pyenv_dir/pyenv-activate.sh" local micro_virtualenv="$micro_pyenv_dir/.virtual_path" From ce51c98c4594a0cb156cbd7b94b4cdea729e0bb6 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 13 Apr 2024 18:04:58 +0200 Subject: [PATCH 109/266] v9.3 - RC up --- .update/version | 2 +- dietpi/func/dietpi-globals | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.update/version b/.update/version index 42b0f6b092..a54ce2d4d0 100644 --- a/.update/version +++ b/.update/version @@ -3,7 +3,7 @@ # Available DietPi version G_REMOTE_VERSION_CORE=9 G_REMOTE_VERSION_SUB=3 -G_REMOTE_VERSION_RC=-1 +G_REMOTE_VERSION_RC=0 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 7b6c58de0b..3f3cf3a3a1 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -55,7 +55,7 @@ # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=3 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=-1 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=0 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From 43f1b9a7e2903154eabde1b05e92e459427a67fc Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 13 Apr 2024 18:11:00 +0200 Subject: [PATCH 110/266] v8.3 - CHANGELOG | Remove new images category from v9.3 changelog --- CHANGELOG.txt | 2 -- 1 file changed, 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index d5374390e5..2d90214d98 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,8 +1,6 @@ v9.3 (2024-04-13) -New images: - Enhancements: - DietPi-Config | Removed the 3.5mm audio option on Raspberry Pi 5, as it does not have a 3.5mm jack. Additionally, the KMS graphics driver is enabled OOTB when HDMI audio is selected, as the snd_bcm2835 driver does not work on Raspberry Pi 5. Many thanks to @JRK0469 for making us aware of this: https://dietpi.com/forum/t/19760 - DietPi-Software | Mosquitto: The official APT repository added support for 64-bit ARM on Bookworm, which is now used for our installation. From 93b79163662d93da91e5d2326d78c352b049414e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 13 Apr 2024 21:21:33 +0200 Subject: [PATCH 111/266] v9.3 - DietPi-Patches | Remove obsolete rockchip64 upgrade from our server - DietPi-Installer | Remove obsolete rockchip64 kernel upgrades from our server --- .build/images/dietpi-installer | 5 ++--- .update/patches | 14 +------------- 2 files changed, 3 insertions(+), 16 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 9c0b8d9a9e..4485fb1e5b 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1151,14 +1151,13 @@ _EOF_ G_AGI initramfs-tools u-boot-tools armbian-firmware "${zstd[@]}" [[ ${zstd[0]} ]] && G_CONFIG_INJECT 'COMPRESS=' 'COMPRESS=zstd' /etc/initramfs-tools/initramfs.conf # Download and pre-install kernel hosted on dietpi.com where the Armbian APT repo provides a too old version - # - NanoPi R4S: Solve Ethernet adapter disappearing on soft reboot: https://github.com/MichaIng/DietPi/issues/6342 - if [[ ( $G_HW_MODEL == 72 && $HW_VARIANT == 2 ) || $G_HW_MODEL =~ ^(47|76|83)$ ]] + if (( $G_HW_MODEL == 83 )) then G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb "https://dietpi.com/downloads/binaries/linux-image-$branch-$kernel.deb" G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb "https://dietpi.com/downloads/binaries/linux-dtb-$branch-$kernel.deb" G_EXEC_OUTPUT=1 G_EXEC curl -fo package3.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' local uboot=() - [[ $G_HW_MODEL == 76 || ( $G_HW_MODEL == 83 && $HW_VARIANT == 1 ) ]] && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package4.deb "https://dietpi.com/downloads/binaries/linux-u-boot-$model-$branch.deb"; uboot=('package4.deb'); } + #(( $G_HW_MODEL == 83 )) && (( $HW_VARIANT == 1 )) && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package4.deb "https://dietpi.com/downloads/binaries/linux-u-boot-$model-$branch.deb"; uboot=('package4.deb'); } G_EXEC_OUTPUT=1 G_EXEC dpkg -i package1.deb package2.deb package3.deb "${uboot[@]}" G_EXEC rm package1.deb package2.deb package3.deb "${uboot[@]}" fi diff --git a/.update/patches b/.update/patches index 8c714aa78c..a91e7e0954 100755 --- a/.update/patches +++ b/.update/patches @@ -1509,20 +1509,8 @@ map $arg_v $asset_immutable { Patch_9_2() { - # NanoPi R4S: Solve Ethernet adapter disappearing on soft reboot: https://github.com/MichaIng/DietPi/issues/6342 - if (( $G_HW_MODEL == 47 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-current-rockchip64 2> /dev/null)" lt-nl 24.2.0 - then - G_DIETPI-NOTIFY 2 'Updating NanoPi R4S kernel ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb 'https://dietpi.com/downloads/binaries/linux-image-current-rockchip64.deb' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb 'https://dietpi.com/downloads/binaries/linux-dtb-current-rockchip64.deb' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package3.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' - local headers=() - dpkg-query -s 'linux-headers-current-rockchip64' &> /dev/null && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package4.deb 'https://dietpi.com/downloads/binaries/linux-headers-current-rockchip64.deb'; headers=('package4.deb'); } - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package1.deb package2.deb package3.deb "${headers[@]}" - G_EXEC rm package1.deb package2.deb package3.deb "${headers[@]}" - # Quartz64 - elif (( $G_HW_MODEL == 49 )) + if (( $G_HW_MODEL == 49 )) then for i in quartz64{a,b} soquartz do From 924fb20020013952cd8c5515a467dfaaa55836dc Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 13 Apr 2024 21:34:09 +0200 Subject: [PATCH 112/266] v9.3 - DietPi-Installer | Some cleanup --- .build/images/dietpi-installer | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 4485fb1e5b..149af68314 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1194,7 +1194,7 @@ _EOF_ elif (( $G_HW_MODEL == 74 )) then G_AGI device-tree-compiler - [[ -d '/boot/overlay-user' ]] || G_EXEC mkdir /boot/overlay-user + G_EXEC mkdir -p /boot/overlay-user cat << '_EOF_' > /boot/overlay-user/dietpi-usb-otg.dts /dts-v1/; /plugin/; @@ -1285,6 +1285,14 @@ _EOF_ [[ -f '/etc/apt/trusted.gpg' ]] && G_EXEC rm /etc/apt/trusted.gpg [[ -f '/etc/apt/trusted.gpg~' ]] && G_EXEC rm '/etc/apt/trusted.gpg~' + # Skip creating kernel symlinks and remove existing ones + if [[ -L '/vmlinuz' ]] + then + G_DIETPI-NOTIFY 2 'Preventing obsolete kernel and initramfs symlink generation' + G_EXEC eval 'echo '\''do_symlinks=0'\'' > /etc/kernel-img.conf' + G_EXEC rm -f /{initrd.img,vmlinuz}{,.old} + fi + # Quartz64 elif [[ $G_HW_MODEL == 49 && $(findmnt -Ufnro TARGET -T /boot) == '/' ]] then @@ -1476,10 +1484,6 @@ _EOF_ if dpkg-query -s 'armbian-firmware' &> /dev/null then aPACKAGES_REQUIRED_INSTALL+=('armbian-firmware') - - elif dpkg-query -s 'orangepi-firmware' &> /dev/null - then - aPACKAGES_REQUIRED_INSTALL+=('orangepi-firmware') else aPACKAGES_REQUIRED_INSTALL+=('firmware-linux-free') # Free misc aPACKAGES_REQUIRED_INSTALL+=('firmware-misc-nonfree') # Non-free misc incl. Ralink and MediaTek WiFi/BT From ec9206f337856c371486d0cf8a67b3156a1cc081 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 14 Apr 2024 14:57:09 +0200 Subject: [PATCH 113/266] v9.3 - General | Remove trailing slash from APT repos, which are redundant and removed internally. It can make sense for complete (dir) URLs to avoid a redirect, but APT repo URLs are never called as is but final "Release" and "Packages" URLs created from them. We hence save those few bits. --- .build/images/dietpi-installer | 6 +++--- .update/pre-patches | 10 +++++----- dietpi.txt | 4 ++-- dietpi/dietpi-config | 28 ++++++++++++++-------------- dietpi/dietpi-software | 28 ++++++++++++++-------------- dietpi/func/dietpi-set_software | 8 ++++---- 6 files changed, 42 insertions(+), 42 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 149af68314..b21bf8f8eb 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -964,7 +964,7 @@ setenv rootuuid "true"' /boot/boot.cmd fi # Assure that dir for additional sources is present - [[ -d '/etc/apt/sources.list.d' ]] || G_EXEC mkdir /etc/apt/sources.list.d + G_EXEC mkdir -p /etc/apt/sources.list.d ### Kernel/bootloader/initramfs packages: We need to install those directly to allow G_AGA() autoremove possible older packages later: https://github.com/MichaIng/DietPi/issues/1285#issuecomment-354602594 @@ -1037,7 +1037,7 @@ _EOF_ # Remove obsolete lists G_EXEC rm -Rf /etc/apt/sources.list.d/* # Add Armbian repository - G_EXEC eval "echo 'deb https://apt.armbian.com/ ${DISTRO_TARGET_NAME/bullseye/bookworm} main' > /etc/apt/sources.list.d/dietpi-armbian.list" + G_EXEC eval "echo 'deb https://apt.armbian.com ${DISTRO_TARGET_NAME/bullseye/bookworm} main' > /etc/apt/sources.list.d/dietpi-armbian.list" # Update APT lists G_AGUP # Install kernel, device tree, U-Boot, firmware and initramfs packages @@ -1448,7 +1448,7 @@ _EOF_ # Remove obsolete components from Armbian list and connect via HTTPS G_EXEC rm -Rf /etc/apt/sources.list.d/{,.??,.[^.]}* - G_EXEC eval "echo 'deb https://apt.armbian.com/ $DISTRO_TARGET_NAME main' > /etc/apt/sources.list.d/dietpi-armbian.list" + G_EXEC eval "echo 'deb https://apt.armbian.com $DISTRO_TARGET_NAME main' > /etc/apt/sources.list.d/dietpi-armbian.list" # Skip creating kernel symlinks and remove existing ones if [[ -L '/vmlinuz' ]] diff --git a/.update/pre-patches b/.update/pre-patches index de6302c9bb..e650adb30e 100755 --- a/.update/pre-patches +++ b/.update/pre-patches @@ -161,7 +161,7 @@ fi if (( $G_DIETPI_VERSION_CORE < 8 || ( $G_DIETPI_VERSION_CORE == 8 && $G_DIETPI_VERSION_SUB < 11 ) )) && [[ -f '/etc/apt/sources.list.d/grafana.list' ]] then G_DIETPI-NOTIFY 2 'Updating Grafana APT list to use the new repository: https://grafana.com/docs/grafana/latest/setup-grafana/installation/debian/#repository-migration-november-8th-2022' - G_EXEC eval "echo 'deb https://apt.grafana.com/ stable main' > /etc/apt/sources.list.d/grafana.list" + G_EXEC eval "echo 'deb https://apt.grafana.com stable main' > /etc/apt/sources.list.d/grafana.list" fi # v8.13 @@ -283,14 +283,14 @@ then if (( $G_HW_ARCH == 11 )) then G_DIETPI-NOTIFY 2 'Migrating from Debian ports to regular Debian Sid repository, which now supports RISC-V' - G_EXEC eval 'echo '\''deb https://deb.debian.org/debian/ sid main contrib non-free non-free-firmware'\'' > /etc/apt/sources.list' + G_EXEC eval 'echo '\''deb https://deb.debian.org/debian sid main contrib non-free non-free-firmware'\'' > /etc/apt/sources.list' dpkg-query -s 'debian-ports-archive-keyring' &> /dev/null && G_EXEC apt-mark auto debian-ports-archive-keyring # RPi/ARMv6 container Bookworm elif [[ $G_DISTRO -ge 7 && -f '/etc/apt/sources.list.d/raspi.list' ]] then G_DIETPI-NOTIFY 2 'Migrating RPi APT repository to Bookworm' - G_EXEC eval 'echo '\''deb https://archive.raspberrypi.com/debian/ bookworm main'\'' > /etc/apt/sources.list.d/raspi.list' + G_EXEC eval 'echo '\''deb https://archive.raspberrypi.com/debian bookworm main'\'' > /etc/apt/sources.list.d/raspi.list' G_DIETPI-NOTIFY 2 'Removing faulty non-free-firmware component if present' (( $G_RASPBIAN )) && G_EXEC sed --follow-symlinks -i 's/ non-free-firmware$//' /etc/apt/sources.list @@ -395,11 +395,11 @@ fi # v9.3 if (( $G_DIETPI_VERSION_CORE < 9 || ( $G_DIETPI_VERSION_CORE == 9 && $G_DIETPI_VERSION_SUB < 3 ) )) then - # Update APT repo on Bullseye systems to Bookworm, but re-assure only kernel and firmware packages are pulled form it. Armbian dropped Bullseye support + # Update APT repo on Bullseye systems to Bookworm, but re-assure only kernel and firmware packages are pulled form it. Armbian dropped Bullseye support. if [[ $G_DISTRO == 6 && -f '/etc/apt/sources.list.d/dietpi-armbian.list' ]] then G_DIETPI-NOTIFY 2 'Moving EOL Armbian Bullseye repo to Bookworm for Debian-version-agnostic firmware and kernel upgrades' - cat << '_EOF_' > /etc/apt/preferences.d/dietpi-armbian + cat << '_EOF_' > /etc/apt/preferences.d/dietpi-armbian || exit 1 Package: * Pin: origin apt.armbian.com Pin-Priority: -1 diff --git a/dietpi.txt b/dietpi.txt index fdd5e82a8e..0a2d49965c 100644 --- a/dietpi.txt +++ b/dietpi.txt @@ -219,9 +219,9 @@ CONFIG_ENABLE_IPV6=1 # APT mirrors which are applied to /etc/apt/sources.list | Values here will also be applied during 1st run setup # - Raspbian: https://www.raspbian.org/RaspbianMirrors -CONFIG_APT_RASPBIAN_MIRROR=http://raspbian.raspberrypi.com/raspbian/ +CONFIG_APT_RASPBIAN_MIRROR=http://raspbian.raspberrypi.com/raspbian # - Debian: https://www.debian.org/mirror/official#list -CONFIG_APT_DEBIAN_MIRROR=https://deb.debian.org/debian/ +CONFIG_APT_DEBIAN_MIRROR=https://deb.debian.org/debian # NTP server(s) applied to /etc/systemd/timesyncd.conf # - "default": Use the NTP server(s) provided via DHCP, else the debian.pool.ntp.org NTP pool. diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index e586907567..549a17b264 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -3864,23 +3864,23 @@ Additional benchmarks: if (( $G_RASPBIAN )) then local mirror_list='https://www.raspbian.org/RaspbianMirrors/' - G_WHIP_MENU_ARRAY+=('http://raspbian.raspberrypi.org/raspbian/' ': Global mirror director (default)') - G_WHIP_MENU_ARRAY+=('https://mirror.ox.ac.uk/sites/archive.raspbian.org/archive/raspbian/' ': UK') - G_WHIP_MENU_ARRAY+=('https://mirror.netcologne.de/raspbian/raspbian/' ': Germany') - G_WHIP_MENU_ARRAY+=('https://mirror.umd.edu/raspbian/raspbian/' ': USA') - G_WHIP_MENU_ARRAY+=('https://mirrors.ustc.edu.cn/raspbian/raspbian/' ': China') - G_WHIP_MENU_ARRAY+=('http://raspbian.mirror.digitalpacific.com.au/raspbian/' ': Australia') + G_WHIP_MENU_ARRAY+=('http://raspbian.raspberrypi.org/raspbian' ': Global mirror director (default)') + G_WHIP_MENU_ARRAY+=('https://mirror.ox.ac.uk/sites/archive.raspbian.org/archive/raspbian' ': UK') + G_WHIP_MENU_ARRAY+=('https://mirror.netcologne.de/raspbian/raspbian' ': Germany') + G_WHIP_MENU_ARRAY+=('https://mirror.umd.edu/raspbian/raspbian' ': USA') + G_WHIP_MENU_ARRAY+=('https://mirrors.ustc.edu.cn/raspbian/raspbian' ': China') + G_WHIP_MENU_ARRAY+=('http://raspbian.mirror.digitalpacific.com.au/raspbian' ': Australia') # Debian else local mirror_list='https://www.debian.org/mirror/list' - G_WHIP_MENU_ARRAY+=('https://deb.debian.org/debian/' ': Global mirror director (default)') - G_WHIP_MENU_ARRAY+=('https://ftp.debian.org/debian/' ': Global') - G_WHIP_MENU_ARRAY+=('http://ftp.uk.debian.org/debian/' ': UK') - G_WHIP_MENU_ARRAY+=('http://ftp.de.debian.org/debian/' ': Germany') - G_WHIP_MENU_ARRAY+=('http://ftp.us.debian.org/debian/' ': USA') - G_WHIP_MENU_ARRAY+=('http://ftp.cn.debian.org/debian/' ': China') - G_WHIP_MENU_ARRAY+=('http://ftp.au.debian.org/debian/' ': Australia') + G_WHIP_MENU_ARRAY+=('https://deb.debian.org/debian' ': Global mirror director (default)') + G_WHIP_MENU_ARRAY+=('https://ftp.debian.org/debian' ': Global') + G_WHIP_MENU_ARRAY+=('http://ftp.uk.debian.org/debian' ': UK') + G_WHIP_MENU_ARRAY+=('http://ftp.de.debian.org/debian' ': Germany') + G_WHIP_MENU_ARRAY+=('http://ftp.us.debian.org/debian' ': USA') + G_WHIP_MENU_ARRAY+=('http://ftp.cn.debian.org/debian' ': China') + G_WHIP_MENU_ARRAY+=('http://ftp.au.debian.org/debian' ': Australia') fi G_WHIP_DEFAULT_ITEM=$apt_mirror_current @@ -3889,7 +3889,7 @@ Additional benchmarks: if [[ $G_WHIP_RETURNED_VALUE == 'Custom' ]] then G_WHIP_DEFAULT_ITEM=$apt_mirror_current - G_WHIP_INPUTBOX 'Please enter a new APT mirror, e.g. https://ftp.debian.org/debian/' || continue + G_WHIP_INPUTBOX 'Please enter a new APT mirror, e.g. https://ftp.debian.org/debian' || continue fi /boot/dietpi/func/dietpi-set_software apt-mirror "$G_WHIP_RETURNED_VALUE" || { failure='[FAILED] An internal error occurred, please report this issue to:\n - https://github.com/MichaIng/DietPi/issues\n\n'; continue; } diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 5198f0406a..121e3edf55 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3041,7 +3041,7 @@ unix_socket_directories = '/run/postgresql'" > "$i/00dietpi.conf" # - On Raspbian use separate suite: https://github.com/MichaIng/DietPi/issues/1023 local suite='buster' (( $G_RASPBIAN )) && suite='raspbianbuster' - G_EXEC eval "echo 'deb https://download.mono-project.com/repo/debian/ $suite main' > /etc/apt/sources.list.d/dietpi-mono.list" + G_EXEC eval "echo 'deb https://download.mono-project.com/repo/debian $suite main' > /etc/apt/sources.list.d/dietpi-mono.list" G_AGUP # APT package @@ -5039,7 +5039,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-mopidy.gpg --yes" # APT list - G_EXEC eval "echo 'deb https://apt.mopidy.com/ ${G_DISTRO_NAME/bookworm/bullseye} main contrib non-free' > /etc/apt/sources.list.d/mopidy.list" + G_EXEC eval "echo 'deb https://apt.mopidy.com ${G_DISTRO_NAME/bookworm/bullseye} main contrib non-free' > /etc/apt/sources.list.d/mopidy.list" G_AGUP fi @@ -6695,7 +6695,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-mosquitto.gpg --yes" # APT list - G_EXEC eval "echo 'deb https://repo.mosquitto.org/debian/ $G_DISTRO_NAME main' > /etc/apt/sources.list.d/dietpi-mosquitto.list" + G_EXEC eval "echo 'deb https://repo.mosquitto.org/debian $G_DISTRO_NAME main' > /etc/apt/sources.list.d/dietpi-mosquitto.list" G_AGUP fi @@ -7293,7 +7293,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-influxdb.gpg --yes" # APT list - G_EXEC eval "echo 'deb https://repos.influxdata.com/debian/ ${G_DISTRO_NAME/bookworm/bullseye} stable' > /etc/apt/sources.list.d/influxdb.list" + G_EXEC eval "echo 'deb https://repos.influxdata.com/debian ${G_DISTRO_NAME/bookworm/bullseye} stable' > /etc/apt/sources.list.d/influxdb.list" G_AGUP # APT package @@ -7331,7 +7331,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-grafana.gpg --yes" # APT list - G_EXEC eval "echo 'deb https://apt.grafana.com/ stable main' > /etc/apt/sources.list.d/grafana.list" + G_EXEC eval "echo 'deb https://apt.grafana.com stable main' > /etc/apt/sources.list.d/grafana.list" G_AGUP # APT package @@ -7791,7 +7791,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-zerotier.gpg --yes" # APT list - G_EXEC eval "echo 'deb https://download.zerotier.com/debian/${G_DISTRO_NAME/trixie/bookworm}/ ${G_DISTRO_NAME/trixie/bookworm} main' > /etc/apt/sources.list.d/dietpi-zerotier.list" + G_EXEC eval "echo 'deb https://download.zerotier.com/debian/${G_DISTRO_NAME/trixie/bookworm} ${G_DISTRO_NAME/trixie/bookworm} main' > /etc/apt/sources.list.d/dietpi-zerotier.list" G_AGUP # APT package @@ -8285,7 +8285,7 @@ location = /.well-known/caldav { return 301 /baikal/html/dav.php; }' > /etc/ngi G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-plexmediaserver.gpg --yes" # APT list - G_EXEC eval 'echo '\''deb https://downloads.plex.tv/repo/deb/ public main'\'' > /etc/apt/sources.list.d/plexmediaserver.list' + G_EXEC eval 'echo '\''deb https://downloads.plex.tv/repo/deb public main'\'' > /etc/apt/sources.list.d/plexmediaserver.list' G_AGUP # APT package @@ -9408,7 +9408,7 @@ _EOF_ G_EXEC eval 'curl -sSf '\''https://keyserver.ubuntu.com/pks/lookup?search=0x2009837CBFFD68F45BC180471F4F90DE2A9B4BF8&op=get'\'' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-sonarr.gpg --yes' # APT list: Buster is the latest available suite: https://apt.sonarr.tv/debian/dists/ - G_EXEC eval 'echo '\''deb https://apt.sonarr.tv/debian/ buster main'\'' > /etc/apt/sources.list.d/sonarr.list' + G_EXEC eval 'echo '\''deb https://apt.sonarr.tv/debian buster main'\'' > /etc/apt/sources.list.d/sonarr.list' # Update package lists G_AGUP @@ -10029,7 +10029,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.22.2499/Readarr.develop.0.3.22.2499.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.23.2506/Readarr.develop.0.3.23.2506.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Readarr/Readarr/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}" | head -1)" G_EXEC mv Readarr /opt/readarr fi @@ -10372,7 +10372,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-docker.gpg --yes" # APT list - G_EXEC eval "echo 'deb https://download.docker.com/linux/$distro/ ${G_DISTRO_NAME/trixie/bookworm} stable' > /etc/apt/sources.list.d/docker.list" + G_EXEC eval "echo 'deb https://download.docker.com/linux/$distro ${G_DISTRO_NAME/trixie/bookworm} stable' > /etc/apt/sources.list.d/docker.list" G_AGUP # APT package name @@ -10766,7 +10766,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-raspotify.gpg --yes" # APT list - G_EXEC eval 'echo '\''deb https://dtcooper.github.io/raspotify/ raspotify main'\'' > /etc/apt/sources.list.d/raspotify.list' + G_EXEC eval 'echo '\''deb https://dtcooper.github.io/raspotify raspotify main'\'' > /etc/apt/sources.list.d/raspotify.list' G_AGUP # APT package @@ -10927,7 +10927,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-jellyfin.gpg --yes" # APT list - G_EXEC eval "echo 'deb https://repo.jellyfin.org/debian/ $G_DISTRO_NAME main' > /etc/apt/sources.list.d/dietpi-jellyfin.list" + G_EXEC eval "echo 'deb https://repo.jellyfin.org/debian $G_DISTRO_NAME main' > /etc/apt/sources.list.d/dietpi-jellyfin.list" G_AGUP # APT meta package: Server, web component and FFmpeg implementation @@ -11077,7 +11077,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-moonlight.gpg --yes" # APT list - G_EXEC eval "echo 'deb https://dl.cloudsmith.io/public/moonlight-game-streaming/moonlight-embedded/deb/raspbian/ ${G_DISTRO_NAME/trixie/bookworm} main' > /etc/apt/sources.list.d/dietpi-moonlight.list" + G_EXEC eval "echo 'deb https://dl.cloudsmith.io/public/moonlight-game-streaming/moonlight-embedded/deb/raspbian ${G_DISTRO_NAME/trixie/bookworm} main' > /etc/apt/sources.list.d/dietpi-moonlight.list" G_AGUP # APT deps @@ -11099,7 +11099,7 @@ _EOF_ G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-moonlight-qt.gpg --yes" # APT list - G_EXEC eval "echo 'deb https://dl.cloudsmith.io/public/moonlight-game-streaming/moonlight-qt/deb/raspbian/ ${G_DISTRO_NAME/trixie/bookworm} main' > /etc/apt/sources.list.d/dietpi-moonlight-qt.list" + G_EXEC eval "echo 'deb https://dl.cloudsmith.io/public/moonlight-game-streaming/moonlight-qt/deb/raspbian ${G_DISTRO_NAME/trixie/bookworm} main' > /etc/apt/sources.list.d/dietpi-moonlight-qt.list" G_AGUP # Install: libgl1 required, else start from console prints "SDL Error: Can't load EGL/GL library on window creation.", the GUI says it cannot find a video decoder and streaming does not start. diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 93e7b1fb27..50c9abb995 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -114,17 +114,17 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R [[ $INPUT_MODE_VALUE ]] || { Unknown_Input_Mode; return 1; } # RPi Trixie: Suite does not exist yet: https://archive.raspberrypi.com/debian/dists/ - (( $G_HW_MODEL < 10 || ( $G_HW_MODEL == 75 && ${G_RASPBIAN:-0} == 1 ) )) && G_EXEC eval "echo 'deb https://archive.raspberrypi.com/debian/ ${G_DISTRO_NAME/trixie/bookworm} main' > /etc/apt/sources.list.d/raspi.list" + (( $G_HW_MODEL < 10 || ( $G_HW_MODEL == 75 && ${G_RASPBIAN:-0} == 1 ) )) && G_EXEC eval "echo 'deb https://archive.raspberrypi.com/debian ${G_DISTRO_NAME/trixie/bookworm} main' > /etc/apt/sources.list.d/raspi.list" # RISC-V: Provided via Sid only if (( $G_HW_ARCH == 11 )) then - G_EXEC eval 'echo '\''deb https://deb.debian.org/debian/ sid main contrib non-free non-free-firmware'\'' > /etc/apt/sources.list' + G_EXEC eval 'echo '\''deb https://deb.debian.org/debian sid main contrib non-free non-free-firmware'\'' > /etc/apt/sources.list' # Raspbian elif (( $G_RASPBIAN )) then - [[ $INPUT_MODE_VALUE == 'default' ]] && INPUT_MODE_VALUE='http://raspbian.raspberrypi.com/raspbian/' + [[ $INPUT_MODE_VALUE == 'default' ]] && INPUT_MODE_VALUE='http://raspbian.raspberrypi.com/raspbian' G_EXEC eval "echo 'deb $INPUT_MODE_VALUE $G_DISTRO_NAME main contrib non-free' > /etc/apt/sources.list" @@ -137,7 +137,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R G_EXEC eval "echo 'deb $INPUT_MODE_VALUE $G_DISTRO_NAME main contrib non-free deb $INPUT_MODE_VALUE $G_DISTRO_NAME-updates main contrib non-free -deb https://deb.debian.org/debian-security/ $G_DISTRO_NAME-security main contrib non-free +deb https://deb.debian.org/debian-security $G_DISTRO_NAME-security main contrib non-free deb $INPUT_MODE_VALUE $G_DISTRO_NAME-backports main contrib non-free' > /etc/apt/sources.list" # Bookworm: non-free firmware has been moved to new component: https://deb.debian.org/debian/pool/ From 32d8d41bfb6b8af39e0f22329d946afbf7bdf557 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 14 Apr 2024 17:02:39 +0200 Subject: [PATCH 114/266] v9.3 - General | We added an own APT repository for own software and kernel/firmware builds. This simplifies updates for software packages like Squeezelite, vaultwarden and Amiberry, as well as allows us to provide own up-to-date kernel and bootloader packages, applied via regular "apt upgrade". A goal is also to become independent of some 3rd party repositories, which are regularly affected by network errors or provide packages updates too infrequently. --- .build/images/dietpi-installer | 2 +- .update/patches | 71 +++------------------------------ CHANGELOG.txt | 1 + dietpi/func/dietpi-set_software | 57 ++++++++++++++++++++++++++ 4 files changed, 65 insertions(+), 66 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index b21bf8f8eb..66fc2b9bee 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -816,7 +816,7 @@ setenv rootuuid "true"' /boot/boot.cmd G_DIETPI-NOTIFY 2 "Setting APT sources.list: $DISTRO_TARGET_NAME $DISTRO_TARGET" # We need to forward $DISTRO_TARGET* to dietpi-set_software, as well as $G_HW_MODEL + $G_RASPBIAN for Debian vs Raspbian decision. - G_DISTRO=$DISTRO_TARGET G_DISTRO_NAME=$DISTRO_TARGET_NAME G_HW_ARCH=$G_HW_ARCH G_HW_MODEL=$G_HW_MODEL G_RASPBIAN=$G_RASPBIAN G_EXEC /boot/dietpi/func/dietpi-set_software apt-mirror default + G_DISTRO=$DISTRO_TARGET G_DISTRO_NAME=$DISTRO_TARGET_NAME G_HW_ARCH=$G_HW_ARCH G_HW_MODEL=$G_HW_MODEL G_RASPBIAN=$G_RASPBIAN HW_VARIANT=$HW_VARIANT G_EXEC /boot/dietpi/func/dietpi-set_software apt-mirror default # (Re)create DietPi runtime and logs dir, used by G_AGx G_EXEC mkdir -p /run/dietpi /var/tmp/dietpi/logs diff --git a/.update/patches b/.update/patches index a91e7e0954..603f27de3a 100755 --- a/.update/patches +++ b/.update/patches @@ -1314,16 +1314,8 @@ _EOF_ Patch_8_23() { - # RPi: Update raspberrypi-sys-mods: https://github.com/MichaIng/DietPi/issues/6666 - if (( $G_HW_MODEL < 10 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' raspberrypi-sys-mods 2> /dev/null)" lt-nl 2:20230510-dietpi2 - then - G_DIETPI-NOTIFY 2 'Updating raspberrypi-sys-mods package ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/raspberrypi-sys-mods.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb - # VisionFive 2 - elif (( $G_HW_MODEL == 81 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-visionfive2 2> /dev/null)" lt-nl 6.1.59-dietpi1 + if (( $G_HW_MODEL == 81 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-visionfive2 2> /dev/null)" lt-nl 6.1.59-dietpi1 then G_DIETPI-NOTIFY 2 'Updating RISC-V StarFive VisionFive 2 kernel ...' G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-visionfive2.deb' @@ -1404,19 +1396,6 @@ Patch_8_24() fi [[ -f '/etc/modprobe.d/dietpi-disable_bluetooth.conf' ]] || G_EXEC eval 'echo '\''sprdbt_tty'\'' > /etc/modules-load.d/dietpi-enable_bluetooth.conf' fi - - # Software updates and migrations - if [[ -f '/boot/dietpi/.installed' ]] - then - # Shairport Sync - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[37\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' shairport-sync 2> /dev/null)" lt 4.3.2-dietpi2 - then - G_DIETPI-NOTIFY 2 'Updating Shairport Sync package ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/shairport-sync_$G_HW_ARCH_NAME.deb" - G_AGI ./package.deb - G_EXEC rm package.deb - fi - fi } Patch_8_25() @@ -1509,36 +1488,6 @@ map $arg_v $asset_immutable { Patch_9_2() { - # Quartz64 - if (( $G_HW_MODEL == 49 )) - then - for i in quartz64{a,b} soquartz - do - dpkg --compare-versions "$(dpkg-query -Wf '${Version}' "firmware-$i" 2> /dev/null)" lt-nl 6.7.4-dietpi1 || continue - G_DIETPI-NOTIFY 2 "Updating $i kernel and bootloader ..." - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/firmware-$i.deb" - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb - break - done - - # VisionFive 2 - elif (( $G_HW_MODEL == 81 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-visionfive2 2> /dev/null)" lt-nl 6.1.81-dietpi1 - then - G_DIETPI-NOTIFY 2 'Updating RISC-V StarFive VisionFive 2 kernel ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-visionfive2.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb - - # Star64 - elif (( $G_HW_MODEL == 84 )) && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' linux-image-star64 2> /dev/null)" lt-nl 6.1.81-dietpi1 - then - G_DIETPI-NOTIFY 2 'Updating RISC-V PINE64 Star64 kernel ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-image-star64.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i --force-confdef,confold package.deb - G_EXEC rm package.deb - fi - # Software updates and migrations if [[ -f '/boot/dietpi/.installed' ]] then @@ -1565,15 +1514,6 @@ Patch_9_2() fi fi - # Squeezelite - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' squeezelite 2> /dev/null)" lt 2.0.0-1468-dietpi1 - then - G_DIETPI-NOTIFY 2 'Updating Squeezelite package ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/squeezelite_$G_HW_ARCH_NAME.deb" - G_AGI ./package.deb - G_EXEC rm package.deb - fi - # vaultwarden if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[183\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' vaultwarden 2> /dev/null)" lt 1.30.5-dietpi1 then @@ -1583,10 +1523,6 @@ Patch_9_2() G_EXEC rm -R /opt/vaultwarden [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service fi - G_DIETPI-NOTIFY 2 'Updating vaultwarden package ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" - G_AGI ./package.deb - G_EXEC rm package.deb fi # Amiberry @@ -1602,6 +1538,11 @@ Patch_9_3() { # Purge ancient vmtouch which prevents /boot from being unmounted e.g. for RPi firmware migration: https://github.com/MichaIng/DietPi/issues/6819, https://github.com/MichaIng/DietPi/issues/6976 [[ -f '/etc/default/vmtouch' ]] && grep -q '/boot/dietpi' /etc/default/vmtouch && G_AGP vmtouch + + # Add DietPi APT repo + /boot/dietpi/dietpi-set_software apt-mirror dietpi + G_AGUP -v + (( $G_AGUP_COUNT )) && G_AGUG } # v6.35 => v7 migration diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 2d90214d98..b5a3c599cc 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,6 +2,7 @@ v9.3 (2024-04-13) Enhancements: +- General | We added an own APT repository for own software and kernel/firmware builds. This simplifies updates for software packages like Squeezelite, vaultwarden and Amiberry, as well as allows us to provide own up-to-date kernel and bootloader packages, applied via regular "apt upgrade". A goal is also to become independent of some 3rd party repositories, which are regularly affected by network errors or provide packages updates too infrequently. - DietPi-Config | Removed the 3.5mm audio option on Raspberry Pi 5, as it does not have a 3.5mm jack. Additionally, the KMS graphics driver is enabled OOTB when HDMI audio is selected, as the snd_bcm2835 driver does not work on Raspberry Pi 5. Many thanks to @JRK0469 for making us aware of this: https://dietpi.com/forum/t/19760 - DietPi-Software | Mosquitto: The official APT repository added support for 64-bit ARM on Bookworm, which is now used for our installation. - DietPi-Software | UnRAR: Debian added unrar packages for RISC-V, which are now used for our installation. diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 50c9abb995..f018bb1a2c 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -113,6 +113,63 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R { [[ $INPUT_MODE_VALUE ]] || { Unknown_Input_Mode; return 1; } + # DietPi repo + [[ -f '/etc/apt/trusted.gpg.d/dietpi.asc' ]] || G_EXEC curl -sSf 'https://dietpi.com/apt/key.asc' -o /etc/apt/trusted.gpg.d/dietpi.asc + # - ARMv6: Since Debian cannot distinguish between ARMv6hf and ARMv7, both armhf, we use a dedicated main component for those. + local components='main' all_components='' + (( $G_HW_ARCH == 1 )) && components='main-armv6' + # - Additional components for SBC-specific packages and builds, some per distro version, some for all distro versions + [[ $G_HW_MODEL [2-5] ]] && components+=' rpi$G_HW_MODEL' + case $G_HW_MODEL in + [0-9]) all_components='rpi';; + 10) all_components='odroidc1';; + 49) + # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed kernel/firmware package + case $HW_VARIANT in + 1) all_components='quartz64a';; + 2) all_components='quartz64b';; + 3) all_components='soquartz';; + *) + [[ -f '/etc/apt/sources.list.d/dietpi.list' ]] && all_components=$(sed -n '/ all /{s/^.* all //p;q}' /etc/apt/sources.list.d/dietpi.list) + [[ $all_components ]] || for i in quartz64{a,b} soquartz + do + dpkg-query -s "firmware-$i" &> /dev/null || continue + all_components=$i + break + done + ;; + esac + ;; + 61) all_components='nanopi2';; + 62) + # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed U-Boot package + case $HW_VARIANT in + 1) all_components='nanopim3';; + 2) all_components='nanopifire3';; + *) + [[ -f '/etc/apt/sources.list.d/dietpi.list' ]] && all_components=$(sed -n '/ all /{s/^.* all //p;q}' /etc/apt/sources.list.d/dietpi.list) + [[ $all_components ]] || for i in nanopi{m,fire}3 + do + dpkg-query -s "linux-u-boot-$i-legacy" &> /dev/null || continue + all_components=$i + break + done + ;; + esac + ;; + 63) all_components='nanopim1';; + 66) all_components='nanopim1plus';; + 70) all_components='sparkysbc';; + 81) all_components='visionfive2';; + 84) all_components='star64';; + *) :;; + esac + G_EXEC eval "echo 'deb https://dietpi.com/apt $G_DISTRO_NAME $components' > /etc/apt/sources.list.d/dietpi.list" + [[ $all_components ]] && G_EXEC eval "echo 'deb https://dietpi.com/apt all $all_components' >> /etc/apt/sources.list.d/dietpi.list" + + # Exit path for quick DietPi-only repo updates + [[ $INPUT_MODE_VALUE == 'dietpi' ]] && return 0 + # RPi Trixie: Suite does not exist yet: https://archive.raspberrypi.com/debian/dists/ (( $G_HW_MODEL < 10 || ( $G_HW_MODEL == 75 && ${G_RASPBIAN:-0} == 1 ) )) && G_EXEC eval "echo 'deb https://archive.raspberrypi.com/debian ${G_DISTRO_NAME/trixie/bookworm} main' > /etc/apt/sources.list.d/raspi.list" From 232fb1309caa0bfe3c3f93bbe5c7b21df7bb31c8 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 14 Apr 2024 17:03:11 +0200 Subject: [PATCH 115/266] v9.3 - CHANGELOG | Update release date --- CHANGELOG.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index b5a3c599cc..e4099f1580 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,5 +1,5 @@ v9.3 -(2024-04-13) +(2024-04-14) Enhancements: - General | We added an own APT repository for own software and kernel/firmware builds. This simplifies updates for software packages like Squeezelite, vaultwarden and Amiberry, as well as allows us to provide own up-to-date kernel and bootloader packages, applied via regular "apt upgrade". A goal is also to become independent of some 3rd party repositories, which are regularly affected by network errors or provide packages updates too infrequently. From 0df841a86117cf2e844a2b2fb44b016a3656101f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 14 Apr 2024 17:11:29 +0200 Subject: [PATCH 116/266] v9.3 - Coding | Address shellcheck annotations --- .update/patches | 2 ++ dietpi/func/dietpi-set_software | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.update/patches b/.update/patches index 603f27de3a..3bfc5f360a 100755 --- a/.update/patches +++ b/.update/patches @@ -38,6 +38,7 @@ export G_SERVICE_CONTROL=0 # ToDo: On RPi 4, the 64-bit kernel is now used by default, without "arm_64bit=1" set: https://forums.raspberrypi.com/viewtopic.php?p=2088935#p2088935 # - We could set "arm_64bit=0", but for now lets assure that 32-bit software is installed and see how it goes. This enables general support for RPi with 64-bit kernel running 32-bit userland. +# shellcheck disable=SC2034 [[ $G_HW_MODEL == [2-9] && $G_HW_ARCH == 3 && $(dpkg --print-architecture) == 'armhf' ]] && G_HW_ARCH=2 G_HW_ARCH_NAME='armv7l' # Version-based incremental patches @@ -1542,6 +1543,7 @@ Patch_9_3() # Add DietPi APT repo /boot/dietpi/dietpi-set_software apt-mirror dietpi G_AGUP -v + # shellcheck disable=SC2154 (( $G_AGUP_COUNT )) && G_AGUG } diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index f018bb1a2c..e774a8eeac 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -119,7 +119,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R local components='main' all_components='' (( $G_HW_ARCH == 1 )) && components='main-armv6' # - Additional components for SBC-specific packages and builds, some per distro version, some for all distro versions - [[ $G_HW_MODEL [2-5] ]] && components+=' rpi$G_HW_MODEL' + [[ $G_HW_MODEL == [2-5] ]] && components+=' rpi$G_HW_MODEL' case $G_HW_MODEL in [0-9]) all_components='rpi';; 10) all_components='odroidc1';; @@ -166,7 +166,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R esac G_EXEC eval "echo 'deb https://dietpi.com/apt $G_DISTRO_NAME $components' > /etc/apt/sources.list.d/dietpi.list" [[ $all_components ]] && G_EXEC eval "echo 'deb https://dietpi.com/apt all $all_components' >> /etc/apt/sources.list.d/dietpi.list" - + # Exit path for quick DietPi-only repo updates [[ $INPUT_MODE_VALUE == 'dietpi' ]] && return 0 From 2267bf81c228065bf0cbaa191d248d009bd408f4 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 14 Apr 2024 17:18:24 +0200 Subject: [PATCH 117/266] v9.3 - CHANGELOG | Extend APT repo changelog entry for those who want to browse it before the update - Coding | Address shellcheck annotations --- CHANGELOG.txt | 2 +- dietpi/func/dietpi-set_software | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index e4099f1580..5a2715a3bc 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,7 +2,7 @@ v9.3 (2024-04-14) Enhancements: -- General | We added an own APT repository for own software and kernel/firmware builds. This simplifies updates for software packages like Squeezelite, vaultwarden and Amiberry, as well as allows us to provide own up-to-date kernel and bootloader packages, applied via regular "apt upgrade". A goal is also to become independent of some 3rd party repositories, which are regularly affected by network errors or provide packages updates too infrequently. +- General | We added an own APT repository at https://dietpi.com/apt for own software and kernel/firmware builds. This simplifies updates for software packages like Squeezelite, vaultwarden and Amiberry, as well as allows us to provide own up-to-date kernel and bootloader packages, applied via regular "apt upgrade". A goal is also to become independent of some 3rd party repositories, which are regularly affected by network errors or provide packages updates too infrequently. - DietPi-Config | Removed the 3.5mm audio option on Raspberry Pi 5, as it does not have a 3.5mm jack. Additionally, the KMS graphics driver is enabled OOTB when HDMI audio is selected, as the snd_bcm2835 driver does not work on Raspberry Pi 5. Many thanks to @JRK0469 for making us aware of this: https://dietpi.com/forum/t/19760 - DietPi-Software | Mosquitto: The official APT repository added support for 64-bit ARM on Bookworm, which is now used for our installation. - DietPi-Software | UnRAR: Debian added unrar packages for RISC-V, which are now used for our installation. diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index e774a8eeac..b6f4c3cde9 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -119,12 +119,13 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R local components='main' all_components='' (( $G_HW_ARCH == 1 )) && components='main-armv6' # - Additional components for SBC-specific packages and builds, some per distro version, some for all distro versions - [[ $G_HW_MODEL == [2-5] ]] && components+=' rpi$G_HW_MODEL' + [[ $G_HW_MODEL == [2-5] ]] && components+=" rpi$G_HW_MODEL" case $G_HW_MODEL in [0-9]) all_components='rpi';; 10) all_components='odroidc1';; 49) # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed kernel/firmware package + # shellcheck disable=SC2154 case $HW_VARIANT in 1) all_components='quartz64a';; 2) all_components='quartz64b';; @@ -143,6 +144,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R 61) all_components='nanopi2';; 62) # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed U-Boot package + # shellcheck disable=SC2154 case $HW_VARIANT in 1) all_components='nanopim3';; 2) all_components='nanopifire3';; From 9b7e9136575ea41a49100c3a2d26a9a07d7605df Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 14 Apr 2024 17:33:27 +0200 Subject: [PATCH 118/266] v9.3 - DietPi-Software | vaultwarden: Remove pre-v8.7 cleanup from install script, as it is done via patches already. But restore manual DEB package install patch, since pre-v8.7 systems won't have any vaultwarden DEB package installed, hence it won't be upgraded from DietPi APT repo either. --- .update/patches | 11 ++++++----- dietpi/dietpi-software | 3 +-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.update/patches b/.update/patches index 3bfc5f360a..21def36056 100755 --- a/.update/patches +++ b/.update/patches @@ -1519,11 +1519,12 @@ Patch_9_2() if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[183\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' vaultwarden 2> /dev/null)" lt 1.30.5-dietpi1 then # Pre-v8.7 cleanup - if [[ -f '/opt/vaultwarden/target/release/vaultwarden' ]] - then - G_EXEC rm -R /opt/vaultwarden - [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service - fi + [[ -f '/opt/vaultwarden/target/release/vaultwarden' ]] && G_EXEC rm -R /opt/vaultwarden + [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service + G_DIETPI-NOTIFY 2 'Updating vaultwarden package ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" + G_AGI ./package.deb + G_EXEC rm package.deb fi # Amiberry diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 121e3edf55..bf9a3d068c 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -4896,6 +4896,7 @@ The install script will now exit. After applying one of the the above, rerun die if To_Install 32 ympd # ympd then Download_Install "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/ympd_$G_HW_ARCH_NAME.deb" + G_EXEC systemctl stop ympd fi if To_Install 148 mympd # myMPD @@ -9260,8 +9261,6 @@ _EOF_ if To_Install 183 vaultwarden # vaultwarden then - [[ -f '/opt/vaultwarden/target/release/vaultwarden' ]] && G_EXEC rm -R /opt/vaultwarden # Pre-v8.7 - [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service # Pre-v8.7 Download_Install "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" G_EXEC systemctl stop vaultwarden fi From 5f5af8a5b535e780042b2513491e3b2c82161fa9 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 14 Apr 2024 17:41:50 +0200 Subject: [PATCH 119/266] v9.3 - DietPi-Patches | Restore further manual DEB package installs, in cases where it is not assured that those are installed already, i.e. "lt" vs "lt-nl". --- .update/patches | 32 +++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) diff --git a/.update/patches b/.update/patches index 21def36056..9c5ba613e3 100755 --- a/.update/patches +++ b/.update/patches @@ -713,6 +713,18 @@ Patch_8_7() G_DIETPI-NOTIFY 2 'Removing duplicate "cgroup_enable=memory" kernel command-line argument...' G_EXEC sed --follow-symlinks -i 's/ cgroup_enable=memory//' /boot/cmdline.txt done + + # vaultwarden + if [[ -f '/boot/dietpi/.installed' ]] && grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[183\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' vaultwarden 2> /dev/null)" lt 1.30.5-dietpi1 + then + # Pre-v8.7 cleanup + [[ -f '/opt/vaultwarden/target/release/vaultwarden' ]] && G_EXEC rm -R /opt/vaultwarden + [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service + G_DIETPI-NOTIFY 2 'Updating vaultwarden package ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" + G_AGI ./package.deb + G_EXEC rm package.deb + fi } Patch_8_8(){ :; } @@ -1397,6 +1409,15 @@ Patch_8_24() fi [[ -f '/etc/modprobe.d/dietpi-disable_bluetooth.conf' ]] || G_EXEC eval 'echo '\''sprdbt_tty'\'' > /etc/modules-load.d/dietpi-enable_bluetooth.conf' fi + + # Shairport Sync + if [[ -f '/boot/dietpi/.installed' ]] && grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[37\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' shairport-sync 2> /dev/null)" lt 4.3.2-dietpi2 + then + G_DIETPI-NOTIFY 2 'Updating Shairport Sync package ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/shairport-sync_$G_HW_ARCH_NAME.deb" + G_AGI ./package.deb + G_EXEC rm package.deb + fi } Patch_8_25() @@ -1515,14 +1536,11 @@ Patch_9_2() fi fi - # vaultwarden - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[183\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' vaultwarden 2> /dev/null)" lt 1.30.5-dietpi1 + # Squeezelite + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[36\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' squeezelite 2> /dev/null)" lt 2.0.0-1468-dietpi1 then - # Pre-v8.7 cleanup - [[ -f '/opt/vaultwarden/target/release/vaultwarden' ]] && G_EXEC rm -R /opt/vaultwarden - [[ -f '/etc/systemd/system/vaultwarden.service' ]] && G_EXEC rm /etc/systemd/system/vaultwarden.service - G_DIETPI-NOTIFY 2 'Updating vaultwarden package ...' - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" + G_DIETPI-NOTIFY 2 'Updating Squeezelite package ...' + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/squeezelite_$G_HW_ARCH_NAME.deb" G_AGI ./package.deb G_EXEC rm package.deb fi From 2d3e7de7658158114af01e3674f68565dbe33ae7 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 14 Apr 2024 17:45:32 +0200 Subject: [PATCH 120/266] v9.3 - DietPi-Patches | Fix script path --- .update/patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index 9c5ba613e3..d4bcc7f4e8 100755 --- a/.update/patches +++ b/.update/patches @@ -1560,7 +1560,7 @@ Patch_9_3() [[ -f '/etc/default/vmtouch' ]] && grep -q '/boot/dietpi' /etc/default/vmtouch && G_AGP vmtouch # Add DietPi APT repo - /boot/dietpi/dietpi-set_software apt-mirror dietpi + /boot/dietpi/func/dietpi-set_software apt-mirror dietpi G_AGUP -v # shellcheck disable=SC2154 (( $G_AGUP_COUNT )) && G_AGUG From 5ed62efb8afbc8f09045d4e779695756656181e4 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 14 Apr 2024 17:55:49 +0200 Subject: [PATCH 121/266] v9.3 - CHANGELOG | Add v9.3 PR link --- CHANGELOG.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 5a2715a3bc..11a2610a26 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -11,7 +11,7 @@ Bug fixes: - Raspberry Pi 5 | Fixed X11/desktop startup if KMS is enabled. Many thanks to @denguido for reporting the issue and solution: https://dietpi.com/forum/t/19760 - DietPi-Software | Logitech Media Server: Resolved an issue where the install failed due to a changed download URL. Many thanks to @JRK0469 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6992 -As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME +As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/7016 ----------------------------------------------------------------------------------------------------------- From 1de8f642065402e3a0d6359d746a8b6b6da0a8ab Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 15 Apr 2024 12:47:42 +0200 Subject: [PATCH 122/266] v9.4 - CHANGELOG | Fix typo and wrong user acknowledgement --- CHANGELOG.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 11a2610a26..4693fdd0b0 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,8 +2,8 @@ v9.3 (2024-04-14) Enhancements: -- General | We added an own APT repository at https://dietpi.com/apt for own software and kernel/firmware builds. This simplifies updates for software packages like Squeezelite, vaultwarden and Amiberry, as well as allows us to provide own up-to-date kernel and bootloader packages, applied via regular "apt upgrade". A goal is also to become independent of some 3rd party repositories, which are regularly affected by network errors or provide packages updates too infrequently. -- DietPi-Config | Removed the 3.5mm audio option on Raspberry Pi 5, as it does not have a 3.5mm jack. Additionally, the KMS graphics driver is enabled OOTB when HDMI audio is selected, as the snd_bcm2835 driver does not work on Raspberry Pi 5. Many thanks to @JRK0469 for making us aware of this: https://dietpi.com/forum/t/19760 +- General | We added an own APT repository at https://dietpi.com/apt for own software and kernel/firmware builds. This simplifies updates for software packages like Squeezelite, vaultwarden and Amiberry, as well as allows us to provide own up-to-date kernel and bootloader packages, applied via regular "apt upgrade". A goal is also to become independent of some 3rd party repositories, which are regularly affected by network errors or provide package updates too infrequently. +- DietPi-Config | Removed the 3.5mm audio option on Raspberry Pi 5, as it does not have a 3.5mm jack. Additionally, the KMS graphics driver is enabled OOTB when HDMI audio is selected, as the snd_bcm2835 driver does not work on Raspberry Pi 5. Many thanks to @denguido for making us aware of this: https://dietpi.com/forum/t/19760 - DietPi-Software | Mosquitto: The official APT repository added support for 64-bit ARM on Bookworm, which is now used for our installation. - DietPi-Software | UnRAR: Debian added unrar packages for RISC-V, which are now used for our installation. From 7a9d5a7bd6096caf80699c1e2ac54dae81f8250b Mon Sep 17 00:00:00 2001 From: StephanStS Date: Mon, 15 Apr 2024 21:37:00 +0200 Subject: [PATCH 123/266] Init v9.4 (#7021) * Init v9.4 * Fix v9.4 software array --------- Co-authored-by: MichaIng --- .meta/dietpi-survey_report | 3 ++- .update/version | 4 ++-- CHANGELOG.txt | 11 +++++++++++ dietpi/func/dietpi-globals | 4 ++-- 4 files changed, 17 insertions(+), 5 deletions(-) diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index c601631b40..367bbc9790 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -713,10 +713,11 @@ shopt -s extglob aSOFTWARE_NAME9_1[i]=${aSOFTWARE_NAME9_0[i]} aSOFTWARE_NAME9_2[i]=${aSOFTWARE_NAME9_1[i]} aSOFTWARE_NAME9_3[i]=${aSOFTWARE_NAME9_2[i]} + aSOFTWARE_NAME9_4[i]=${aSOFTWARE_NAME9_3[i]} done # Pre-create software counter array so that we can see also software (available in newest version) with 0 installs - for i in "${aSOFTWARE_NAME9_3[@]}" + for i in "${aSOFTWARE_NAME9_4[@]}" do aSOFTWARE[$i]=0 done diff --git a/.update/version b/.update/version index a54ce2d4d0..e2d57b846a 100644 --- a/.update/version +++ b/.update/version @@ -2,8 +2,8 @@ # shellcheck disable=SC2034 # Available DietPi version G_REMOTE_VERSION_CORE=9 -G_REMOTE_VERSION_SUB=3 -G_REMOTE_VERSION_RC=0 +G_REMOTE_VERSION_SUB=4 +G_REMOTE_VERSION_RC=-1 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 4693fdd0b0..3dcfeb81b7 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,3 +1,14 @@ +v9.4 +(2024-05-12) + +Enhancements: + +Bug fixes: + +As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME + +----------------------------------------------------------------------------------------------------------- + v9.3 (2024-04-14) diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 3f3cf3a3a1..73cf65d6e7 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -54,8 +54,8 @@ [[ -f '/boot/dietpi/.version' ]] && . /boot/dietpi/.version # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 - [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=3 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=0 + [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=4 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=-1 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From 6a5870763add677476a903d9ad9fae4e62bc0ea6 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 16 Apr 2024 23:58:09 +0200 Subject: [PATCH 124/266] v9.4 - APT | Add "nanopir5c" component to ship new U-Boot package for NanoPi R5C, which fixes PCIe WiFi --- dietpi/func/dietpi-set_software | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index b6f4c3cde9..55c50d1fc3 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -162,6 +162,23 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R 63) all_components='nanopim1';; 66) all_components='nanopim1plus';; 70) all_components='sparkysbc';; + 76) + # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed U-Boot package + # shellcheck disable=SC2154 + case $HW_VARIANT in + 1) all_components='';; # no R5S component is available yet + 2) all_components='nanopir5c';; + *) + [[ -f '/etc/apt/sources.list.d/dietpi.list' ]] && all_components=$(sed -n '/ all /{s/^.* all //p;q}' /etc/apt/sources.list.d/dietpi.list) + [[ $all_components ]] || for i in nanopi-r5c + do + dpkg-query -s "linux-u-boot-$i-current" &> /dev/null || continue + all_components=${i/-//} + break + done + ;; + esac + ;; 81) all_components='visionfive2';; 84) all_components='star64';; *) :;; From 240756b83402e2e0334e266735e0009637f8411f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 17 Apr 2024 00:42:37 +0200 Subject: [PATCH 125/266] v9.4 - DietPi-Installer | Install self-hosted kernel/firmware packages via our APT repository and cleanup dpkg/ucf config files across the whole system, instead of removing those from our kernel/firmware packages individually --- .build/images/dietpi-installer | 38 ++++++--------------------------- dietpi/func/dietpi-set_software | 1 + 2 files changed, 8 insertions(+), 31 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 66fc2b9bee..bc22674084 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1301,55 +1301,31 @@ _EOF_ 3) variant='soquartz';; *) variant='quartz64a';; esac - G_EXEC curl -sSfo package.deb "https://dietpi.com/downloads/binaries/firmware-$variant.deb" - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb - G_EXEC rm package.deb - aPACKAGES_REQUIRED_INSTALL+=("firmware-$variant") + G_AGI "firmware-$variant" # NanoPi M2/T2/Fire2 Linux 4.4: Requires dedicated boot partition, starting at 4 MiB for U-Boot, with ext4 filesystem elif [[ $G_HW_MODEL == 61 && $(findmnt -Ufnro FSTYPE -M /boot) == 'ext4' ]] && (( $(sfdisk -qlo Start "$BOOT_DEVICE" | mawk 'NR==2') >= 8192 )) then - G_EXEC curl -sSfo package.deb 'https://dietpi.com/downloads/binaries/firmware-nanopi2.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb - G_EXEC rm package.deb - aPACKAGES_REQUIRED_INSTALL+=('firmware-nanopi2') + G_AGI firmware-nanopi2 # VisionFive 2 elif (( $G_HW_MODEL == 81 )) then - G_EXEC curl -sSfo package.deb 'https://dietpi.com/downloads/binaries/linux-image-visionfive2.deb' - dpkg-deb -I linux-image-visionfive2.deb conffiles | while read -r line - do - [[ -f $line ]] && G_EXEC rm "$line" - done - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb - G_EXEC rm package.deb + G_AGI linux-image-visionfive2 libubootenv-tool G_EXEC sed --follow-symlinks -i "s/root=[^[:blank:]]*/root=PARTUUID=$(findmnt -Ufnro PARTUUID -M /)/" /boot/extlinux/extlinux.conf G_EXEC sed --follow-symlinks -i "s/rootfstype=[^[:blank:]]*/rootfstype=$(findmnt -Ufnro FSTYPE -M /)/" /boot/extlinux/extlinux.conf - aPACKAGES_REQUIRED_INSTALL+=('linux-image-visionfive2' 'libubootenv-tool') # Star64 elif (( $G_HW_MODEL == 84 )) then - G_EXEC curl -sSfo package.deb 'https://dietpi.com/downloads/binaries/linux-image-star64.deb' - dpkg-deb -I linux-image-star64.deb conffiles | while read -r line - do - [[ -f $line ]] && G_EXEC rm "$line" - done - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb - G_EXEC rm package.deb + G_AGI linux-image-star64 libubootenv-tool G_EXEC sed --follow-symlinks -i "s/root=[^[:blank:]]*/root=PARTUUID=$(findmnt -Ufnro PARTUUID -M /)/" /boot/extlinux/extlinux.conf G_EXEC sed --follow-symlinks -i "s/rootfstype=[^[:blank:]]*/rootfstype=$(findmnt -Ufnro FSTYPE -M /)/" /boot/extlinux/extlinux.conf - aPACKAGES_REQUIRED_INSTALL+=('linux-image-star64' 'libubootenv-tool') # Sparky SBC elif (( $G_HW_MODEL == 70 )) then - G_EXEC curl -sSfo package.deb 'https://dietpi.com/downloads/binaries/firmware-sparkysbc.deb' - [[ -f '/boot/uenv.txt' ]] && G_EXEC rm /boot/uenv.txt - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb - G_EXEC rm package.deb - aPACKAGES_REQUIRED_INSTALL+=('firmware-sparkysbc') + G_AGI firmware-sparkysbc G_EXEC curl -sSfo u-boot.gz 'https://dietpi.com/downloads/binaries/u-boot-sparkysbc.img.gz' G_EXEC gzip -d u-boot.gz @@ -1610,7 +1586,7 @@ _EOF_ [[ -d '/usr/share/calendar' ]] && G_EXEC rm -R /usr/share/calendar # - Unused DEB package config files - find /etc \( -name '?*\.dpkg-dist' -o -name '?*\.dpkg-old' -o -name '?*\.dpkg-new' -o -name '?*\.dpkg-bak' -o -name '?*\.dpkg-del' -o -name '?*\.ucf-dist' -o -name '?*\.ucf-old' -o -name '?*\.ucf-new' \) -exec rm -v {} + + find / \( -name '*?.dpkg-dist' -o -name '*?.dpkg-old' -o -name '*?.dpkg-new' -o -name '*?.dpkg-bak' -o -name '*?.dpkg-del' -o -name '*?.ucf-dist' -o -name '*?.ucf-old' -o -name '*?.ucf-new' \) -exec rm -v {} + # - Fonts [[ -d '/usr/share/fonts' ]] && G_EXEC rm -R /usr/share/fonts @@ -1753,7 +1729,7 @@ _EOF_ # - Enable /etc/bashrc.d/ support for custom interactive non-login shell scripts: sed --follow-symlinks -i '\#/etc/bashrc\.d/#d' /etc/bash.bashrc # shellcheck disable=SC2016 - echo 'for i in /etc/bashrc.d/*.sh /etc/bashrc.d/*.bash; do [ -r "$i" ] && . $i; done; unset -v i' >> /etc/bash.bashrc + echo 'for i in /etc/bashrc.d/*.sh /etc/bashrc.d/*.bash; do [ -r "$i" ] && . "$i"; done; unset -v i' >> /etc/bash.bashrc # - Enable bash-completion for non-login shells: # - NB: It is called twice on login shells then, but exits directly if called once already. G_EXEC ln -sf /etc/profile.d/bash_completion.sh /etc/bashrc.d/dietpi-bash_completion.sh diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 55c50d1fc3..084da1888e 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -170,6 +170,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R 2) all_components='nanopir5c';; *) [[ -f '/etc/apt/sources.list.d/dietpi.list' ]] && all_components=$(sed -n '/ all /{s/^.* all //p;q}' /etc/apt/sources.list.d/dietpi.list) + # shellcheck disable=SC2043 [[ $all_components ]] || for i in nanopi-r5c do dpkg-query -s "linux-u-boot-$i-current" &> /dev/null || continue From 511d7a94d8f545c78b3426260cfe3d3d6bb7ba5a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 17 Apr 2024 00:54:01 +0200 Subject: [PATCH 126/266] v9.4 - DietPi-Installer | Do not remove dietpi.list and fix Bullseye suite on Armbian-based images --- .build/images/dietpi-installer | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index bc22674084..6a9814b96c 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1035,7 +1035,7 @@ _EOF_ [[ -f '/etc/apt/trusted.gpg' ]] && G_EXEC rm /etc/apt/trusted.gpg [[ -f '/etc/apt/trusted.gpg~' ]] && G_EXEC rm '/etc/apt/trusted.gpg~' # Remove obsolete lists - G_EXEC rm -Rf /etc/apt/sources.list.d/* + find /etc/apt/sources.list.d -mindepth 1 ! -name 'dietpi.list' -exec rm -Rf {} + # Add Armbian repository G_EXEC eval "echo 'deb https://apt.armbian.com ${DISTRO_TARGET_NAME/bullseye/bookworm} main' > /etc/apt/sources.list.d/dietpi-armbian.list" # Update APT lists @@ -1423,8 +1423,8 @@ _EOF_ [[ -f '/etc/apt/trusted.gpg~' ]] && G_EXEC rm '/etc/apt/trusted.gpg~' # Remove obsolete components from Armbian list and connect via HTTPS - G_EXEC rm -Rf /etc/apt/sources.list.d/{,.??,.[^.]}* - G_EXEC eval "echo 'deb https://apt.armbian.com $DISTRO_TARGET_NAME main' > /etc/apt/sources.list.d/dietpi-armbian.list" + find /etc/apt/sources.list.d -mindepth 1 ! -name 'dietpi.list' -exec rm -Rf {} + + G_EXEC eval "echo 'deb https://apt.armbian.com ${DISTRO_TARGET_NAME/bullseye/bookworm} main' > /etc/apt/sources.list.d/dietpi-armbian.list" # Skip creating kernel symlinks and remove existing ones if [[ -L '/vmlinuz' ]] From f0d69bb4adc0f0daa0841ffe5a343e2f19562832 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 17 Apr 2024 00:54:49 +0200 Subject: [PATCH 127/266] v9.4 - Coding | Remove trailing space --- dietpi/func/dietpi-set_software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 084da1888e..0c07a26a6c 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -170,7 +170,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R 2) all_components='nanopir5c';; *) [[ -f '/etc/apt/sources.list.d/dietpi.list' ]] && all_components=$(sed -n '/ all /{s/^.* all //p;q}' /etc/apt/sources.list.d/dietpi.list) - # shellcheck disable=SC2043 + # shellcheck disable=SC2043 [[ $all_components ]] || for i in nanopi-r5c do dpkg-query -s "linux-u-boot-$i-current" &> /dev/null || continue From b3a7ebe04282c81515630872e6d9a1131cbaa4e4 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 17 Apr 2024 21:20:32 +0200 Subject: [PATCH 128/266] v9.4 - NanoPi R5C | New images, or when flashing the new bootloader binary via dietpi-config > Advanced Options > Update MMC bootloader, support M.2 WiFi modules. --- .update/patches | 6 ++++++ CHANGELOG.txt | 1 + 2 files changed, 7 insertions(+) diff --git a/.update/patches b/.update/patches index d4bcc7f4e8..551bd9e1f3 100755 --- a/.update/patches +++ b/.update/patches @@ -1566,6 +1566,12 @@ Patch_9_3() (( $G_AGUP_COUNT )) && G_AGUG } +Patch_9_4() +{ + # Update DietPi APT list for NanoPi R5C + (( $G_HW_MODEL == 76 )) && /boot/dietpi/func/dietpi-set_software apt-mirror dietpi +} + # v6.35 => v7 migration if (( $G_DIETPI_VERSION_CORE == 6 && $G_DIETPI_VERSION_SUB > 34 )) then diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 3dcfeb81b7..e546f85fa7 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,6 +2,7 @@ v9.4 (2024-05-12) Enhancements: +- NanoPi R5C | New images, or when flashing the new bootloader binary via dietpi-config > Advanced Options > Update MMC bootloader, support M.2 WiFi modules. Bug fixes: From 68da00a416a212d314a72688783329a2b7d07c12 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 18 Apr 2024 17:43:50 +0200 Subject: [PATCH 129/266] v9.4 - DietPi-Software | Update some fallback URLs and new (additional) Mosquitto APT key --- dietpi/dietpi-software | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index bf9a3d068c..21831cc080 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6691,7 +6691,7 @@ _EOF_ if (( $G_DISTRO < 8 )) && [[ $G_HW_ARCH == 2 || $G_HW_ARCH == 10 || ( $G_HW_ARCH == 3 && $G_DISTRO == 7 ) ]] then # APT key - local url='https://repo.mosquitto.org/debian/mosquitto-repo.gpg.key' + local url='https://repo.mosquitto.org/debian/mosquitto-repo.gpg' G_CHECK_URL "$url" G_EXEC eval "curl -sSfL '$url' | gpg --dearmor -o /etc/apt/trusted.gpg.d/dietpi-mosquitto.gpg --yes" @@ -7434,7 +7434,7 @@ _EOF_ then Download_Install 'https://github.com/gotson/komga/releases/download/v0.165.0/komga-0.165.0.jar' /mnt/dietpi_userdata/komga/komga.jar else - local fallback_url='https://github.com/gotson/komga/releases/download/1.10.4/komga-1.10.4.jar' + local fallback_url='https://github.com/gotson/komga/releases/download/1.11.0/komga-1.11.0.jar' Download_Install "$(curl -sSfL 'https://api.github.com/repos/gotson/komga/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/komga-[^"\/]*\.jar"$/{print $4}')" /mnt/dietpi_userdata/komga/komga.jar fi @@ -10592,7 +10592,7 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.10/gitea-1.21.10-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.11/gitea-1.21.11-linux-$arch.xz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/go-gitea/gitea/releases/latest' | mawk -F\" "/\"browser_download_url\": \".*\/gitea-[^\"\/]*-linux-$arch\.xz\"/{print \$4}")" /mnt/dietpi_userdata/gitea/gitea # User From c9cc8df4d6a5ec4e9e5b9f7325c2b7023f027efe Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 18 Apr 2024 18:37:16 +0200 Subject: [PATCH 130/266] v9.4 - General | Our scripts do now internally enforce the default umask 0022. Many config and install options rely on this, hence it can cause issues when e.g. 0027 (deny read access for "other" users) has been applied on the parent shell. This affects only the (sub)shell of our scripts, while the current and default umask of parent and of shells/consoles remains untouched. --- CHANGELOG.txt | 1 + dietpi/func/dietpi-globals | 3 +++ 2 files changed, 4 insertions(+) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index e546f85fa7..d03de731bc 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,6 +2,7 @@ v9.4 (2024-05-12) Enhancements: +- General | Our scripts do now internally enforce the default umask 0022. Many config and install options rely on this, hence it can cause issues when e.g. 0027 (deny read access for "other" users) has been applied on the parent shell. This affects only the (sub)shell of our scripts, while the current and default umask of parent and of shells/consoles remains untouched. - NanoPi R5C | New images, or when flashing the new bootloader binary via dietpi-config > Advanced Options > Update MMC bootloader, support M.2 WiFi modules. Bug fixes: diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 73cf65d6e7..ecea008fc3 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -80,6 +80,9 @@ G_GITOWNER='$G_GITOWNER'" > /boot/dietpi/.version # Set PATH to expected default to rule out issues due to broken environment, e.g. in combination with "su" or "sudo -E" export LC_ALL='C.UTF-8' LANG='C.UTF-8' PATH='/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin' + # Enforce default umask: https://github.com/MichaIng/DietPi/issues/7022 + umask 0022 + # Set G_PROGRAM_NAME to originating script file (or shell executable) name if it was not set by originating script [[ $G_PROGRAM_NAME ]] || readonly G_PROGRAM_NAME=${0##*/} From 58ef73dbfe27ca78971e70fffbce9db2e101d821 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 18 Apr 2024 22:18:34 +0200 Subject: [PATCH 131/266] v9.4 - DietPi-Software | Install packages we host on our APT repository from there, and move some migration steps to update patches --- .update/patches | 32 ++++++++++++++++++++++++-------- dietpi/dietpi-software | 25 +++++-------------------- 2 files changed, 29 insertions(+), 28 deletions(-) diff --git a/.update/patches b/.update/patches index 551bd9e1f3..a92b6c5d5b 100755 --- a/.update/patches +++ b/.update/patches @@ -1231,14 +1231,6 @@ Patch_8_19() # Mopidy: Bullseye suite now available in official APT repo [[ -f '/etc/apt/sources.list.d/mopidy.list' ]] && grep -q buster /etc/apt/sources.list.d/mopidy.list && G_EXEC sed --follow-symlinks -i 's/buster/bullseye/' /etc/apt/sources.list.d/mopidy.list - # GMediaRender - grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[163\]=2' /boot/dietpi/.installed && dpkg --compare-versions "$(dpkg-query -Wf '${Version}' gmediarender 2> /dev/null)" lt 0.1-dietpi1 && G_WHIP_MSG '[ INFO ] GMediaRender update available -\nAn update to GMediaRender 0.1 is available. -Release notes: https://github.com/hzeller/gmrender-resurrect/releases -\nDo you want to apply the update now? -\nYou can manually apply it any time via: -# dietpi-software reinstall 163' && echo 163 >> /var/tmp/dietpi/dietpi-update_reinstalls - # ympd if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[32\]=2' /boot/dietpi/.installed then @@ -1570,6 +1562,30 @@ Patch_9_4() { # Update DietPi APT list for NanoPi R5C (( $G_HW_MODEL == 76 )) && /boot/dietpi/func/dietpi-set_software apt-mirror dietpi + + if [[ -f '/boot/dietpi/.installed' ]] + then + # GMediaRender + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[163\]=2' /boot/dietpi/.installed && ! dpkg-query -s 'gmediarender' &> /dev/null + then + # Pre-v8.10 + G_DIETPI-NOTIFY 2 'Updateing GMediaRender ...' + [[ -f '/etc/systemd/system/gmediarender.service' ]] && G_EXEC rm /etc/systemd/system/gmediarender.service + [[ -d '/etc/systemd/system/gmediarender.service.d' ]] && grep -Rq '/usr/local/bin/gmediarender' /etc/systemd/system/gmediarender.service.d && G_EXEC rm -R /etc/systemd/system/gmediarender.service.d + getent passwd gmrender > /dev/null && G_EXEC userdel gmrender + getent group gmrender > /dev/null && G_EXEC groupdel gmrender + [[ -f '/usr/local/bin/gmediarender' ]] && G_EXEC rm /usr/local/bin/gmediarender + [[ -d '/usr/local/share/gmediarender' ]] && G_EXEC rm -R /usr/local/share/gmediarender + G_AGI gmediarender + fi + + # Shairport Sync + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[37\]=2' /boot/dietpi/.installed + then + [[ -f '/usr/local/share/man/man7/shairport-sync.7.gz' ]] && G_EXEC rm /usr/local/share/man/man7/shairport-sync.7.gz + [[ -d '/usr/local/share/man/man7' ]] G_EXEC rmdir -p --ignore-fail-on-non-empty /usr/local/share/man/man7 + fi + fi } # v6.35 => v7 migration diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 21831cc080..3c3f3c44da 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -4895,7 +4895,7 @@ The install script will now exit. After applying one of the the above, rerun die if To_Install 32 ympd # ympd then - Download_Install "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/ympd_$G_HW_ARCH_NAME.deb" + G_AGI ympd G_EXEC systemctl stop ympd fi @@ -8034,7 +8034,7 @@ _EOF_ airplay2= fi - Download_Install "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/shairport-sync${airplay2}_$G_HW_ARCH_NAME.deb" + G_AGI shairport-sync G_EXEC systemctl stop shairport-sync fi @@ -8120,7 +8120,7 @@ _EOF_ if To_Install 36 squeezelite # Squeezelite then - Download_Install "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/squeezelite_$G_HW_ARCH_NAME.deb" + G_AGI squeezelite G_EXEC systemctl stop squeezelite fi @@ -9261,7 +9261,7 @@ _EOF_ if To_Install 183 vaultwarden # vaultwarden then - Download_Install "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/vaultwarden_$G_HW_ARCH_NAME.deb" + G_AGI vaultwarden G_EXEC systemctl stop vaultwarden fi @@ -10633,14 +10633,7 @@ _EOF_ if To_Install 163 gmediarender # GMediaRender then - # Pre-v8.10 - [[ -f '/etc/systemd/system/gmediarender.service' ]] && G_EXEC rm /etc/systemd/system/gmediarender.service - [[ -d '/etc/systemd/system/gmediarender.service.d' ]] && grep -Rq '/usr/local/bin/gmediarender' /etc/systemd/system/gmediarender.service.d && G_EXEC rm -R /etc/systemd/system/gmediarender.service.d - getent passwd gmrender > /dev/null && G_EXEC userdel gmrender - getent group gmrender > /dev/null && G_EXEC groupdel gmrender - [[ -f '/usr/local/bin/gmediarender' ]] && G_EXEC rm /usr/local/bin/gmediarender - [[ -d '/usr/local/share/gmediarender' ]] && G_EXEC rm -R /usr/local/share/gmediarender - Download_Install "https://dietpi.com/downloads/binaries/$G_DISTRO_NAME/gmediarender_$G_HW_ARCH_NAME.deb" + G_AGI gmediarender G_EXEC systemctl stop gmediarender fi @@ -12816,10 +12809,6 @@ If no WireGuard (auto)start is included, but you require it, please do the follo if To_Uninstall 37 # Shairport Sync then G_AGP shairport-sync - # Pre-v6.29 - Remove_Service shairport-sync - [[ -f '/lib/systemd/system/shairport-sync.service' ]] && G_EXEC rm /lib/systemd/system/shairport-sync.service - G_EXEC rm -f /usr/local/bin/shairport-sync /usr/local/etc/shairport-sync.conf* /usr/local/share/man/man7/shairport-sync.7.gz fi if To_Uninstall 152 # Avahi-Daemon @@ -13702,10 +13691,6 @@ _EOF_ if To_Uninstall 163 # GMediaRender then G_AGP gmediarender - # Pre-v8.10 - Remove_Service gmediarender gmrender gmrender - [[ -f '/usr/local/bin/gmediarender' ]] && G_EXEC rm /usr/local/bin/gmediarender - [[ -d '/usr/local/share/gmediarender' ]] && G_EXEC rm -R /usr/local/share/gmediarender fi if To_Uninstall 67 # Firefox From 185a08f67ecf41345b29784ab3bb25196cdfaafb Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 18 Apr 2024 22:26:10 +0200 Subject: [PATCH 132/266] v9.4 - DietPi-Patches | Syntax --- .update/patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index a92b6c5d5b..e1e0b951bf 100755 --- a/.update/patches +++ b/.update/patches @@ -1583,7 +1583,7 @@ Patch_9_4() if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[37\]=2' /boot/dietpi/.installed then [[ -f '/usr/local/share/man/man7/shairport-sync.7.gz' ]] && G_EXEC rm /usr/local/share/man/man7/shairport-sync.7.gz - [[ -d '/usr/local/share/man/man7' ]] G_EXEC rmdir -p --ignore-fail-on-non-empty /usr/local/share/man/man7 + [[ -d '/usr/local/share/man/man7' ]] && G_EXEC rmdir -p --ignore-fail-on-non-empty /usr/local/share/man/man7 fi fi } From 160b8eac7f1894a5d0e1a010da1a47f6525fa555 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 18 Apr 2024 23:02:10 +0200 Subject: [PATCH 133/266] v9.4 - Raspberry Pi | Pro-actively install tiny-initramfs to satisfy the upcoming initramfs dependency for new Raspberry Pi kernel packages: https://github.com/RPi-Distro/repo/issues/358 --- .build/images/dietpi-installer | 7 ++++--- .update/pre-patches | 20 ++++++++++++++++++++ dietpi/func/dietpi-set_software | 2 +- 3 files changed, 25 insertions(+), 4 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 6a9814b96c..c114200700 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1244,8 +1244,6 @@ _EOF_ # ARMv6/7: Add raspi-copies-and-fills local a32bit=() (( $G_HW_ARCH == 3 )) || a32bit=('raspi-copies-and-fills') - # Install our own raspberrypi-sys-mods - G_EXEC curl -sSfO 'https://dietpi.com/downloads/binaries/raspberrypi-sys-mods.deb' if findmnt -M /boot/firmware &> /dev/null then local kernel=() @@ -1270,7 +1268,10 @@ _EOF_ 5) kernel=('linux-image-rpi-2712');; *) { G_DIETPI-NOTIFY 1 "Unexpected hardware model passed: \"$G_HW_MODEL\". Aborting ..."; exit 1; };; esac - G_AGI raspi-firmware "${kernel[@]}" raspi-utils ./raspberrypi-sys-mods.deb raspberrypi-archive-keyring "${a32bit[@]}" + # tiny-initramfs to satisfy dependency: https://github.com/RPi-Distro/repo/issues/358 + G_AGI raspi-firmware + G_CONFIG_INJECT 'SKIP_INITRAMFS_GEN=' 'SKIP_INITRAMFS_GEN=yes' /etc/default/raspi-firmware + G_AGI "${kernel[@]}" raspi-utils raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}" tiny-initramfs else G_AGI raspberrypi-bootloader raspberrypi-kernel libraspberrypi0 libraspberrypi-bin ./raspberrypi-sys-mods.deb raspberrypi-archive-keyring "${a32bit[@]}" fi diff --git a/.update/pre-patches b/.update/pre-patches index e650adb30e..47c98d7b0a 100755 --- a/.update/pre-patches +++ b/.update/pre-patches @@ -412,5 +412,25 @@ _EOF_ fi fi +# v9.4 +if (( $G_DIETPI_VERSION_CORE < 9 || ( $G_DIETPI_VERSION_CORE == 9 && $G_DIETPI_VERSION_SUB < 4 ) )) +then + if (( $G_HW_MDOEL < 10 && $G_DISTRO > 6 )) && dpkg-query -s 'raspi-firmware' &> /dev/null + then + # Satisfy upcoming initramfs dependency of new kernel packages with slim tiny-initramfs: https://github.com/RPi-Distro/repo/issues/358 + G_CONFIG_INJECT 'SKIP_INITRAMFS_GEN=' 'SKIP_INITRAMFS_GEN=yes' /etc/default/raspi-firmware + if ! dpkg-query -s 'initramfs-tools' &> /dev/null + then + G_AGI tiny-initramfs + + elif apt-mark showauto | grep '^initramfs-tools$' + then + G_AGI tiny-initamfs + G_AGP initramfs-tools + # ToDo: Remove existing initramfs images in /boot/initrd-* and /boot/firmware/initramfs* + fi + fi +fi + exit 0 } diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 0c07a26a6c..eeda29c13f 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -771,7 +771,7 @@ deb $INPUT_MODE_VALUE $G_DISTRO_NAME-backports main contrib non-free' > /etc/apt \n- $optional for ${models[$optional]}" && to_install=("$optional") || to_remove=("$optional") fi - G_AGI "$kernel_package" "${to_install[@]}" raspi-firmware raspi-utils + G_AGI "$kernel_package" "${to_install[@]}" raspi-firmware raspi-utils tiny-initramfs G_AGP "${to_remove[@]}" raspberrypi-kernel raspberrypi-headers-kernel raspberrypi-bootloader libraspberrypi-bin libraspberrypi0 } From 3ca585ad517e9ff8ed136f1fe7c68f1ad1ae81b3 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 18 Apr 2024 23:08:34 +0200 Subject: [PATCH 134/266] v9.4 - DietPi-Pre-patches | Typo --- .update/pre-patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/pre-patches b/.update/pre-patches index 47c98d7b0a..c041090ab0 100755 --- a/.update/pre-patches +++ b/.update/pre-patches @@ -415,7 +415,7 @@ fi # v9.4 if (( $G_DIETPI_VERSION_CORE < 9 || ( $G_DIETPI_VERSION_CORE == 9 && $G_DIETPI_VERSION_SUB < 4 ) )) then - if (( $G_HW_MDOEL < 10 && $G_DISTRO > 6 )) && dpkg-query -s 'raspi-firmware' &> /dev/null + if (( $G_HW_MODEL < 10 && $G_DISTRO > 6 )) && dpkg-query -s 'raspi-firmware' &> /dev/null then # Satisfy upcoming initramfs dependency of new kernel packages with slim tiny-initramfs: https://github.com/RPi-Distro/repo/issues/358 G_CONFIG_INJECT 'SKIP_INITRAMFS_GEN=' 'SKIP_INITRAMFS_GEN=yes' /etc/default/raspi-firmware From d4aea5244a3ffa2c6ee4cedca0ba6bf88b4c4376 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 19 Apr 2024 15:50:23 +0200 Subject: [PATCH 135/266] v9.4 - DietPi-Installer | Remove manual U-Boot package downloads from our server, as those are now hosted in our APT repository --- .build/images/dietpi-installer | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index c114200700..018f0bdfda 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1041,9 +1041,9 @@ _EOF_ # Update APT lists G_AGUP # Install kernel, device tree, U-Boot, firmware and initramfs packages - local model='odroidn2' kernel='meson64' arch='arm64' branch='current' zstd=() dietpi_com=0 + local model='odroidn2' kernel='meson64' arch='arm64' branch='current' zstd=() case $G_HW_MODEL in - 10) model='odroidc1' kernel='meson' arch='arm' dietpi_com=1;; + 10) model='odroidc1' kernel='meson' arch='arm';; 11) model='odroidxu4' kernel='odroidxu4' arch='arm';; 12) model='odroidc2';; 16) model='odroidc4';; @@ -1068,14 +1068,14 @@ _EOF_ 2) model='nanopifire3';; *) model='nanopim3';; esac;; - 63) model='nanopim1' kernel='sunxi' arch='arm' dietpi_com=1;; + 63) model='nanopim1' kernel='sunxi' arch='arm';; 64) model='nanopiair' kernel='sunxi' arch='arm';; 65) kernel='sunxi64' case $HW_VARIANT in 2) model='nanopineo2black';; *) model='nanopineo2';; esac;; - 66) model='nanopim1plus' kernel='sunxi' arch='arm' dietpi_com=1;; + 66) model='nanopim1plus' kernel='sunxi' arch='arm';; 67) model='nanopik1plus' kernel='sunxi64';; 68) kernel='rockchip64' case $HW_VARIANT in @@ -1110,14 +1110,6 @@ _EOF_ 87) model='orangepi3b' kernel='rockchip64' branch='edge';; *) :;; esac - # Download and pre-install U-Boot hosted on dietpi.com where it has not been ported to the Armbian Bookworm repo or has been removed completely - if (( $dietpi_com && $G_DISTRO > 6 || $G_HW_MODEL == 62 )) - then - G_EXEC curl -sSfo package.deb "https://dietpi.com/downloads/binaries/linux-u-boot-$model-$branch.deb" - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb - G_EXEC rm package.deb - aPACKAGES_REQUIRED_INSTALL+=("linux-u-boot-$model-$branch") - fi # Odroid C1: https://dietpi.com/forum/t/odroid-c1-not-booting-after-kernel-upgrade/17818 if (( $G_HW_MODEL == 10 )) From acda521a58474122dc64662e0ed55540dd2e0560 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 19 Apr 2024 16:29:47 +0200 Subject: [PATCH 136/266] v9.4 - Orange Pi 3B | Added an option for updating the SPI bootloader via dietpi-config > Advanced Options > Update SPI bootloader. Since this implies generic support for flashcp based flashing to /dev/mtd using a different U-Boot image name as well, this re-adds the options for some other SBCs with recent U-Boot packages --- CHANGELOG.txt | 1 + dietpi/dietpi-config | 38 +++++++++++++++++++++++++++----------- 2 files changed, 28 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index d03de731bc..8dd3bdf604 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -4,6 +4,7 @@ v9.4 Enhancements: - General | Our scripts do now internally enforce the default umask 0022. Many config and install options rely on this, hence it can cause issues when e.g. 0027 (deny read access for "other" users) has been applied on the parent shell. This affects only the (sub)shell of our scripts, while the current and default umask of parent and of shells/consoles remains untouched. - NanoPi R5C | New images, or when flashing the new bootloader binary via dietpi-config > Advanced Options > Update MMC bootloader, support M.2 WiFi modules. +- Orange Pi 3B | Added an option for updating the SPI bootloader via dietpi-config > Advanced Options > Update SPI bootloader. Bug fixes: diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index 549a17b264..258900fff6 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -1068,11 +1068,17 @@ Re-enabling HDMI requires a reboot. If you need emergency HDMI output, edit the G_WHIP_MENU_ARRAY+=('Update RPi EEPROM firmware' ': Install rpi-eeprom APT package') fi - # ROCK 4, ROCK 5B and Orange Pi 5 (Plus): https://dietpi.com/forum/t/orange-pi-5-boot-from-nvme/16457 - elif [[ $G_HW_MODEL =~ ^(72|78|80|82)$ ]] + # ROCK 4, ROCK 5B, Orange Pi 5 (Plus) and Orange Pi 3B: https://dietpi.com/forum/t/orange-pi-5-boot-from-nvme/16457 + elif [[ $G_HW_MODEL =~ ^(72|78|80|82|87)$ ]] then # ROCK 4: Device tree overlay required - (( $G_HW_MODEL == 72 )) || [[ -b '/dev/mtdblock0' && -f '/usr/lib/u-boot/platform_install.sh' ]] && G_WHIP_MENU_ARRAY+=('Update SPI bootloader' ': Flash current U-Boot to /dev/mtdblock0') + local spidev='/dev/mtdblock0' + (( $G_HW_MODEL == 72 )) || { + [[ -f '/usr/lib/u-boot/platform_install.sh' ]] && { + { [[ -e '/dev/mtd0' ]] && grep -q '/dev/mtd0' /usr/lib/u-boot/platform_install.sh && spidev='/dev/mtd0'; } || + { [[ -b '/dev/mtdblock0' ]] && grep -q 'rksd_loader.img' /usr/lib/u-boot/platform_install.sh; } + } + } && G_WHIP_MENU_ARRAY+=("Update SPI bootloader' ': Flash current U-Boot to $spidev") # VisionFive 2/Star64: https://doc-en.rvspace.org/VisionFive2/PDF/VisionFive2_QSG.pdf elif (( $G_HW_MODEL == 81 || $G_HW_MODEL == 84 )) @@ -1238,17 +1244,27 @@ Further information: https://www.raspberrypi.org/documentation/hardware/raspberr G_CONFIG_INJECT 'overlays=' "overlays=${overlays[*]}" /boot/dietpiEnv.txt G_CONFIG_INJECT 'param_spinor_spi_bus=' 'param_spinor_spi_bus=1' /boot/dietpiEnv.txt REBOOT_REQUIRED=1 - return 0 fi - fi - G_WHIP_YESNO '[ INFO ] SPI bootloader update + + elif [[ $spidev == '/dev/mtd0' ]] + then + G_WHIP_YESNO '[ INFO ] SPI bootloader update +\nThis will flash the U-Boot image of the installed linux-u-boot-* package to the SPI device /dev/mtd0. +\nDo you want to continue?' || return 0 + G_AG_CHECK_INSTALL_PREREQ mtd-utils + # shellcheck disable=SC1091 + . /usr/lib/u-boot/platform_install.sh + write_uboot_platform_mtd + else + G_WHIP_YESNO '[ INFO ] SPI bootloader update \nThis will flash the U-Boot image of the installed linux-u-boot-* package to the SPI device /dev/mtdblock0. \nDo you want to continue?' || return 0 - # shellcheck disable=SC1091 - . /usr/lib/u-boot/platform_install.sh - [[ -f $DIR/rkspi_loader.img ]] || { G_WHIP_MSG "[FAILED] SPI U-Boot image missing\n\nThe expected U-Boot image at $DIR/rkspi_loader.img could not be found. Please report this to our GitHub or forum, so we can check back and in case update this dietpi-config option."; return 1; } - # shellcheck disable=SC2154 - G_EXEC_OUTPUT=1 G_EXEC dd if="$DIR/rkspi_loader.img" of=/dev/mtdblock0 oflag=direct conv=notrunc status=progress + # shellcheck disable=SC1091 + . /usr/lib/u-boot/platform_install.sh + [[ -f $DIR/rkspi_loader.img ]] || { G_WHIP_MSG "[FAILED] SPI U-Boot image missing\n\nThe expected U-Boot image at $DIR/rkspi_loader.img could not be found. Please report this to our GitHub or forum, so we can check back and in case update this dietpi-config option."; return 1; } + # shellcheck disable=SC2154 + G_EXEC_OUTPUT=1 G_EXEC dd if="$DIR/rkspi_loader.img" of=/dev/mtdblock0 oflag=direct conv=notrunc status=progress + fi elif [[ $G_WHIP_RETURNED_VALUE == 'Update bootloader' ]]; then From 7da2b57a78a35bc6db5f0778ca1601faaad7356c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 20 Apr 2024 13:44:24 +0200 Subject: [PATCH 137/266] v9.4 - CI | Armbian: Add support for more branches for RK35xx kernel builds --- .github/workflows/armbian.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 1872a37956..c966c872d2 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -11,7 +11,7 @@ on: branch: description: 'Branch' type: choice - options: [legacy, current, edge] + options: [legacy, current, edge, vendor, vendor-boogie-panthor, collabora] default: current required: true board: From 75e113d25068c991ea744fbaa9edd267f9c55ea7 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 20 Apr 2024 14:36:35 +0200 Subject: [PATCH 138/266] v9.4 - DietPi-Software | Snapcast: 64-bit ARM and Debian Bookworm + Trixie will have the now available packages from Snapcast installed, instead of those from the Debian repository. - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. --- CHANGELOG.txt | 2 ++ dietpi/dietpi-software | 36 +++++++++++++++++------------------- 2 files changed, 19 insertions(+), 19 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 8dd3bdf604..7d3093b4fb 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -5,8 +5,10 @@ Enhancements: - General | Our scripts do now internally enforce the default umask 0022. Many config and install options rely on this, hence it can cause issues when e.g. 0027 (deny read access for "other" users) has been applied on the parent shell. This affects only the (sub)shell of our scripts, while the current and default umask of parent and of shells/consoles remains untouched. - NanoPi R5C | New images, or when flashing the new bootloader binary via dietpi-config > Advanced Options > Update MMC bootloader, support M.2 WiFi modules. - Orange Pi 3B | Added an option for updating the SPI bootloader via dietpi-config > Advanced Options > Update SPI bootloader. +- DietPi-Software | Snapcast: 64-bit ARM and Debian Bookworm + Trixie will have the now available packages from Snapcast installed, instead of those from the Debian repository. Bug fixes: +- DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 3c3f3c44da..0d1b149cb1 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9953,7 +9953,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.15.0.4361/Prowlarr.master.1.15.0.4361.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.16.2.4435/Prowlarr.master.1.16.2.4435.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Prowlarr/Prowlarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC mv Prowlarr /opt/prowlarr fi @@ -11497,20 +11497,19 @@ _EOF_ if To_Install 191 snapserver # Snapcast Server then - # ARMv6/7/x86_64: Install package from GitHub repo (no Bookworm as package depends on libflac8) - if (( $G_DISTRO < 7 )) && [[ $G_HW_ARCH =~ ^(1|2|10)$ ]] + # RISC-V: Install from Debian repo: https://github.com/badaix/snapcast/releases + if (( $G_HW_ARCH == 11 )) then - local arch='armhf' - (( $G_HW_ARCH == 10 )) && arch='amd64' - local fallback_url="https://github.com/badaix/snapcast/releases/download/v0.27.0/snapserver_0.27.0-1_$arch.deb" - Download_Install "$(curl -sSfL 'https://api.github.com/repos/badaix/snapcast/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/snapserver_[^\"\/]*_$arch.deb\"/{print \$4}")" - - # Else install from Debian repo - else G_AGI snapserver # Enable web UI to align with upstream package G_CONFIG_INJECT 'doc_root[[:blank:]=]' 'doc_root = /usr/share/snapserver/snapweb' /etc/snapserver.conf '\[http\]' + else + local arch=$(dpkg --print-architecture) dist=${G_DISTRO_NAME/trixie/bookworm} + local fallback_url="https://github.com/badaix/snapcast/releases/download/v0.28.0/snapcast_0.28.0_$arch-debian-$dist.zip" + Download_Install "$(curl -sSfL 'https://api.github.com/repos/badaix/snapcast/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/snapcast_[^\"\/]*_$arch-debian-$dist.zip\"/{print \$4}")" + G_AGI ./snapserver_*_"$dist.deb" + G_EXEC rm snap*.deb fi G_EXEC systemctl stop snapserver @@ -11520,17 +11519,16 @@ _EOF_ if To_Install 192 snapclient # Snapcast Client then - # ARMv6/7/x86_64: Install package from GitHub repo (no Bookworm as package depends on libflac8) - if (( $G_DISTRO < 7 )) && [[ $G_HW_ARCH =~ ^(1|2|10)$ ]] + # RISC-V: Install from Debian repo: https://github.com/badaix/snapcast/releases + if (( $G_HW_ARCH == 11 )) then - local arch='armhf' - (( $G_HW_ARCH == 10 )) && arch='amd64' - local fallback_url="https://github.com/badaix/snapcast/releases/download/v0.27.0/snapclient_0.27.0-1_without-pulse_$arch.deb" - Download_Install "$(curl -sSfL 'https://api.github.com/repos/badaix/snapcast/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/snapclient_[^\"\/]*_without-pulse_$arch.deb\"$/{print \$4}")" - - # Else install from Debian repo - else G_AGI snapclient + else + local arch=$(dpkg --print-architecture) dist=${G_DISTRO_NAME/trixie/bookworm} + local fallback_url="https://github.com/badaix/snapcast/releases/download/v0.28.0/snapcast_0.28.0_$arch-debian-$dist.zip" + Download_Install "$(curl -sSfL 'https://api.github.com/repos/badaix/snapcast/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/snapcast_[^\"\/]*_$arch-debian-$dist.zip\"/{print \$4}")" + G_AGI ./snapclient_*_without-pulse_"$dist.deb" + G_EXEC rm snap*.deb fi G_EXEC systemctl stop snapclient From 79086e1539e33506682f0e1f0b7383ef9d30179a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 20 Apr 2024 16:06:05 +0200 Subject: [PATCH 139/266] v9.4 - CI | Armbian: Always rebase onto latest upstream commit --- .github/workflows/armbian.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index c966c872d2..306267b2a7 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -37,6 +37,16 @@ jobs: branch='${{ github.event.inputs.gitbranch }}' [ "$branch" ] || branch='main' git clone -b "$branch" --depth=1 "https://github.com/$owner/build" + if [ "$owner" != 'armbian' ] + then + git remote add upstream https://github.com/armbian/build + git fetch upstream main + git rebase upstream main + elif [ "$branch" != 'main' ] + then + git fetch origin main + git rebase main + fi - name: Build asset run: | cd build From 44177aa6bf7d09be2cfa44770cb3487ae142f441 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 20 Apr 2024 16:24:08 +0200 Subject: [PATCH 140/266] v9.4 - CI | Armbian: Fix rebase --- .github/workflows/armbian.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 306267b2a7..c0486aa36c 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -37,6 +37,7 @@ jobs: branch='${{ github.event.inputs.gitbranch }}' [ "$branch" ] || branch='main' git clone -b "$branch" --depth=1 "https://github.com/$owner/build" + cd build if [ "$owner" != 'armbian' ] then git remote add upstream https://github.com/armbian/build @@ -49,7 +50,6 @@ jobs: fi - name: Build asset run: | - cd build ./compile.sh '${{ github.event.inputs.asset }}' BRANCH='${{ github.event.inputs.branch }}' BOARD='${{ github.event.inputs.board }}' - name: Upload run: | From e6183a652962bef3b9520d15a0188792ed0d0827 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 20 Apr 2024 16:28:02 +0200 Subject: [PATCH 141/266] v9.4 - CI | Armbian: Fix rebase --- .github/workflows/armbian.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index c0486aa36c..67db92831a 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -42,7 +42,7 @@ jobs: then git remote add upstream https://github.com/armbian/build git fetch upstream main - git rebase upstream main + git rebase upstream/main elif [ "$branch" != 'main' ] then git fetch origin main From 47a24d6330411b2a266cf4b20eb04a5abffce24b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 20 Apr 2024 16:33:54 +0200 Subject: [PATCH 142/266] v9.4 - CI | Armbian: Allow to skip rebase --- .github/workflows/armbian.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 67db92831a..f184b79247 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -21,6 +21,10 @@ on: description: 'Override Git owner of Armbian repo' gitbranch: description: 'Override Git branch of Armbian repo' + rebase: + description: 'Rebase onto latest armbian/main' + type: boolean + default: true concurrency: group: ${{ github.workflow }}-${{ github.event.inputs.asset }}-${{ github.event.inputs.branch }}-${{ github.event.inputs.board }} cancel-in-progress: true @@ -38,6 +42,7 @@ jobs: [ "$branch" ] || branch='main' git clone -b "$branch" --depth=1 "https://github.com/$owner/build" cd build + [ '${{ github.event.inputs.rebase }}' == 'false' ] && exit 0 || : if [ "$owner" != 'armbian' ] then git remote add upstream https://github.com/armbian/build From 1d0d39ff3b8bb0ab9d6b7b33c8e0f0da048342dc Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 20 Apr 2024 16:37:09 +0200 Subject: [PATCH 143/266] v9.4 - CI | Fix skipping rebase --- .github/workflows/armbian.yml | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index f184b79247..6af27719ac 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -42,16 +42,18 @@ jobs: [ "$branch" ] || branch='main' git clone -b "$branch" --depth=1 "https://github.com/$owner/build" cd build - [ '${{ github.event.inputs.rebase }}' == 'false' ] && exit 0 || : - if [ "$owner" != 'armbian' ] + if [ '${{ github.event.inputs.rebase }}' == 'true' ] then - git remote add upstream https://github.com/armbian/build - git fetch upstream main - git rebase upstream/main - elif [ "$branch" != 'main' ] - then - git fetch origin main - git rebase main + if [ "$owner" != 'armbian' ] + then + git remote add upstream https://github.com/armbian/build + git fetch upstream main + git rebase upstream/main + elif [ "$branch" != 'main' ] + then + git fetch origin main + git rebase main + fi fi - name: Build asset run: | From b41a92cc9e3f1fe8f950d1cd919fad6f38ffe33d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 20 Apr 2024 16:39:15 +0200 Subject: [PATCH 144/266] v9.4 - CI | Armbian: ... --- .github/workflows/armbian.yml | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 6af27719ac..e0d848ab41 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -41,22 +41,21 @@ jobs: branch='${{ github.event.inputs.gitbranch }}' [ "$branch" ] || branch='main' git clone -b "$branch" --depth=1 "https://github.com/$owner/build" + [ '${{ github.event.inputs.rebase }}' == 'false' ] && exit 0 || : cd build - if [ '${{ github.event.inputs.rebase }}' == 'true' ] + if [ "$owner" != 'armbian' ] then - if [ "$owner" != 'armbian' ] - then - git remote add upstream https://github.com/armbian/build - git fetch upstream main - git rebase upstream/main - elif [ "$branch" != 'main' ] - then - git fetch origin main - git rebase main - fi + git remote add upstream https://github.com/armbian/build + git fetch upstream main + git rebase upstream/main + elif [ "$branch" != 'main' ] + then + git fetch origin main + git rebase main fi - name: Build asset run: | + cd build ./compile.sh '${{ github.event.inputs.asset }}' BRANCH='${{ github.event.inputs.branch }}' BOARD='${{ github.event.inputs.board }}' - name: Upload run: | From bfd0acc8fab45e7d9783f8356d93ce5ee0fe7720 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 20 Apr 2024 20:45:24 +0200 Subject: [PATCH 145/266] v9.4 - DietPi-Software | Snapcast: Fix package name --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 0d1b149cb1..b1897635f4 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11508,7 +11508,7 @@ _EOF_ local arch=$(dpkg --print-architecture) dist=${G_DISTRO_NAME/trixie/bookworm} local fallback_url="https://github.com/badaix/snapcast/releases/download/v0.28.0/snapcast_0.28.0_$arch-debian-$dist.zip" Download_Install "$(curl -sSfL 'https://api.github.com/repos/badaix/snapcast/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/snapcast_[^\"\/]*_$arch-debian-$dist.zip\"/{print \$4}")" - G_AGI ./snapserver_*_"$dist.deb" + G_AGI ./snapserver_*_"$arch.deb" G_EXEC rm snap*.deb fi G_EXEC systemctl stop snapserver @@ -11527,7 +11527,7 @@ _EOF_ local arch=$(dpkg --print-architecture) dist=${G_DISTRO_NAME/trixie/bookworm} local fallback_url="https://github.com/badaix/snapcast/releases/download/v0.28.0/snapcast_0.28.0_$arch-debian-$dist.zip" Download_Install "$(curl -sSfL 'https://api.github.com/repos/badaix/snapcast/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/snapcast_[^\"\/]*_$arch-debian-$dist.zip\"/{print \$4}")" - G_AGI ./snapclient_*_without-pulse_"$dist.deb" + G_AGI ./snapclient_*_without-pulse_"$arch.deb" G_EXEC rm snap*.deb fi G_EXEC systemctl stop snapclient From 3da35f5996b093bc9cbdfcc603ab38a35691e4a7 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 21 Apr 2024 15:46:27 +0200 Subject: [PATCH 146/266] v9.4 - DietPi-Software | Readarr: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index b1897635f4..ad7d1f3829 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10028,7 +10028,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.23.2506/Readarr.develop.0.3.23.2506.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.24.2510/Readarr.develop.0.3.24.2510.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Readarr/Readarr/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}" | head -1)" G_EXEC mv Readarr /opt/readarr fi From 1004d606a9c3ced7215ec28cc7eba25e32c72b1b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 21 Apr 2024 16:44:51 +0200 Subject: [PATCH 147/266] v9.4 - DietPi-Build/Installer | Add support for ROCK 4C Plus, since the recent ROCK 4B bootloader does not select the correct device tree automatically anymore, and cleanup method for installing self-hosted kernel/bootloader builds. --- .build/images/dietpi-build | 1 + .build/images/dietpi-installer | 25 ++++++++++++++----------- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 2464c916d4..d70376fb2a 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -122,6 +122,7 @@ case $HW_MODEL in 70) iname='SparkySBC' HW_ARCH=2 partition_start=8 boot_size=48 root_size=712 boot_fstype='fat16';; '72.1') iname='ROCKPi4' HW_ARCH=3 partition_start=16 root_size=1008;; '72.2') iname='ROCK4SE' HW_ARCH=3 partition_start=16 root_size=1008;; + '72.3') iname='ROCK4CPlus' HW_ARCH=3 partition_start=16 root_size=1008;; 73) iname='ROCKPiS' HW_ARCH=3 partition_start=16 root_size=1008;; 74) iname='RadxaZero' HW_ARCH=3 partition_start=4 root_size=1020;; 75) iname='Container' HW_ARCH=${HW_ARCH:-10} root_size=575;; diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 018f0bdfda..6c37f6365b 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -412,6 +412,7 @@ _EOF_ '79.3' ': NanoPC T6' '72.1' ': ROCK 4 (all other variants)' '72.2' ': ROCK 4 SE' + '72.3' ': ROCK 4C Plus' '73' ': ROCK Pi S' '74' ': Radxa Zero' '77' ': ROCK 3A' @@ -1041,7 +1042,7 @@ _EOF_ # Update APT lists G_AGUP # Install kernel, device tree, U-Boot, firmware and initramfs packages - local model='odroidn2' kernel='meson64' arch='arm64' branch='current' zstd=() + local model='odroidn2' kernel='meson64' arch='arm64' branch='current' zstd=() dietpi_uboot=0 dietpi_kernel=0 case $G_HW_MODEL in 10) model='odroidc1' kernel='meson' arch='arm';; 11) model='odroidxu4' kernel='odroidxu4' arch='arm';; @@ -1086,6 +1087,7 @@ _EOF_ 72) kernel='rockchip64' case $HW_VARIANT in 2) model='rock-4se';; + 3) model='rockpi-4cplus';; *) model='rockpi-4b';; esac;; 73) model='rockpi-s' kernel='rockchip64';; @@ -1136,22 +1138,23 @@ _EOF_ fi # Install initramfs-tools first to have an initramfs generated on kernel install, and configure it to use zstd if supported for better compression and faster decompression [[ $kernel == 'rockchip64' || $kernel == 'rk35xx' || $kernel == 'meson64' || $kernel == 'sunxi64' || $kernel == 'sunxi' || $kernel == 'rockchip' ]] && zstd=('zstd') - # - Download and pre-install a more recent armbian-firmware package from our server - #G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' - #G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb - #G_EXEC rm package.deb G_AGI initramfs-tools u-boot-tools armbian-firmware "${zstd[@]}" [[ ${zstd[0]} ]] && G_CONFIG_INJECT 'COMPRESS=' 'COMPRESS=zstd' /etc/initramfs-tools/initramfs.conf - # Download and pre-install kernel hosted on dietpi.com where the Armbian APT repo provides a too old version - if (( $G_HW_MODEL == 83 )) + # Download and pre-install kernel hosted on dietpi.com where the Armbian APT repo provides a too old version or is not available + if (( $dietpi_kernel )) then G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb "https://dietpi.com/downloads/binaries/linux-image-$branch-$kernel.deb" G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb "https://dietpi.com/downloads/binaries/linux-dtb-$branch-$kernel.deb" G_EXEC_OUTPUT=1 G_EXEC curl -fo package3.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' - local uboot=() - #(( $G_HW_MODEL == 83 )) && (( $HW_VARIANT == 1 )) && { G_EXEC_OUTPUT=1 G_EXEC curl -fo package4.deb "https://dietpi.com/downloads/binaries/linux-u-boot-$model-$branch.deb"; uboot=('package4.deb'); } - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package1.deb package2.deb package3.deb "${uboot[@]}" - G_EXEC rm package1.deb package2.deb package3.deb "${uboot[@]}" + G_EXEC_OUTPUT=1 G_EXEC dpkg -i package[1-3].deb + G_EXEC rm package[1-3].deb + fi + # Download and pre-install U-Boot hosted on dietpi.com where the Armbian APT repo provides a too old version or is not available + if (( $dietpi_uboot )) + then + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/linux-u-boot-$model-$branch.deb" + G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb + G_EXEC rm package.deb fi # Orange Pi Zero 3 1.5G RAM variant: Install original Orange Pi bootloader if (( $G_HW_MODEL == 83 )) && (( $HW_VARIANT == 2 )) From 977a3b4d80977208a06ca1ec44fa64cfdaa91890 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 21 Apr 2024 17:19:37 +0200 Subject: [PATCH 148/266] v9.4 - CHANGELOG | Add entry for new ROCK 4C Plus image --- CHANGELOG.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 7d3093b4fb..296862db51 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,6 +1,9 @@ v9.4 (2024-05-12) +New images: +- ROCK 4C Plus | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4C Plus, we provide a new image for this particular variant. Many thanks to @lfiorini and @arpegius5555 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6593, https://github.com/MichaIng/DietPi/issues/6935 + Enhancements: - General | Our scripts do now internally enforce the default umask 0022. Many config and install options rely on this, hence it can cause issues when e.g. 0027 (deny read access for "other" users) has been applied on the parent shell. This affects only the (sub)shell of our scripts, while the current and default umask of parent and of shells/consoles remains untouched. - NanoPi R5C | New images, or when flashing the new bootloader binary via dietpi-config > Advanced Options > Update MMC bootloader, support M.2 WiFi modules. From b05711fcb73db36e2a7c5fdb7b8beb96d24ef3d6 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 21 Apr 2024 21:21:10 +0200 Subject: [PATCH 149/266] v9.4 - CI | Use GITHUB_REF_NAME instead of scraping from GITHUB_REF --- .github/workflows/dietpi-build.yml | 2 +- .github/workflows/raspberrypi-sys-mods.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index cb92edee03..d8f98dc353 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -130,4 +130,4 @@ jobs: ${{ secrets.GPG_KEY }} _EOF_ - name: Run DietPi-Build - run: sudo bash -c "G_GITOWNER=$GITHUB_REPOSITORY_OWNER G_GITBRANCH=${GITHUB_REF#refs/heads/}; $(curl -sSf "https://raw.githubusercontent.com/$GITHUB_REPOSITORY_OWNER/DietPi/${GITHUB_REF#refs/heads/}/.build/images/dietpi-build")" 'DietPi-Build' ${{ matrix.buildargs }} --sign '${{ secrets.GPG_PASS }}' + run: sudo bash -c "G_GITOWNER=$GITHUB_REPOSITORY_OWNER G_GITBRANCH=$GITHUB_REF_NAME; $(curl -sSf "https://raw.githubusercontent.com/$GITHUB_REPOSITORY_OWNER/DietPi/$GITHUB_REF_NAME/.build/images/dietpi-build")" 'DietPi-Build' ${{ matrix.buildargs }} --sign '${{ secrets.GPG_PASS }}' diff --git a/.github/workflows/raspberrypi-sys-mods.yml b/.github/workflows/raspberrypi-sys-mods.yml index ea4e845776..675e3af75e 100644 --- a/.github/workflows/raspberrypi-sys-mods.yml +++ b/.github/workflows/raspberrypi-sys-mods.yml @@ -10,7 +10,7 @@ jobs: runs-on: ubuntu-22.04 steps: - name: Build - run: sudo bash -c "$(curl -sSf "https://raw.githubusercontent.com/$GITHUB_REPOSITORY_OWNER/DietPi/${GITHUB_REF#refs/heads/}/.build/software/raspberrypi-sys-mods/build.bash")" + run: sudo bash -c "$(curl -sSf "https://raw.githubusercontent.com/$GITHUB_REPOSITORY_OWNER/DietPi/$GITHUB_REF_NAME/.build/software/raspberrypi-sys-mods/build.bash")" - name: Upload run: | # SSH server and client keys From 234cc689fa8f4c7736300661b01204373abc9824 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 22 Apr 2024 23:41:42 +0200 Subject: [PATCH 150/266] v9.4 - DietPi-Software | Kavita: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index ad7d1f3829..e2f8231e80 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6302,7 +6302,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.8.0/kavita-linux-$arch.tar.gz" + local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.8.1/kavita-linux-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Kareadita/Kavita/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/kavita-linux-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC chmod +x Kavita/Kavita From 079710ad0f58d5bf7682c5dc71b3de109dd07873 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 23 Apr 2024 13:15:15 +0200 Subject: [PATCH 151/266] v9.4 (#7033) - DietPi-Imager | Skip moving backup partition table before touching the image. parted/sfdisk may throw warnings, but the step can fail if the last partition reaches the end of the image, e.g. if the file was cut right after the last partition, ignoring the backup table. Additionally, obtain the size needed for the GPT backup correctly by the first usabe LBA/sector, instead of using the 34 sectors default GPT size. fdisk/sfdisk use 2048 by default, while parted defaults to the actual 34 sectors the GPT truly uses. --- .build/images/dietpi-imager | 18 +++++++++++------- CHANGELOG.txt | 1 + 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/.build/images/dietpi-imager b/.build/images/dietpi-imager index 47412ad2e1..fdc61988b5 100755 --- a/.build/images/dietpi-imager +++ b/.build/images/dietpi-imager @@ -336,10 +336,7 @@ # Move GPT backup partition table to end of drive elif [[ $PART_TABLE_TYPE == 'gpt' ]] then - G_DIETPI-NOTIFY 2 'GPT partition table detected, moving GPT backup partition table to end of drive...' - G_AG_CHECK_INSTALL_PREREQ gdisk - G_EXEC_OUTPUT=1 G_EXEC sgdisk -e "$FP_SOURCE" - G_SLEEP 0.5 # Give the root filesystem a little time to be detected + G_DIETPI-NOTIFY 2 'GPT partition table detected' else Error_Exit "Unknown partition table type ($PART_TABLE_TYPE), aborting..." fi @@ -512,9 +509,16 @@ # - WARNING: this assumes that the partitions in the table are in order (which we do in other places as well) local last_part_end=$(sfdisk -qlo End "$FP_SOURCE" | tail -1) # 512 byte sectors IMAGE_SIZE=$last_part_end - # Add 34 sectors for GPT backup partition table and 1 sector for MBR - # shellcheck disable=SC2015 - [[ $PART_TABLE_TYPE == 'gpt' ]] && ((IMAGE_SIZE+=34)) || ((IMAGE_SIZE++)) + # Add space for GPT backup partition table, or 1 sector for MBR + if [[ $PART_TABLE_TYPE == 'gpt' ]] + then + # Obtain first usable LBA, which defines the size of the GPT backup, else use 34 sectors as default: https://github.com/MichaIng/DietPi/issues/7024 + local gpt_size=$(sgdisk -p "$FP_SOURCE" 2>&1 | mawk -F[\ ,] '/^First usable sector/{print $5}') + # shellcheck disable=SC2015 + (( $gpt_size )) && ((IMAGE_SIZE+=$gpt_size)) || ((IMAGE_SIZE+=34)) + else + ((IMAGE_SIZE++)) + fi ((IMAGE_SIZE*=512)) # 512 byte sectors => bytes # RPi: Move configs to boot FAT partition to allow easier edit from Windows/macOS diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 296862db51..2a51cfa2f8 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -11,6 +11,7 @@ Enhancements: - DietPi-Software | Snapcast: 64-bit ARM and Debian Bookworm + Trixie will have the now available packages from Snapcast installed, instead of those from the Debian repository. Bug fixes: +- DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME From f372c8ac3cb26d486eaf5fe50ed64628549ab02b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 24 Apr 2024 14:34:04 +0200 Subject: [PATCH 152/266] v9.4 - CI | DietPi-Software test: Temporarily remove the Microsoft APT repository, which currently fails to fetch - DietPi-Software | Komga: Update fallback URL - DietPi-Set_hardware | Remove pre-v6.10 step when disabling the Waveshare32 LCD, which just removes a comment line, added in ancient DietPi versions when enabling it --- .github/workflows/dietpi-software.bash | 2 ++ dietpi/dietpi-software | 2 +- dietpi/func/dietpi-set_hardware | 1 - 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index f10f4e2687..ae6abf853b 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -260,6 +260,8 @@ done ########################################## apackages=('xz-utils' 'parted' 'fdisk' 'systemd-container') (( $G_HW_ARCH == $arch || ( $G_HW_ARCH < 10 && $G_HW_ARCH > $arch ) )) || apackages+=('qemu-user-static' 'binfmt-support') +# Temporary workaround for failing Microsoft repo fetch: https://github.com/microsoft/linux-package-repositories/issues/130 +G_EXEC rm /etc/apt/sources.list.d/microsoft-prod.list G_AG_CHECK_INSTALL_PREREQ "${apackages[@]}" ########################################## diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index e2f8231e80..84593d594e 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -7434,7 +7434,7 @@ _EOF_ then Download_Install 'https://github.com/gotson/komga/releases/download/v0.165.0/komga-0.165.0.jar' /mnt/dietpi_userdata/komga/komga.jar else - local fallback_url='https://github.com/gotson/komga/releases/download/1.11.0/komga-1.11.0.jar' + local fallback_url='https://github.com/gotson/komga/releases/download/1.11.1/komga-1.11.1.jar' Download_Install "$(curl -sSfL 'https://api.github.com/repos/gotson/komga/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/komga-[^"\/]*\.jar"$/{print $4}')" /mnt/dietpi_userdata/komga/komga.jar fi diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 0108f1d727..e5b3747fd0 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -803,7 +803,6 @@ _EOF_ [[ -f '/boot/overlays/waveshare32b.dtbo' ]] && G_EXEC rm /boot/overlays/waveshare32b.dtbo G_EXEC sed --follow-symlinks -i 's/ fbcon=map:10 fbcon=font:ProFont6x11 logo.nologo//' /boot/cmdline.txt - G_EXEC sed --follow-symlinks -i '/Waveshare 32 LCD/d' /boot/config.txt G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*dtoverlay=waveshare32b/d' /boot/config.txt G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*dtoverlay=ads7846,cs=1,penirq=17/d' /boot/config.txt G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*dtoverlay=w1-gpio-pullup,gpiopin=4,extpullup=1/d' /boot/config.txt From 2080acdc853e2f30863d80ed06ad7e9d0e0bdb33 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 24 Apr 2024 16:00:54 +0200 Subject: [PATCH 153/266] v9.4 - DietPi-Software | OctoPrint: Resolved an issue where the installation failed on RISC-V and ARMv6/7 Bullseye systems, due to changed dependencies. - CI | DietPi-Software test: Remove workaround for fixed Microsoft repo issue --- .github/workflows/dietpi-software.bash | 2 -- CHANGELOG.txt | 1 + dietpi/dietpi-software | 17 +++++++++++------ 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index ae6abf853b..f10f4e2687 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -260,8 +260,6 @@ done ########################################## apackages=('xz-utils' 'parted' 'fdisk' 'systemd-container') (( $G_HW_ARCH == $arch || ( $G_HW_ARCH < 10 && $G_HW_ARCH > $arch ) )) || apackages+=('qemu-user-static' 'binfmt-support') -# Temporary workaround for failing Microsoft repo fetch: https://github.com/microsoft/linux-package-repositories/issues/130 -G_EXEC rm /etc/apt/sources.list.d/microsoft-prod.list G_AG_CHECK_INSTALL_PREREQ "${apackages[@]}" ########################################## diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 2a51cfa2f8..1ded7a0554 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -13,6 +13,7 @@ Enhancements: Bug fixes: - DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. +- DietPi-Software | OctoPrint: Resolved an issue where the installation failed on RISC-V and ARMv6/7 Bullseye systems, due to changed dependencies. As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 84593d594e..463f75f130 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10143,14 +10143,19 @@ _EOF_ if To_Install 153 octoprint # OctoPrint then # Deps - # - RISC-V and ARMv6/7 Bookworm: gcc and libffi-dev for cffi - if (( $G_HW_ARCH == 11 || ( $G_HW_ARCH < 3 && $G_DISTRO > 6 ) )) + # - RISC-V: gcc and libffi-dev for cffi, Rust for maturin + if (( $G_HW_ARCH == 11 )) then - G_AGI gcc libffi-dev + aDEPS=('gcc' 'libffi-dev') + G_EXEC curl -sSf 'https://sh.rustup.rs/' -o rustup-init.sh + G_EXEC chmod +x rustup-init.sh + G_EXEC_OUTPUT=1 G_EXEC ./rustup-init.sh -y --profile minimal + G_EXEC rm rustup-init.sh + export PATH="/root/.cargo/bin:$PATH" - # - ARMv8:: gcc for netifaces and psutil - # - Bookworm: gcc for netifaces - elif (( $G_HW_ARCH == 3 || $G_DISTRO > 6 )) + # - ARMv8: gcc for psutil + # - ARMv6/7: gcc for regex: https://github.com/piwheels/packages/issues/442 + elif (( $G_HW_ARCH == 3 || ( $G_HW_ARCH < 3 && $G_DISTRO == 6 ) )) then G_AGI gcc fi From 7a851cc180f5f6c38e82c1d1e7fe9c4e14a6d4dc Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 24 Apr 2024 16:02:28 +0200 Subject: [PATCH 154/266] v9.4 - DietPi-Software | Prometheus Node Exporter: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 463f75f130..88dac89ab5 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3332,7 +3332,7 @@ _EOF_ esac # Download binary - local fallback_url="https://github.com/prometheus/node_exporter/releases/download/v1.7.0/node_exporter-1.7.0.linux-$arch.tar.gz" + local fallback_url="https://github.com/prometheus/node_exporter/releases/download/v1.8.0/node_exporter-1.8.0.linux-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/prometheus/node_exporter/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/node_exporter-.*\.linux-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC mkdir -p /opt/node_exporter G_EXEC cp --preserve=mode node_exporter*/node_exporter /opt/node_exporter/ From f0adb283a401b115f7b8ce5f1029ced12e0a0fb4 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 24 Apr 2024 16:51:44 +0200 Subject: [PATCH 155/266] v9.4 - DietPi-Software | OctoPrint: The Rust compiler, required for RISC-V, needs to be available for the "octoprint" user - DietPi-Software | HTPC Manager: Skip obsolete dependencies for installs on ARMv6/7 Bookworm/Trixie systems --- dietpi/dietpi-software | 38 +++++++++++++++++--------------------- 1 file changed, 17 insertions(+), 21 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 88dac89ab5..57832afe23 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10085,22 +10085,18 @@ _EOF_ # APT deps case $G_HW_ARCH in - [12]|11) - if (( $G_DISTRO < 7 )) - then - G_AGI libtiff5 libopenjp2-7 libxcb1 # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff5 pulls libjpeg62-turbo) - else - # Bookworm: Most wheels need to be compiled: gcc and libffi-dev for cffi, libssl-dev and Rust for cryptography and bcrypt, make for PyNaCl, libjpeg62-turbo-dev for Pillow, pkg-config for cryptography - G_AGI gcc libffi-dev libssl-dev make libjpeg62-turbo-dev pkg-config - G_EXEC curl -sSf 'https://sh.rustup.rs/' -o rustup-init.sh - G_EXEC chmod +x rustup-init.sh - # RPi with 64-bit kernel on 32-bit image: Enforce 32-bit toolchain: https://github.com/MichaIng/DietPi/issues/6306 - G_EXEC_OUTPUT=1 G_EXEC ./rustup-init.sh -y --profile minimal ${RPI_64KERNEL_32OS:+'--default-host' 'armv7-unknown-linux-gnueabihf'} - G_EXEC rm rustup-init.sh - export PATH="/root/.cargo/bin:$PATH" - fi - ;; + 1|2) G_AGI libtiff5 libopenjp2-7 libxcb1;; # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff5 pulls libjpeg62-turbo) 3) G_AGI gcc;; # gcc for psutil + 11) + # gcc and libffi-dev for cffi, libssl-dev and Rust for cryptography and bcrypt, make for PyNaCl, libjpeg62-turbo-dev for Pillow, pkg-config for cryptography + G_AGI gcc libffi-dev libssl-dev make libjpeg62-turbo-dev pkg-config + G_EXEC curl -sSf 'https://sh.rustup.rs/' -o rustup-init.sh + G_EXEC chmod +x rustup-init.sh + # RPi with 64-bit kernel on 32-bit image: Enforce 32-bit toolchain: https://github.com/MichaIng/DietPi/issues/6306 + G_EXEC_OUTPUT=1 G_EXEC ./rustup-init.sh -y --profile minimal ${RPI_64KERNEL_32OS:+'--default-host' 'armv7-unknown-linux-gnueabihf'} + G_EXEC rm rustup-init.sh + export PATH="/root/.cargo/bin:$PATH" + ;; *) :;; esac @@ -10142,6 +10138,11 @@ _EOF_ if To_Install 153 octoprint # OctoPrint then + # Pre-create user and its home directory to allow user-level (Rust and) Python instance + Create_User -G dialout,tty,video -d /mnt/dietpi_userdata/octoprint octoprint + G_EXEC mkdir -p /mnt/dietpi_userdata/octoprint + G_EXEC chown -R octoprint:octoprint /mnt/dietpi_userdata/octoprint + # Deps # - RISC-V: gcc and libffi-dev for cffi, Rust for maturin if (( $G_HW_ARCH == 11 )) @@ -10149,7 +10150,7 @@ _EOF_ aDEPS=('gcc' 'libffi-dev') G_EXEC curl -sSf 'https://sh.rustup.rs/' -o rustup-init.sh G_EXEC chmod +x rustup-init.sh - G_EXEC_OUTPUT=1 G_EXEC ./rustup-init.sh -y --profile minimal + G_EXEC_OUTPUT=1 G_EXEC sudo -u octoprint ./rustup-init.sh -y --profile minimal G_EXEC rm rustup-init.sh export PATH="/root/.cargo/bin:$PATH" @@ -10160,11 +10161,6 @@ _EOF_ G_AGI gcc fi - # Pre-create user and its home directory to allow user-level Python instance - Create_User -G dialout,tty,video -d /mnt/dietpi_userdata/octoprint octoprint - G_EXEC mkdir -p /mnt/dietpi_userdata/octoprint - G_EXEC chown -R octoprint:octoprint /mnt/dietpi_userdata/octoprint - # Clear pip cache in case it got somehow created [[ -d '/mnt/dietpi_userdata/octoprint/.cache' ]] && G_EXEC rm -R /mnt/dietpi_userdata/octoprint/.cache From f50aba81dd60c2632e2a280e7bf6dd9ecb1ef9f1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 24 Apr 2024 17:47:22 +0200 Subject: [PATCH 156/266] v9.4 - DietPi-Software | OctoPrint: Pass PATH correctly for RISC-V PATH --- dietpi/dietpi-software | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 57832afe23..29ed6c25c1 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10145,6 +10145,7 @@ _EOF_ # Deps # - RISC-V: gcc and libffi-dev for cffi, Rust for maturin + local aPATH=() if (( $G_HW_ARCH == 11 )) then aDEPS=('gcc' 'libffi-dev') @@ -10152,7 +10153,7 @@ _EOF_ G_EXEC chmod +x rustup-init.sh G_EXEC_OUTPUT=1 G_EXEC sudo -u octoprint ./rustup-init.sh -y --profile minimal G_EXEC rm rustup-init.sh - export PATH="/root/.cargo/bin:$PATH" + aPATH=("PATH='/mnt/dietpi_userdata/octoprint/.cargo/bin:$PATH'") # - ARMv8: gcc for psutil # - ARMv6/7: gcc for regex: https://github.com/piwheels/packages/issues/442 @@ -10165,7 +10166,7 @@ _EOF_ [[ -d '/mnt/dietpi_userdata/octoprint/.cache' ]] && G_EXEC rm -R /mnt/dietpi_userdata/octoprint/.cache # Install OctoPrint - G_EXEC_OUTPUT=1 G_EXEC sudo -u octoprint pip3 install -U --user --no-warn-script-location octoprint + G_EXEC_OUTPUT=1 G_EXEC sudo -u octoprint "${aPATH[@]}" pip3 install -U --user --no-warn-script-location octoprint # Service: https://github.com/OctoPrint/OctoPrint/blob/master/scripts/octoprint.service cat << '_EOF_' > /etc/systemd/system/octoprint.service From ea4959739e35c85178d1a9a827799736836a285e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 24 Apr 2024 17:50:02 +0200 Subject: [PATCH 157/266] v9.4 - CI | DietPi-Software test: Allow service in emulated container more time to startup --- .github/workflows/dietpi-software.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index f10f4e2687..46575d232f 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -181,7 +181,7 @@ Process_Software() 152) aSERVICES[i]='avahi-daemon' aUDP[i]='5353';; 153) aSERVICES[i]='octoprint' aTCP[i]='5001'; (( $arch == 10 )) || aDELAY[i]=60;; 154) aSERVICES[i]='roonserver';; # Listens on a variety of different port ranges - 155) aSERVICES[i]='htpc-manager' aTCP[i]='8085';; + 155) aSERVICES[i]='htpc-manager' aTCP[i]='8085'; (( $arch == 10 )) || aDELAY[i]=30;; 157) aSERVICES[i]='home-assistant' aTCP[i]='8123'; (( $arch == 10 )) && aDELAY[i]=60 || aDELAY[i]=900;; 158) aSERVICES[i]='minio' aTCP[i]='9001 9004';; 161) aSERVICES[i]='bdd' aTCP[i]='80 443';; From 9e872115cdbb47d539534396e308f40baf0a1ea9 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 24 Apr 2024 18:15:22 +0200 Subject: [PATCH 158/266] v9.4 - DietPi-Software | HTPC Manager: Fix libtiff version for Bookworm/Trixie - DietPi-Software | Synapse: Skip obsolete dependencies for installs on ARMv6/7 Bookworm/Trixie systems --- dietpi/dietpi-software | 34 +++++++++++++++++++--------------- 1 file changed, 19 insertions(+), 15 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 29ed6c25c1..f7908e1554 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3881,20 +3881,20 @@ _EOF_ then # APT deps for Synapse with PostgreSQL case $G_HW_ARCH in - [12]|11) - if (( $G_DISTRO < 7 )) - then - G_AGI libtiff5 libopenjp2-7 libxcb1 # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff5 pulls libjpeg62-turbo) - else - # Bookworm: Most wheels need to be compiled: gcc and libffi-dev for cffi, Rust for cryptography and matrix-synapse, libpq-dev for psycopg2, make for PyNaCl, libjpeg62-turbo-dev for Pillow, libssl-dev and pkg-config for cryptography - G_AGI gcc libffi-dev libpq-dev make libjpeg62-turbo-dev libssl-dev pkg-config - G_EXEC curl -sSf 'https://sh.rustup.rs/' -o rustup-init.sh - G_EXEC chmod +x rustup-init.sh - # RPi with 64-bit kernel on 32-bit image: Enforce 32-bit toolchain: https://github.com/MichaIng/DietPi/issues/6306 - G_EXEC_OUTPUT=1 G_EXEC ./rustup-init.sh -y --profile minimal ${RPI_64KERNEL_32OS:+'--default-host' 'armv7-unknown-linux-gnueabihf'} - G_EXEC rm rustup-init.sh - export PATH="/root/.cargo/bin:$PATH" - fi + 1|2) + local libtiff='libtiff6' + (( $G_DISTRO < 7 )) && libtiff='libtiff5' + G_AGI "$libtiff" libopenjp2-7 libxcb1;; # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff pulls libjpeg62-turbo) + ;; + 11) + # gcc and libffi-dev for cffi, Rust for cryptography and matrix-synapse, libpq-dev for psycopg2, make for PyNaCl, libjpeg62-turbo-dev for Pillow, libssl-dev and pkg-config for cryptography + G_AGI gcc libffi-dev libpq-dev make libjpeg62-turbo-dev libssl-dev pkg-config + G_EXEC curl -sSf 'https://sh.rustup.rs/' -o rustup-init.sh + G_EXEC chmod +x rustup-init.sh + # RPi with 64-bit kernel on 32-bit image: Enforce 32-bit toolchain: https://github.com/MichaIng/DietPi/issues/6306 + G_EXEC_OUTPUT=1 G_EXEC ./rustup-init.sh -y --profile minimal ${RPI_64KERNEL_32OS:+'--default-host' 'armv7-unknown-linux-gnueabihf'} + G_EXEC rm rustup-init.sh + export PATH="/root/.cargo/bin:$PATH" ;; *) G_AGI gcc libpq-dev;; # ARMv8/x86_64: psycopg2 needs to be compiled esac @@ -10085,7 +10085,11 @@ _EOF_ # APT deps case $G_HW_ARCH in - 1|2) G_AGI libtiff5 libopenjp2-7 libxcb1;; # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff5 pulls libjpeg62-turbo) + 1|2) + local libtiff='libtiff6' + (( $G_DISTRO < 7 )) && libtiff='libtiff5' + G_AGI "$libtiff" libopenjp2-7 libxcb1;; # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff pulls libjpeg62-turbo) + ;; 3) G_AGI gcc;; # gcc for psutil 11) # gcc and libffi-dev for cffi, libssl-dev and Rust for cryptography and bcrypt, make for PyNaCl, libjpeg62-turbo-dev for Pillow, pkg-config for cryptography From 6bfafb7b8b8efb323e1a48a9701e7cefe758de77 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 24 Apr 2024 18:25:57 +0200 Subject: [PATCH 159/266] v9.4 - DietPi-Software | Syntax --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index f7908e1554..47effc1e32 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3884,7 +3884,7 @@ _EOF_ 1|2) local libtiff='libtiff6' (( $G_DISTRO < 7 )) && libtiff='libtiff5' - G_AGI "$libtiff" libopenjp2-7 libxcb1;; # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff pulls libjpeg62-turbo) + G_AGI "$libtiff" libopenjp2-7 libxcb1 # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff pulls libjpeg62-turbo) ;; 11) # gcc and libffi-dev for cffi, Rust for cryptography and matrix-synapse, libpq-dev for psycopg2, make for PyNaCl, libjpeg62-turbo-dev for Pillow, libssl-dev and pkg-config for cryptography @@ -10088,7 +10088,7 @@ _EOF_ 1|2) local libtiff='libtiff6' (( $G_DISTRO < 7 )) && libtiff='libtiff5' - G_AGI "$libtiff" libopenjp2-7 libxcb1;; # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff pulls libjpeg62-turbo) + G_AGI "$libtiff" libopenjp2-7 libxcb1 # ARMv6/7: Runtime libs for Pillow from piwheels (libtiff pulls libjpeg62-turbo) ;; 3) G_AGI gcc;; # gcc for psutil 11) From 921bdb18e64a9728d74a41fe5b642fe1a4c7d210 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 24 Apr 2024 20:51:05 +0200 Subject: [PATCH 160/266] v9.4 - CI | DietPi-Software test: Add more service startup time for HTPC Manager on ARMv8 Trixie systems, needed for whatever reason --- .github/workflows/dietpi-software.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index 46575d232f..d735537fa5 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -181,7 +181,7 @@ Process_Software() 152) aSERVICES[i]='avahi-daemon' aUDP[i]='5353';; 153) aSERVICES[i]='octoprint' aTCP[i]='5001'; (( $arch == 10 )) || aDELAY[i]=60;; 154) aSERVICES[i]='roonserver';; # Listens on a variety of different port ranges - 155) aSERVICES[i]='htpc-manager' aTCP[i]='8085'; (( $arch == 10 )) || aDELAY[i]=30;; + 155) aSERVICES[i]='htpc-manager' aTCP[i]='8085'; (( $arch == 10 )) || aDELAY[i]=30; [[ $arch == 3 && $DISTRO == 'trixie' ]] && aDELAY[i]=60;; 157) aSERVICES[i]='home-assistant' aTCP[i]='8123'; (( $arch == 10 )) && aDELAY[i]=60 || aDELAY[i]=900;; 158) aSERVICES[i]='minio' aTCP[i]='9001 9004';; 161) aSERVICES[i]='bdd' aTCP[i]='80 443';; From a509085445ba5d4db3e9da16846bc6b713aaa754 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 11:28:16 +0200 Subject: [PATCH 161/266] v9.4 - DietPi-Software | Bazarr/OctoPrint: Remove obsolete dependencies --- dietpi/dietpi-software | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 47effc1e32..3a64d1c49b 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9666,8 +9666,7 @@ _EOF_ # APT deps if (( $G_HW_ARCH < 3 )) then - aDEPS=('g++' 'libopenblas-dev' 'pkg-config') # g++, libopenblas-dev and pkg-config for numpy until wheels have been built on piwheels. Afterwards install libopenblas0 runtime library instead: https://piwheels.org/project/numpy/ - (( $G_DISTRO < 7 )) || aDEPS+=('libxslt1-dev') # Bookworm: libxslt1-dev and gcc for lxml until wheels have been built on piwheels: https://piwheels.org/project/lxml/ + aDEPS=('libopenblas0-pthread') # libopenblas0-pthread runtime library for piwheels wheel: https://piwheels.org/project/numpy/ (( $G_HW_ARCH == 1 )) && aDEPS+=('unar') # ARMv6 does not support unrar-nonfree and Bazarr does not support unrar-free, so we need to use "unar": https://github.com/morpheus65535/bazarr/issues/2172 fi @@ -10160,8 +10159,7 @@ _EOF_ aPATH=("PATH='/mnt/dietpi_userdata/octoprint/.cargo/bin:$PATH'") # - ARMv8: gcc for psutil - # - ARMv6/7: gcc for regex: https://github.com/piwheels/packages/issues/442 - elif (( $G_HW_ARCH == 3 || ( $G_HW_ARCH < 3 && $G_DISTRO == 6 ) )) + elif (( $G_HW_ARCH == 3 )) then G_AGI gcc fi From 01a53c2d74d04f321b870a66eb45d7281c46efc7 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 14:01:31 +0200 Subject: [PATCH 162/266] v9.4 - CI | DietPi-Build: Add ROCK 4C Plus to "all" builds --- .github/workflows/dietpi-build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index d8f98dc353..0307a374b4 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -70,6 +70,7 @@ jobs: '"-m 70 -d 6 -e all", '\ '"-m 72.1 -d 6", "-m 72.1 -d 7", "-m 72.1 -d 8", '\ '"-m 72.2 -d 6", "-m 72.2 -d 7", "-m 72.2 -d 8", '\ + '"-m 72.3 -d 6", "-m 72.3 -d 7", "-m 72.3 -d 8", '\ '"-m 73 -d 6", "-m 73 -d 7", "-m 73 -d 8", '\ '"-m 74 -d 6", "-m 74 -d 7", "-m 74 -d 8", '\ '"-m 75 -a 1 -d 6", "-m 75 -a 2 -d 6", "-m 75 -a 3 -d 6", "-m 75 -a 10 -d 6", '\ From 8a404f786e88fa599e8f1f4ef08ad8cb547ccae1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 18:14:56 +0200 Subject: [PATCH 163/266] v9.4 - DietPi-Globals | Apply Armbian APT fetch failure workaround for APT updates as well (instead of installs/upgrades only) --- dietpi/func/dietpi-globals | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index ecea008fc3..314e3c3089 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -1572,6 +1572,9 @@ Press any key to continue...' # Clean cache before every update, which can corrupt and gets fully rewritten anyway G_EXEC_PRE_FUNC(){ apt-get clean; } + # Workaround for Armbian mirrors being out of sync regularly or throwing 5xx errors + [[ -f '/etc/apt/sources.list.d/dietpi-armbian.list' ]] && G_EXEC_POST_FUNC(){ [[ $exit_code != 0 ]] && grep -q '^E: Failed to fetch .*armbian' "$fp_log" && G_EXEC_RETRIES=2 && unset -f G_EXEC_POST_FUNC; } + G_EXEC_DESC='\e[0mAPT update' G_EXEC_OUTPUT=1 G_EXEC_OUTPUT_COL='\e[90m' G_EXEC apt-get -y -eany update local exit_code=$? From c791d2a5ce0364b5a7e2369db0414a9cb084563f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 18:23:36 +0200 Subject: [PATCH 164/266] v9.4 - CI | DietPi-Build: Test mmdebstrap, which should be faster, includes security and update suites automatically, and hopefully fixes current and regularly happening issues with debootstrap and Debian testing/unstable --- .build/images/dietpi-build | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index d70376fb2a..2286f66a05 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -217,7 +217,7 @@ fi # Virtual machine disk conversion [[ $VMTYPE && $VMTYPE != 'raw' ]] && apackages+=('qemu-utils') -G_AG_CHECK_INSTALL_PREREQ parted debootstrap dbus systemd-container xz-utils "${apackages[@]}" +G_AG_CHECK_INSTALL_PREREQ parted mmdebstrap dbus systemd-container xz-utils "${apackages[@]}" # Bootstrap archive keyring if missing if [[ ! -f $keyring ]] @@ -379,8 +379,8 @@ G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/lib/apt/lists G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/log packages='apt,bash-completion,bzip2,ca-certificates,cron,curl,fdisk,gnupg,htop,iputils-ping,locales,nano,p7zip,parted,procps,psmisc,sudo,systemd-sysv,tzdata,udev,unzip,wget,whiptail,' [[ $HW_MODEL == 75 ]] && packages+='iproute2' || packages+='console-setup,dropbear,ethtool,fake-hwclock,ifupdown,isc-dhcp-client,kmod,rfkill,systemd-timesyncd,usbutils' -G_EXEC_POST_FUNC(){ [[ $exit_code == 0 ]] || cat rootfs/debootstrap/debootstrap.log; } -G_EXEC_OUTPUT=1 G_EXEC debootstrap --variant=minbase --include="$packages" --arch="$parch" --keyring="$keyring" "$distro" ./rootfs "$repo" +#G_EXEC_POST_FUNC(){ [[ $exit_code == 0 ]] || cat rootfs/debootstrap/debootstrap.log; } +G_EXEC_OUTPUT=1 G_EXEC mmdebstrap --variant=minbase --include="$packages" --arch="$parch" --keyring="$keyring" "$distro" ./rootfs "$repo" G_EXEC umount rootfs/dev rootfs/run rootfs/var/cache/apt rootfs/var/lib/apt/lists rootfs/var/log ########################################## From ae7fe5201e30e4c6a7cb0cbfa7fb8ef2eacd7f5e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 18:24:56 +0200 Subject: [PATCH 165/266] v9.4 - DietPi-Installer | Fix raspberrypi-sys-mods package install from our repo --- .build/images/dietpi-installer | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 6c37f6365b..283003fc9f 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1268,7 +1268,7 @@ _EOF_ G_CONFIG_INJECT 'SKIP_INITRAMFS_GEN=' 'SKIP_INITRAMFS_GEN=yes' /etc/default/raspi-firmware G_AGI "${kernel[@]}" raspi-utils raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}" tiny-initramfs else - G_AGI raspberrypi-bootloader raspberrypi-kernel libraspberrypi0 libraspberrypi-bin ./raspberrypi-sys-mods.deb raspberrypi-archive-keyring "${a32bit[@]}" + G_AGI raspberrypi-bootloader raspberrypi-kernel libraspberrypi0 libraspberrypi-bin raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}" fi G_EXEC rm raspberrypi-sys-mods.deb From 9088c1adf4121edcfe9d8b1d81aed0e14fb1bf29 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 18:53:45 +0200 Subject: [PATCH 166/266] v9.4 - DietPi-Build | Try to allow non-empty target dir for mmdebstrap --- .build/images/dietpi-build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 2286f66a05..397930aad0 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -380,7 +380,7 @@ G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/log packages='apt,bash-completion,bzip2,ca-certificates,cron,curl,fdisk,gnupg,htop,iputils-ping,locales,nano,p7zip,parted,procps,psmisc,sudo,systemd-sysv,tzdata,udev,unzip,wget,whiptail,' [[ $HW_MODEL == 75 ]] && packages+='iproute2' || packages+='console-setup,dropbear,ethtool,fake-hwclock,ifupdown,isc-dhcp-client,kmod,rfkill,systemd-timesyncd,usbutils' #G_EXEC_POST_FUNC(){ [[ $exit_code == 0 ]] || cat rootfs/debootstrap/debootstrap.log; } -G_EXEC_OUTPUT=1 G_EXEC mmdebstrap --variant=minbase --include="$packages" --arch="$parch" --keyring="$keyring" "$distro" ./rootfs "$repo" +G_EXEC_OUTPUT=1 G_EXEC mmdebstrap --skip=check/empty --variant=minbase --include="$packages" --arch="$parch" --keyring="$keyring" "$distro" ./rootfs "$repo" G_EXEC umount rootfs/dev rootfs/run rootfs/var/cache/apt rootfs/var/lib/apt/lists rootfs/var/log ########################################## From b544a700492b1c7b528728f1f5bac8fc809dff5c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 20:22:40 +0200 Subject: [PATCH 167/266] v9.4 - DietPi-Software | NZBGet: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 3a64d1c49b..fb19a7f77c 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9872,7 +9872,7 @@ _EOF_ local reinstall=0 [[ -f '/mnt/dietpi_userdata/nzbget/nzbget.conf' ]] && reinstall=1 - local fallback_url='https://github.com/nzbgetcom/nzbget/releases/download/v22.0/nzbget-22.0-bin-linux.run' + local fallback_url='https://github.com/nzbgetcom/nzbget/releases/download/v24.0/nzbget-24.0-bin-linux.run' Download_Install "$(curl -sSfL 'https://api.github.com/repos/nzbgetcom/nzbget/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/nzbget-[^"/]*-bin-linux.run"$/{print $4}')" nzbget.run G_EXEC mkdir -p /mnt/dietpi_userdata/nzbget G_EXEC_OUTPUT=1 G_EXEC dash nzbget.run --destdir /mnt/dietpi_userdata/nzbget From f806fe8381ee296365aedc6f03850d955eabfe31 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 21:16:35 +0200 Subject: [PATCH 168/266] v9.4 - DietPi-Imager | Remove obsolete step --- .build/images/dietpi-installer | 1 - 1 file changed, 1 deletion(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 283003fc9f..c2656159b9 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1270,7 +1270,6 @@ _EOF_ else G_AGI raspberrypi-bootloader raspberrypi-kernel libraspberrypi0 libraspberrypi-bin raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}" fi - G_EXEC rm raspberrypi-sys-mods.deb # https://github.com/RPi-Distro/raspberrypi-sys-mods/pull/60 [[ -f '/etc/apt/trusted.gpg.d/microsoft.gpg' ]] && G_EXEC rm /etc/apt/trusted.gpg.d/microsoft.gpg From 18ca04a513a4d637064b32e18e8041b7afa323a2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 22:28:51 +0200 Subject: [PATCH 169/266] v9.4 - DietPi-Build | Workaround for failing build on ARMv6/7 Trixie systems due to conflicting libssl3 and libssl3t64 dependencies --- .build/images/dietpi-build | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 397930aad0..2164d2ebec 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -379,6 +379,8 @@ G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/lib/apt/lists G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/log packages='apt,bash-completion,bzip2,ca-certificates,cron,curl,fdisk,gnupg,htop,iputils-ping,locales,nano,p7zip,parted,procps,psmisc,sudo,systemd-sysv,tzdata,udev,unzip,wget,whiptail,' [[ $HW_MODEL == 75 ]] && packages+='iproute2' || packages+='console-setup,dropbear,ethtool,fake-hwclock,ifupdown,isc-dhcp-client,kmod,rfkill,systemd-timesyncd,usbutils' +# Workaround for failing build on ARMv6/7 Trixie systems due to conflicting libssl3 and libssl3t64 dependencies +(( $HW_ARCH < 3 && $DISTRO > 7 )) && packages+=',libssl3t64' #G_EXEC_POST_FUNC(){ [[ $exit_code == 0 ]] || cat rootfs/debootstrap/debootstrap.log; } G_EXEC_OUTPUT=1 G_EXEC mmdebstrap --skip=check/empty --variant=minbase --include="$packages" --arch="$parch" --keyring="$keyring" "$distro" ./rootfs "$repo" G_EXEC umount rootfs/dev rootfs/run rootfs/var/cache/apt rootfs/var/lib/apt/lists rootfs/var/log From 90d6c6fd5e5ef0c1f1c0560a529227a6686573a3 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 23:08:43 +0200 Subject: [PATCH 170/266] v9.4 - DietPi-Installer | Install firmware package from our server prior to its APT install, to avoid a doubled install/upgrade step --- .build/images/dietpi-installer | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index c2656159b9..ab610487b8 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1137,6 +1137,12 @@ blacklist rockchip_vdec _EOF_ fi # Install initramfs-tools first to have an initramfs generated on kernel install, and configure it to use zstd if supported for better compression and faster decompression + if (( $dietpi_kernel )) + then + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' + G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb + G_EXEC rm package.deb + fi [[ $kernel == 'rockchip64' || $kernel == 'rk35xx' || $kernel == 'meson64' || $kernel == 'sunxi64' || $kernel == 'sunxi' || $kernel == 'rockchip' ]] && zstd=('zstd') G_AGI initramfs-tools u-boot-tools armbian-firmware "${zstd[@]}" [[ ${zstd[0]} ]] && G_CONFIG_INJECT 'COMPRESS=' 'COMPRESS=zstd' /etc/initramfs-tools/initramfs.conf @@ -1145,9 +1151,8 @@ _EOF_ then G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb "https://dietpi.com/downloads/binaries/linux-image-$branch-$kernel.deb" G_EXEC_OUTPUT=1 G_EXEC curl -fo package2.deb "https://dietpi.com/downloads/binaries/linux-dtb-$branch-$kernel.deb" - G_EXEC_OUTPUT=1 G_EXEC curl -fo package3.deb 'https://dietpi.com/downloads/binaries/armbian-firmware.deb' - G_EXEC_OUTPUT=1 G_EXEC dpkg -i package[1-3].deb - G_EXEC rm package[1-3].deb + G_EXEC_OUTPUT=1 G_EXEC dpkg -i package[12].deb + G_EXEC rm package[12].deb fi # Download and pre-install U-Boot hosted on dietpi.com where the Armbian APT repo provides a too old version or is not available if (( $dietpi_uboot )) From 16a75a47bee94ba5604ae74fa405ffb7c4181ef3 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 25 Apr 2024 23:46:30 +0200 Subject: [PATCH 171/266] v9.4 - DietPi-Imager | dietpiEnv.txt cannot exist on the rootfs, if it is not the bootfs --- .build/images/dietpi-imager | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.build/images/dietpi-imager b/.build/images/dietpi-imager index fdc61988b5..176c6021d4 100755 --- a/.build/images/dietpi-imager +++ b/.build/images/dietpi-imager @@ -529,7 +529,7 @@ G_EXEC mount "${FP_ROOT_DEV::-1}1" "$fat_mountpoint" G_EXEC mount "$FP_ROOT_DEV" "$root_mountpoint" G_DIETPI-NOTIFY 2 'Copying dietpi.txt and other config files to the DIETPISETUP partition' - for f in 'dietpi.txt' 'dietpi-wifi.txt' 'dietpiEnv.txt' 'unattended_pivpn.conf' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' + for f in 'dietpi.txt' 'dietpi-wifi.txt' 'unattended_pivpn.conf' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' do [[ -f $root_mountpoint/boot/$f ]] && G_EXEC cp "$root_mountpoint/boot/$f" "$fat_mountpoint/" done From 3710fdd56a3d456dd8980f9d56535db2fbe30c7b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 26 Apr 2024 13:44:04 +0200 Subject: [PATCH 172/266] v9.4 - DietPi-Build | Raise some image sizes required for Trixie and temporarily skip Trixie AlloGUI builds: The netdata package is currently not available (only on Raspbian, not Debian) and systemd-logind fails to start within the container as of a new change/bug, to investigate. --- .build/images/dietpi-build | 23 ++++++++++++----------- .build/images/dietpi-imager | 4 ++-- 2 files changed, 14 insertions(+), 13 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 2164d2ebec..4bba54f1ec 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -83,9 +83,9 @@ case $HW_MODEL in 5) iname='RPi5' HW_ARCH=3 boot_size=128 root_size=895;; 10) iname='OdroidC1' HW_ARCH=2 partition_start=4 boot_size=128 root_size=700 boot_fstype='fat16';; 11) iname='OdroidXU4' HW_ARCH=2 partition_start=4 root_size=764;; - 12) iname='OdroidC2' HW_ARCH=3 partition_start=4 root_size=1020;; - 15) iname='OdroidN2' HW_ARCH=3 partition_start=4 root_size=1020;; - 16) iname='OdroidC4' HW_ARCH=3 partition_start=4 root_size=1020;; + 12) iname='OdroidC2' HW_ARCH=3 partition_start=4 root_size=1148;; + 15) iname='OdroidN2' HW_ARCH=3 partition_start=4 root_size=1148;; + 16) iname='OdroidC4' HW_ARCH=3 partition_start=4 root_size=1148;; 20) iname='VM' HW_ARCH=${HW_ARCH:-10} VMTYPE=${VMTYPE:-raw};; 21) iname='NativePC-BIOS' HW_ARCH=10 root_size=1663;; 40) iname='PINEA64' HW_ARCH=3 partition_start=4 root_size=892;; @@ -100,7 +100,7 @@ case $HW_MODEL in '49.2') iname='Quartz64B' HW_ARCH=3 partition_start=16 root_size=752;; '49.3') iname='SOQuartz' HW_ARCH=3 partition_start=16 root_size=752;; 52) iname='ASUSTB' HW_ARCH=2 partition_start=4 root_size=764;; - 54) iname='NanoPiK2' HW_ARCH=3 partition_start=4 root_size=1020;; + 54) iname='NanoPiK2' HW_ARCH=3 partition_start=4 root_size=1148;; 55) iname='NanoPiR2S' HW_ARCH=3 partition_start=16 root_size=1008;; 56) iname='NanoPiNEO3' HW_ARCH=3 partition_start=16 root_size=1008;; 57) iname='NanoPiNEOPlus2' HW_ARCH=3 partition_start=4 root_size=892;; @@ -112,10 +112,10 @@ case $HW_MODEL in '62.2') iname='NanoPiFire3' HW_ARCH=3 partition_start=4 root_size=700;; 63) iname='NanoPiM1' HW_ARCH=2 partition_start=4 root_size=764;; 64) iname='NanoPiNEOAir' HW_ARCH=2 partition_start=4 root_size=764;; - '65.1') iname='NanoPiNEO2' HW_ARCH=3 partition_start=4 root_size=892;; - '65.2') iname='NanoPiNEO2Black' HW_ARCH=3 partition_start=4 root_size=892;; + '65.1') iname='NanoPiNEO2' HW_ARCH=3 partition_start=4 root_size=1020;; + '65.2') iname='NanoPiNEO2Black' HW_ARCH=3 partition_start=4 root_size=1020;; 66) iname='NanoPiM1Plus' HW_ARCH=2 partition_start=4 root_size=764;; - 67) iname='NanoPiK1Plus' HW_ARCH=3 partition_start=4 root_size=892;; + 67) iname='NanoPiK1Plus' HW_ARCH=3 partition_start=4 root_size=1020;; '68.1') iname='NanoPiM4' HW_ARCH=3 partition_start=16 root_size=1008;; '68.2') iname='NanoPCT4' HW_ARCH=3 partition_start=16 root_size=1008;; '68.3') iname='NanoPiNEO4' HW_ARCH=3 partition_start=16 root_size=1008;; @@ -124,11 +124,11 @@ case $HW_MODEL in '72.2') iname='ROCK4SE' HW_ARCH=3 partition_start=16 root_size=1008;; '72.3') iname='ROCK4CPlus' HW_ARCH=3 partition_start=16 root_size=1008;; 73) iname='ROCKPiS' HW_ARCH=3 partition_start=16 root_size=1008;; - 74) iname='RadxaZero' HW_ARCH=3 partition_start=4 root_size=1020;; + 74) iname='RadxaZero' HW_ARCH=3 partition_start=4 root_size=1148;; 75) iname='Container' HW_ARCH=${HW_ARCH:-10} root_size=575;; '76.1') iname='NanoPiR5S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; '76.2') iname='NanoPiR5C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; - 77) iname='ROCK3A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + 77) iname='ROCK3A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; 78) iname='ROCK5B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; '79.1') iname='NanoPiR6S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; '79.2') iname='NanoPiR6C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; @@ -141,7 +141,7 @@ case $HW_MODEL in 84) iname='Star64' HW_ARCH=11 root_size=639;; 85) iname='ROCK5A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; 86) iname='ASUSTB2' HW_ARCH=3 partition_start=16 root_size=1008;; - 87) iname='OrangePi3B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + 87) iname='OrangePi3B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; *) G_DIETPI-NOTIFY 1 "Invalid hardware model \"$HW_MODEL\" passed, aborting..."; exit 1;; esac @@ -510,7 +510,8 @@ then fi # AlloGUI edition: Pre-install Allo GUI with all managed audiophile software -if [[ $EDITION == 'AlloGUI' || ( $EDITION == 'all' && $HW_MODEL =~ ^(0|70)$ ) ]] +# - Temporarily skip Trixie AlloGUI builds: The netdata package is currently not available (only on Raspbian, not Debian) and systemd-logind fails to start within the container as of a new change/bug, to investigate. +if [[ $EDITION == 'AlloGUI' || ( $EDITION == 'all' && $HW_MODEL =~ ^(0|70)$ && $DISTRO != 8 ) ]] then G_EXEC mv "$OUTPUT_IMG_NAME.img" "${OUTPUT_IMG_NAME%_Amiberry}_AlloGUI.img" OUTPUT_IMG_NAME="${OUTPUT_IMG_NAME%_Amiberry}_AlloGUI" diff --git a/.build/images/dietpi-imager b/.build/images/dietpi-imager index 176c6021d4..832e3d6e46 100755 --- a/.build/images/dietpi-imager +++ b/.build/images/dietpi-imager @@ -61,8 +61,8 @@ [[ $SKIP_FIRSTBOOT_RESIZE == 1 ]] || SKIP_FIRSTBOOT_RESIZE=0 [[ $SHRINK_ONLY == 1 ]] || SHRINK_ONLY=0 [[ $SKIP_ARCHIVE == 1 ]] || SKIP_ARCHIVE=0 - ADD_DOS_PART=0 - CONFIGS_TO_BOOT=0 + ADD_DOS_PART=0 # trailing FAT partition for first boot config files, automatically imported and partition removed on first boot + CONFIGS_TO_BOOT=0 # for new RPi kernel/firmware stack where a boot FAT partition exists, but is mounted to /boot/firmware instead of /boot SIGN_PASS= while (( $# )) do From 06dc9a31ccfb46a7797b8b5af4eeaaeb6ab87c6c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 26 Apr 2024 14:00:32 +0200 Subject: [PATCH 173/266] v9.4 - DietPi-Imager | Use multi-threaded xz compression. Other than 7zip, xz uses a single thread only by default --- .build/images/dietpi-imager | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.build/images/dietpi-imager b/.build/images/dietpi-imager index 832e3d6e46..10ed47c673 100755 --- a/.build/images/dietpi-imager +++ b/.build/images/dietpi-imager @@ -746,10 +746,10 @@ _EOF_ # Generate xz archive # NB: LZMA2 ultra compression requires much memory per thread. 1 GiB is not sufficient for >2 threads, hence use "-T2" to limit used CPU threads to "2" on 1 GiB devices with more than two cores. - local limit_threads=() - (( $(free -m | mawk '/Mem:/{print $2}') < 1750 && $(nproc) > 2 )) && limit_threads=('-T2') + local threads=$(nproc) + (( $(free -m | mawk '/Mem:/{print $2}') < 1750 && $threads > 2 )) && threads=2 [[ -f $OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz ]] && G_EXEC rm "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz" - G_EXEC_DESC='Creating final xz archive' G_EXEC xz -9e -k "${limit_threads[@]}" "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" + G_EXEC_DESC='Creating final xz archive' G_EXEC xz -9e -k "$threads" "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz' > '$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz.sha256'" local signature=() sig_text='' [[ $SIGN_PASS ]] && { G_DIETPI-NOTIFY 2 'Signing archive ...'; gpg --batch --pinentry-mode loopback --passphrase "$SIGN_PASS" -b --armor "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz" || exit 1; signature=("$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz.asc") sig_text="\nSignature: $PWD/${signature[*]}"; } From 60600bdae76ee06d8f64e0eeb3d68bd35dacdd78 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 26 Apr 2024 14:04:32 +0200 Subject: [PATCH 174/266] v9.4 - DietPi-Imager | Fix xz threads option and use special value "0" to automate the number of threads and assure multi-theaded mode (for decompression) even in case of a single CPU core/thread. --- .build/images/dietpi-imager | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.build/images/dietpi-imager b/.build/images/dietpi-imager index 10ed47c673..e1d975a6e4 100755 --- a/.build/images/dietpi-imager +++ b/.build/images/dietpi-imager @@ -746,10 +746,10 @@ _EOF_ # Generate xz archive # NB: LZMA2 ultra compression requires much memory per thread. 1 GiB is not sufficient for >2 threads, hence use "-T2" to limit used CPU threads to "2" on 1 GiB devices with more than two cores. - local threads=$(nproc) - (( $(free -m | mawk '/Mem:/{print $2}') < 1750 && $threads > 2 )) && threads=2 + local threads=0 + (( $(free -m | mawk '/Mem:/{print $2}') < 1750 && $(nproc) > 2 )) && threads=2 [[ -f $OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz ]] && G_EXEC rm "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz" - G_EXEC_DESC='Creating final xz archive' G_EXEC xz -9e -k "$threads" "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" + G_EXEC_DESC='Creating final xz archive' G_EXEC xz -9e -k "-T$threads" "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz' > '$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz.sha256'" local signature=() sig_text='' [[ $SIGN_PASS ]] && { G_DIETPI-NOTIFY 2 'Signing archive ...'; gpg --batch --pinentry-mode loopback --passphrase "$SIGN_PASS" -b --armor "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz" || exit 1; signature=("$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz.asc") sig_text="\nSignature: $PWD/${signature[*]}"; } From 13d20c75aeec6669a57ee0da25ca5e1479e601ab Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 27 Apr 2024 21:26:08 +0200 Subject: [PATCH 175/266] v9.4 - DietPi-Installer | When flashing U-Boot via Armbian's script, do not mute progress and error messages --- .build/images/dietpi-installer | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index ab610487b8..eb7ca51e26 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1181,6 +1181,8 @@ _EOF_ # Flash U-Boot # shellcheck disable=SC1091 . /usr/lib/u-boot/platform_install.sh + # - Do not mute progress and error messages + eval "$(declare -f write_uboot_platform | sed -e 's| > /dev/null 2>&1||g' -e 's|status=none|status=progress|g')" # shellcheck disable=SC2154 write_uboot_platform "$DIR" "$BOOT_DEVICE" From 80536116081d329b48005b1f9633b6e64c42658b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 27 Apr 2024 21:39:34 +0200 Subject: [PATCH 176/266] v9.4 (#7046) - DietPi-Imager | Skip moving backup partition table before touching the image. parted/sfdisk may throw warnings, but the step can fail if the last partition reaches the end of the image, e.g. if the file was cut right after the last partition, ignoring the backup table. Additionally, obtain the size needed for the GPT backup correctly by the first usabe LBA/sector, instead of using the 34 sectors default GPT size. fdisk/sfdisk use 2048 by default, while parted defaults to the actual 34 sectors the GPT truly uses. From b215c0149b4add4e8e20e03d326a8b197d2ee3cf Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 28 Apr 2024 15:59:04 +0200 Subject: [PATCH 177/266] v9.4 - DietPi-Build | Raise some image sizes for Trixie - DietPi-Software | Update fallback URLs --- .build/images/dietpi-build | 8 ++++---- dietpi/dietpi-software | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 4bba54f1ec..5d9992374c 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -88,11 +88,11 @@ case $HW_MODEL in 16) iname='OdroidC4' HW_ARCH=3 partition_start=4 root_size=1148;; 20) iname='VM' HW_ARCH=${HW_ARCH:-10} VMTYPE=${VMTYPE:-raw};; 21) iname='NativePC-BIOS' HW_ARCH=10 root_size=1663;; - 40) iname='PINEA64' HW_ARCH=3 partition_start=4 root_size=892;; + 40) iname='PINEA64' HW_ARCH=3 partition_start=4 root_size=1020;; 42) iname='ROCKPro64' HW_ARCH=3 partition_start=16 root_size=1008;; 43) iname='ROCK64' HW_ARCH=3 partition_start=16 root_size=1008;; - 44) iname='Pinebook' HW_ARCH=3 partition_start=4 root_size=892;; - 45) iname='PINEH64' HW_ARCH=3 partition_start=4 root_size=892;; + 44) iname='Pinebook' HW_ARCH=3 partition_start=4 root_size=1020;; + 45) iname='PINEH64' HW_ARCH=3 partition_start=4 root_size=1020;; 46) iname='PinebookPro' HW_ARCH=3 partition_start=16 root_size=1008;; 47) iname='NanoPiR4S' HW_ARCH=3 partition_start=16 root_size=1008;; 48) iname='NanoPiR1' HW_ARCH=2 partition_start=4 root_size=764;; @@ -133,7 +133,7 @@ case $HW_MODEL in '79.1') iname='NanoPiR6S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; '79.2') iname='NanoPiR6C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; '79.3') iname='NanoPCT6' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; - 80) iname='OrangePi5' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; + 80) iname='OrangePi5' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; 81) iname='VisionFive2' HW_ARCH=11 root_size=639;; 82) iname='OrangePi5Plus' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; '83.1') iname='OrangePiZero3' HW_ARCH=3 partition_start=4 root_size=1148;; diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index fb19a7f77c..66fbfd30e2 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6206,7 +6206,7 @@ _EOF_ *) local arch='amd64';; esac - local fallback_url="https://github.com/navidrome/navidrome/releases/download/v0.51.1/navidrome_0.51.1_linux_$arch.tar.gz" + local fallback_url="https://github.com/navidrome/navidrome/releases/download/v0.52.0/navidrome_0.52.0_linux_$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/navidrome/navidrome/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/navidrome_[0-9.]*_linux_$arch\.tar\.gz\"$/{print \$4}")" /opt/navidrome # Data dir @@ -10027,7 +10027,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.24.2510/Readarr.develop.0.3.24.2510.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.25.2515/Readarr.develop.0.3.25.2515.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Readarr/Readarr/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}" | head -1)" G_EXEC mv Readarr /opt/readarr fi From 939ec3d40c5e0253221bebf6a4535d6e404ee1ab Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 28 Apr 2024 16:33:31 +0200 Subject: [PATCH 178/266] v9.4 - CI | Armbian: Setup Python to make available /usr/bin/python, requried for legacy s5p6818 build. Use our fork with some patches/commits by default. Rebase any other fork/branch onto ours and onto upstream. --- .github/workflows/armbian.yml | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index e0d848ab41..a998f57432 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -34,15 +34,30 @@ jobs: name: "${{ github.event.inputs.asset }} - ${{ github.event.inputs.branch }} - ${{ github.event.inputs.board }}" runs-on: ubuntu-22.04 steps: + # https://github.com/actions/setup-python/tags + - uses: actions/setup-python@v5 + with: + python-version: '3.x' + check-latest: true - name: Clone Armbian repo run: | owner='${{ github.event.inputs.gitowner }}' - [ "$owner" ] || owner='armbian' + [ "$owner" ] || owner='MichaIng' branch='${{ github.event.inputs.gitbranch }}' - [ "$branch" ] || branch='main' + [ "$branch" ] || branch='dietpi' git clone -b "$branch" --depth=1 "https://github.com/$owner/build" [ '${{ github.event.inputs.rebase }}' == 'false' ] && exit 0 || : cd build + if [ "$owner" != 'MichaIng' ] + then + git remote add dietpi https://github.com/MichaIng/build + git fetch dietpi dietpi + git rebase dietpi/dietpi + elif [ "$branch" != 'dietpi' ] + then + git fetch origin dietpi + git rebase dietpi + fi if [ "$owner" != 'armbian' ] then git remote add upstream https://github.com/armbian/build From 7f776867a4990139d7f400ebc0385852517f63a4 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 28 Apr 2024 17:08:02 +0200 Subject: [PATCH 179/266] v9.4 - CI | Armbian: Fix rebasing if branch contains more than 1 new commit. In this case, with only the last commit in history, any rebase conflicts due to unexpected diffs from previous commits. --- .github/workflows/armbian.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index a998f57432..c8a7ed2130 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -45,7 +45,7 @@ jobs: [ "$owner" ] || owner='MichaIng' branch='${{ github.event.inputs.gitbranch }}' [ "$branch" ] || branch='dietpi' - git clone -b "$branch" --depth=1 "https://github.com/$owner/build" + git clone -b "$branch" "https://github.com/$owner/build" [ '${{ github.event.inputs.rebase }}' == 'false' ] && exit 0 || : cd build if [ "$owner" != 'MichaIng' ] From 4279e4ac14a2e780941fcb91cef9eadac575d1bc Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 28 Apr 2024 17:14:36 +0200 Subject: [PATCH 180/266] v9.4 - CI | Armbian: Further attempt to fix missing /usr/bin/python --- .github/workflows/armbian.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index c8a7ed2130..cc74ed1381 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -71,6 +71,7 @@ jobs: - name: Build asset run: | cd build + which python || sudo ln -sv python3 /usr/bin/python ./compile.sh '${{ github.event.inputs.asset }}' BRANCH='${{ github.event.inputs.branch }}' BOARD='${{ github.event.inputs.board }}' - name: Upload run: | From 019b2e81902bbfec7d67bf16f178cef924f8db2f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 28 Apr 2024 17:20:23 +0200 Subject: [PATCH 181/266] v9.4 - CI | Armbian: Final fix for missing /usr/bin/python --- .github/workflows/armbian.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index cc74ed1381..5b68f9f816 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -71,7 +71,8 @@ jobs: - name: Build asset run: | cd build - which python || sudo ln -sv python3 /usr/bin/python + # Add python executable for legacy s5p6818 builds + sudo ln -sv python3 /usr/bin/python ./compile.sh '${{ github.event.inputs.asset }}' BRANCH='${{ github.event.inputs.branch }}' BOARD='${{ github.event.inputs.board }}' - name: Upload run: | From 93844ba625e8965f121c42564a05559215e540da Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 28 Apr 2024 23:15:38 +0200 Subject: [PATCH 182/266] v9.4 - DietPi-Software | Enhance cancel button text for Pi-hole/AdGuard home pre-install dialogues, to show both "Skip" instead of "Cancel". --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 66fbfd30e2..820a203c78 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -15009,13 +15009,13 @@ We allow it to take up to 30 minutes, it's process can be followed, please be pa # Add option to use Unbound as upstream DNS server if (( ${aSOFTWARE_INSTALL_STATE[182]} == 0 )) then - G_WHIP_YESNO 'Would you like to use Unbound, a tiny recursive DNS server hosted on your device, as your upstream DNS server? + G_WHIP_BUTTON_CANCEL_TEXT='Skip' G_WHIP_YESNO 'Would you like to use Unbound, a tiny recursive DNS server hosted on your device, as your upstream DNS server? \nThis will increase privacy, because you will not be sending data to Google etc. \nHowever, the downside is that some websites may load slower the first time you visit them.' && aSOFTWARE_INSTALL_STATE[182]=1 fi # Prompt for static IP - if G_WHIP_YESNO 'A static IP address is essential for a DNS server installations. DietPi-Config can be used to quickly setup your static IP address. + if G_WHIP_BUTTON_CANCEL_TEXT='Skip' G_WHIP_YESNO 'A static IP address is essential for a DNS server installation. DietPi-Config can be used to quickly setup your static IP address. \nIf you have already setup your static IP, please ignore this message.\n\nWould you like to setup your static IP address now?' then G_WHIP_MSG 'DietPi-Config will now be launched. Simply select your Ethernet or Wifi connection from the menu to access the IP address settings. From 7cdb014d9a68803be100328dafea111c551f546c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 28 Apr 2024 23:28:15 +0200 Subject: [PATCH 183/266] v9.4 (#7050) - CI | Armbian: Fix rebase syntax and remove obsolete workaround attempts for failing s5p6818 buids: This is now fixed via Armbian patch. --- .github/workflows/armbian.yml | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 5b68f9f816..088be9a818 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -34,11 +34,6 @@ jobs: name: "${{ github.event.inputs.asset }} - ${{ github.event.inputs.branch }} - ${{ github.event.inputs.board }}" runs-on: ubuntu-22.04 steps: - # https://github.com/actions/setup-python/tags - - uses: actions/setup-python@v5 - with: - python-version: '3.x' - check-latest: true - name: Clone Armbian repo run: | owner='${{ github.event.inputs.gitowner }}' @@ -56,7 +51,7 @@ jobs: elif [ "$branch" != 'dietpi' ] then git fetch origin dietpi - git rebase dietpi + git rebase origin/dietpi fi if [ "$owner" != 'armbian' ] then @@ -66,13 +61,11 @@ jobs: elif [ "$branch" != 'main' ] then git fetch origin main - git rebase main + git rebase origin/main fi - name: Build asset run: | cd build - # Add python executable for legacy s5p6818 builds - sudo ln -sv python3 /usr/bin/python ./compile.sh '${{ github.event.inputs.asset }}' BRANCH='${{ github.event.inputs.branch }}' BOARD='${{ github.event.inputs.board }}' - name: Upload run: | From 406ddb3f78ceb3ba18c02744120c77d4587380ec Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 29 Apr 2024 00:25:59 +0200 Subject: [PATCH 184/266] v9.4 - DietPi-Build | Remove non-functional Trixie armhf workaround for time_t transition: It does not work, since there are still/again hard dependencies on both versions of some packages. We need to wait until all this has settled. --- .build/images/dietpi-build | 2 -- 1 file changed, 2 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 5d9992374c..f6b8c072e7 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -379,8 +379,6 @@ G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/lib/apt/lists G_EXEC mount -o X-mount.mkdir -t tmpfs tmpfs rootfs/var/log packages='apt,bash-completion,bzip2,ca-certificates,cron,curl,fdisk,gnupg,htop,iputils-ping,locales,nano,p7zip,parted,procps,psmisc,sudo,systemd-sysv,tzdata,udev,unzip,wget,whiptail,' [[ $HW_MODEL == 75 ]] && packages+='iproute2' || packages+='console-setup,dropbear,ethtool,fake-hwclock,ifupdown,isc-dhcp-client,kmod,rfkill,systemd-timesyncd,usbutils' -# Workaround for failing build on ARMv6/7 Trixie systems due to conflicting libssl3 and libssl3t64 dependencies -(( $HW_ARCH < 3 && $DISTRO > 7 )) && packages+=',libssl3t64' #G_EXEC_POST_FUNC(){ [[ $exit_code == 0 ]] || cat rootfs/debootstrap/debootstrap.log; } G_EXEC_OUTPUT=1 G_EXEC mmdebstrap --skip=check/empty --variant=minbase --include="$packages" --arch="$parch" --keyring="$keyring" "$distro" ./rootfs "$repo" G_EXEC umount rootfs/dev rootfs/run rootfs/var/cache/apt rootfs/var/lib/apt/lists rootfs/var/log From 78d27c070018fd76fc7a7600e8cfa581978e5497 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 1 May 2024 00:08:20 +0200 Subject: [PATCH 185/266] v9.4 - DietPi-Installer | ROCK 4C Plus: Hardcode device tree since even the variant-specific U-Boot build does not pick the correct one --- .build/images/dietpi-installer | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index eb7ca51e26..3f26c90755 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -674,7 +674,13 @@ setenv rootuuid "true"' /boot/boot.cmd 46) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3399-pinebook-pro.dtb' /boot/dietpiEnv.txt;; 55) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3328-nanopi-r2-rev00.dtb' /boot/dietpiEnv.txt;; # Not necessarily needed as rk3328-nanopi-r2s.dtb is automatically chosen, but provides more consistent /sys/class/leds/{wan,lan}_led interface and blinking instead of steady lid power LED 56) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3328-nanopi-neo3-rev02.dtb' /boot/dietpiEnv.txt;; # Loads rk3328-nanopi-r2s.dtb by default - 72) (( $HW_VARIANT == 2 )) && G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3399-rock-4se.dtb' /boot/dietpiEnv.txt;; + 72) + case $HW_VARIANT in + 2) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3399-rock-4se.dtb' /boot/dietpiEnv.txt;; + 3) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3399-rock-4c-plus.dtb' /boot/dietpiEnv.txt;; + *) :;; + esac + ;; 73) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3308-rock-pi-s.dtb' /boot/dietpiEnv.txt;; # U-Boot does not pass any ${fdtfile} 77) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3568-rock-3a.dtb' /boot/dietpiEnv.txt;; 78) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3588-rock-5b.dtb' /boot/dietpiEnv.txt;; From 15ab92ec34ac71f4c672033694005f2a86fbd1ee Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 1 May 2024 19:05:16 +0200 Subject: [PATCH 186/266] v9.4 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 820a203c78..b627fe7576 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11129,7 +11129,7 @@ _EOF_ # v3 drops PHP 7.4 support: https://github.com/TasmoAdmin/TasmoAdmin/releases/tag/v3.0.0 if (( $G_DISTRO > 6 )) then - local fallback_url='https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v4.0.2/tasmoadmin_v4.0.2.tar.gz' + local fallback_url='https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v4.1.0/tasmoadmin_v4.1.0.tar.gz' Download_Install "$(curl -sSfL 'https://api.github.com/repos/TasmoAdmin/TasmoAdmin/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/tasmoadmin_v[^"\/]*\.tar\.gz"$/{print $4}')" else Download_Install 'https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v2.4.2/tasmoadmin_v2.4.2.tar.gz' @@ -11707,7 +11707,7 @@ _EOF_ *) local arch='amd64';; esac - local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.28.0/linux-$arch-filebrowser.tar.gz" + local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.29.0/linux-$arch-filebrowser.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/filebrowser/filebrowser/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/linux-$arch-filebrowser\.tar\.gz\"$/{print \$4}")" ./filebrowser/ # Reinstall From 9f55baebb3834beb9c9a742a72ca50a7b2a2a7e5 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 1 May 2024 22:12:40 +0200 Subject: [PATCH 187/266] v9.4 - DietPi-VPN | Resolved an issue where installing the IPVanish config failed, due to a changed URL. Many thanks to @DreamPhreak and @Michael-Robson for reporting this issue: https://github.com/MichaIng/DietPi/issues/7043 --- CHANGELOG.txt | 1 + dietpi/dietpi-vpn | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 1ded7a0554..ad3a8af1bb 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -11,6 +11,7 @@ Enhancements: - DietPi-Software | Snapcast: 64-bit ARM and Debian Bookworm + Trixie will have the now available packages from Snapcast installed, instead of those from the Debian repository. Bug fixes: +- DietPi-VPN | Resolved an issue where installing the IPVanish config failed, due to a changed URL. Many thanks to @DreamPhreak and @Michael-Robson for reporting this issue: https://github.com/MichaIng/DietPi/issues/7043 - DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. - DietPi-Software | OctoPrint: Resolved an issue where the installation failed on RISC-V and ARMv6/7 Bullseye systems, due to changed dependencies. diff --git a/dietpi/dietpi-vpn b/dietpi/dietpi-vpn index 9c052ca47a..094d70f82d 100755 --- a/dietpi/dietpi-vpn +++ b/dietpi/dietpi-vpn @@ -124,7 +124,7 @@ Available commands: then [[ $1 != '-f' && -d $FP_IPVANISH ]] && return 0 [[ $1 != '-f' ]] || G_WHIP_YESNO 'This will remove all IPVanish server files and perform a fresh download of IPVanish server configurations. Once completed, you will need to reselect a IPVanish server from the new list.\n\nDo you want to continue?' || return 0 - G_EXEC curl -sSfLO 'https://www.ipvanish.com/software/configs/configs.zip' + G_EXEC curl -sSfLO 'https://configs.ipvanish.com/configs/configs.zip' VPN_SERVER= [[ -d $FP_IPVANISH ]] && G_EXEC_DESC='Removing old IPVanish server configs' G_EXEC rm -R "$FP_IPVANISH" G_EXEC mkdir -p "$FP_IPVANISH" From 7b6a556127b66aa3bcace7696b7e69f621ad7ccd Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 1 May 2024 22:23:28 +0200 Subject: [PATCH 188/266] v9.4 - DietPi-VPN | IPVanish: As well remove "keysize" option from config on Bookworm (and above), which has been deprecated and is invalid sine Bookworm. --- CHANGELOG.txt | 2 +- dietpi/dietpi-vpn | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index ad3a8af1bb..f96db459b2 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -11,7 +11,7 @@ Enhancements: - DietPi-Software | Snapcast: 64-bit ARM and Debian Bookworm + Trixie will have the now available packages from Snapcast installed, instead of those from the Debian repository. Bug fixes: -- DietPi-VPN | Resolved an issue where installing the IPVanish config failed, due to a changed URL. Many thanks to @DreamPhreak and @Michael-Robson for reporting this issue: https://github.com/MichaIng/DietPi/issues/7043 +- DietPi-VPN | Resolved an issue where installing the IPVanish config failed, due to a changed URL, and startup failed on Bookworm systems since their configs contain a deprecated option. Many thanks to @DreamPhreak and @Michael-Robson for reporting this issue: https://github.com/MichaIng/DietPi/issues/7043 - DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. - DietPi-Software | OctoPrint: Resolved an issue where the installation failed on RISC-V and ARMv6/7 Bullseye systems, due to changed dependencies. diff --git a/dietpi/dietpi-vpn b/dietpi/dietpi-vpn index 094d70f82d..38cc32967d 100755 --- a/dietpi/dietpi-vpn +++ b/dietpi/dietpi-vpn @@ -233,6 +233,8 @@ _EOF_ # Set protocol and port: UDP port 443 is default, but TCP 1194 and UDP 1194 are supported as well. G_CONFIG_INJECT 'proto[[:blank:]]' "proto $PROTOCOL" "$FP_CLIENT_OVPN" G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*remote[[:blank:]]/s/[[:blank:]][0-9][0-9]*$/ 1194/' "$FP_CLIENT_OVPN" + # Bookworm: Remove "keysize" option, which has been removed with OpenVPN 2.6 + (( $G_DISTRO > 6 )) && G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*keysize[[:blank:]]/d' "$FP_CLIENT_OVPN" elif [[ $VPN_PROVIDER == 'PIA' ]] then From 3dedf4009970d4be2e19373b700ccf0ccc3be059 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 2 May 2024 14:16:13 +0200 Subject: [PATCH 189/266] v9.4 (#7053) - CI | Armbian: Set Git user and email to repo owner name and email --- .github/workflows/armbian.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 088be9a818..329064ee06 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -43,6 +43,8 @@ jobs: git clone -b "$branch" "https://github.com/$owner/build" [ '${{ github.event.inputs.rebase }}' == 'false' ] && exit 0 || : cd build + git config user.name "$GITHUB_REPOSITORY_OWNER" + git config user.email '${{ github.repository.owner.email }}' if [ "$owner" != 'MichaIng' ] then git remote add dietpi https://github.com/MichaIng/build From 0a3a252768b219bf75dabd0d164bdb8b8f6e15f2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 2 May 2024 22:44:25 +0200 Subject: [PATCH 190/266] v9.4 (#7042) - Orange Pi 3 LTS/Radxa ZERO 3 | Add support --- .build/images/dietpi-build | 2 ++ .build/images/dietpi-installer | 19 ++++++++++++------- .github/workflows/dietpi-build.yml | 4 +++- .meta/dietpi-survey_report | 2 ++ CHANGELOG.txt | 2 ++ dietpi/func/dietpi-obtain_hw_model | 12 +++++++++++- dietpi/func/dietpi-set_hardware | 2 +- dietpi/func/dietpi-set_software | 1 + 8 files changed, 34 insertions(+), 10 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index f6b8c072e7..a1465f21d7 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -142,6 +142,8 @@ case $HW_MODEL in 85) iname='ROCK5A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; 86) iname='ASUSTB2' HW_ARCH=3 partition_start=16 root_size=1008;; 87) iname='OrangePi3B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; + 89) iname='OrangePi3LTS' HW_ARCH=3 partition_start=4 root_size=892;; + 90) iname='RadxaZERO3' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; *) G_DIETPI-NOTIFY 1 "Invalid hardware model \"$HW_MODEL\" passed, aborting..."; exit 1;; esac diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 3f26c90755..3f7becfcee 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -415,10 +415,12 @@ _EOF_ '72.3' ': ROCK 4C Plus' '73' ': ROCK Pi S' '74' ': Radxa Zero' + '90' ': Radxa ZERO 3' '77' ': ROCK 3A' '78' ': ROCK 5B' '85' ': ROCK 5A' '87' ': Orange Pi 3B' + '89' ': Orange Pi 3 LTS' '80' ': Orange Pi 5' '82' ': Orange Pi 5 Plus' '83.1' ': Orange Pi Zero 3' @@ -619,7 +621,7 @@ _EOF_ G_EXEC mv "DietPi-$G_GITBRANCH/.build/images/U-Boot/99-dietpi-uboot" /etc/initramfs/post-update.d/99-dietpi-uboot G_EXEC sed --follow-symlinks -i 's/arm64/arm/' /etc/initramfs/post-update.d/99-dietpi-uboot - elif [[ $G_HW_MODEL =~ ^(12|15|16|40|42|43|44|45|46|47|48|52|54|55|56|57|58|59|60|62|63|64|65|66|67|68|72|73|74|76|77|78|79|80|82|83|85|86|87)$ ]] + elif [[ $G_HW_MODEL =~ ^(12|15|16|40|42|43|44|45|46|47|48|52|54|55|56|57|58|59|60|62|63|64|65|66|67|68|72|73|74|76|77|78|79|80|82|83|85|86|87|89|90)$ ]] then armbian_repo=1 G_EXEC mv "DietPi-$G_GITBRANCH/.build/images/U-Boot/boot.cmd" /boot/boot.cmd @@ -660,7 +662,7 @@ setenv rootuuid "true"' /boot/boot.cmd (( $G_HW_MODEL == 15 )) && G_EXEC eval 'echo '\''meson_rng'\'' > /etc/modules-load.d/dietpi-hwrng.conf' # Rockchip 64-bit (configs work with Amlogic OOTB) - elif [[ $G_HW_MODEL =~ ^(42|43|46|47|55|56|58|68|72|73|76|77|78|79|80|82|85|86|87)$ ]] + elif [[ $G_HW_MODEL =~ ^(42|43|46|47|55|56|58|68|72|73|76|77|78|79|80|82|85|86|87|90)$ ]] then G_EXEC sed --follow-symlinks -Ei '/^setenv (kernel|fdt)_addr_r/d' /boot/boot.cmd G_CONFIG_INJECT 'setenv scriptaddr ' 'setenv scriptaddr "0x9000000"' /boot/boot.cmd @@ -687,6 +689,7 @@ setenv rootuuid "true"' /boot/boot.cmd 79) (( $HW_VARIANT == 2 )) && G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3588s-nanopi-r6c.dtb' /boot/dietpiEnv.txt;; 85) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3588s-rock-5a.dtb' /boot/dietpiEnv.txt;; 87) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3566-orangepi-3b.dtb' /boot/dietpiEnv.txt;; + 90) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3566-radxa-zero3.dtb' /boot/dietpiEnv.txt;; *) :;; esac case $G_HW_MODEL in @@ -712,7 +715,7 @@ setenv rootuuid "true"' /boot/boot.cmd G_EXEC sed --follow-symlinks -i -e 's/ttyAML0/ttyS2/' -e '/^extraargs=/s/$/ systemd.unified_cgroup_hierarchy=0/' /boot/dietpiEnv.txt # Allwinner 64-bit - elif [[ $G_HW_MODEL =~ ^(40|44|45|57|65|67|83)$ ]] + elif [[ $G_HW_MODEL =~ ^(40|44|45|57|65|67|83|89)$ ]] then G_EXEC sed --follow-symlinks -Ei '/^setenv (kernel|fdt)_addr_r/d' /boot/boot.cmd G_CONFIG_INJECT 'setenv scriptaddr ' 'setenv scriptaddr "0x45000000"' /boot/boot.cmd @@ -1116,6 +1119,8 @@ _EOF_ 85) model='rock-5a' kernel='rk35xx' branch='legacy';; 86) model='tinkerboard-2' kernel='rockchip64';; 87) model='orangepi3b' kernel='rockchip64' branch='edge';; + 89) model='orangepi3-lts' kernel='sunxi64';; + 90) model='radxa-zero3' kernel='rk35xx' branch='legacy';; *) :;; esac @@ -1957,8 +1962,8 @@ _EOF_' then /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyS2 - # PINE A64, Pinebook, PINE H64, NenoPi NEO Plus2, ZeroPi, NanoPi NEO, NanoPi M1, NanoPi NEO Air, NenoPi NEO2, NanoPi M1 Plus, NanoPi K1 Plus, ROCK Pi S, VisionFive 2, Orange Pi Zero 3, Star64 - elif [[ $G_HW_MODEL =~ ^(40|44|45|57|59|60|63|64|65|66|67|73|81|83|84)$ ]] + # PINE A64, Pinebook, PINE H64, NenoPi NEO Plus2, ZeroPi, NanoPi NEO, NanoPi M1, NanoPi NEO Air, NenoPi NEO2, NanoPi M1 Plus, NanoPi K1 Plus, ROCK Pi S, VisionFive 2, Orange Pi Zero 3, Star64, Orange Pi 3 LTS + elif [[ $G_HW_MODEL =~ ^(40|44|45|57|59|60|63|64|65|66|67|73|81|83|84|89)$ ]] then /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyS0 @@ -1967,8 +1972,8 @@ _EOF_' then /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyS1 - # RK3588: ROCK 5B, NanoPi 6, Orange Pi 5, Orange Pi 5 Plus, ROCK 5A - elif [[ $G_HW_MODEL =~ ^(78|79|80|82|85)$ ]] + # Rockchip vendor: ROCK 5B, NanoPi 6, Orange Pi 5, Orange Pi 5 Plus, ROCK 5A, Radxa ZERO 3 + elif [[ $G_HW_MODEL =~ ^(78|79|80|82|85|90)$ ]] then /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyFIQ0 diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index 0307a374b4..249fd50fc5 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -91,7 +91,9 @@ jobs: '"-m 84 -d 8", '\ '"-m 85 -d 6", "-m 85 -d 7", "-m 85 -d 8", '\ '"-m 86 -d 6", "-m 86 -d 7", "-m 86 -d 8", '\ - '"-m 87 -d 6", "-m 87 -d 7", "-m 87 -d 8"]' >> "$GITHUB_OUTPUT" + '"-m 87 -d 6", "-m 87 -d 7", "-m 87 -d 8", '\ + '"-m 89 -d 6", "-m 89 -d 7", "-m 89 -d 8", '\ + '"-m 90 -d 6", "-m 90 -d 7", "-m 90 -d 8"]' >> "$GITHUB_OUTPUT" elif [ "${{ github.event.inputs.buildargs }}" = 'quartz64' ] then echo buildargs=[\ diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index 367bbc9790..2afeda1bd3 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -92,6 +92,8 @@ shopt -s extglob [85]='ROCK 5A' [86]='ASUS Tinker Board 2' [87]='Orange Pi 3B' + [89]='Orange Pi 3 LTS' + [90]='Radxa ZERO 3' ) ## Benchmark data arrays: aBENCH_XX[$HW_MODEL,${aBENCH_XX_INDEX[$HW_MODEL]}] diff --git a/CHANGELOG.txt b/CHANGELOG.txt index f96db459b2..11a29214dd 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -3,6 +3,8 @@ v9.4 New images: - ROCK 4C Plus | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4C Plus, we provide a new image for this particular variant. Many thanks to @lfiorini and @arpegius5555 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6593, https://github.com/MichaIng/DietPi/issues/6935 +- Orange Pi 3 LTS | Added support for this Allwinner H6 based SBC. +- Radxa ZERO 3 | Added support for this Rockchip RK3566 based SBC, the 3E variant with Ethernet as well as the 3W variant with onboard WiFi. Enhancements: - General | Our scripts do now internally enforce the default umask 0022. Many config and install options rely on this, hence it can cause issues when e.g. 0027 (deny read access for "other" users) has been applied on the parent shell. This affects only the (sub)shell of our scripts, while the current and default umask of parent and of shells/consoles remains untouched. diff --git a/dietpi/func/dietpi-obtain_hw_model b/dietpi/func/dietpi-obtain_hw_model index 9a0c8748ef..e49ec26e31 100755 --- a/dietpi/func/dietpi-obtain_hw_model +++ b/dietpi/func/dietpi-obtain_hw_model @@ -316,7 +316,17 @@ G_HW_MODEL=$(mawk 'NR==1' "$FP_G_HW_MODEL_IDENTIFIER") - if (( $G_HW_MODEL == 87 )); then + if (( $G_HW_MODEL == 90 )); then + + G_HW_MODEL_NAME='Radxa ZERO 3' + G_HW_CPUID=9 + + elif (( $G_HW_MODEL == 89 )); then + + G_HW_MODEL_NAME='Orange Pi 3 LTS' + G_HW_CPUID=5 + + elif (( $G_HW_MODEL == 87 )); then G_HW_MODEL_NAME='Orange Pi 3B' G_HW_CPUID=9 diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index e5b3747fd0..1d13bb641e 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -1519,7 +1519,7 @@ Do you want to continue and disable the serial login console?' || return 1 elif (( $DIETPIENV || $G_HW_MODEL == 49 || $G_HW_MODEL == 76 || $G_HW_MODEL == 79 )) then local baudrate='115200' - if [[ $G_HW_MODEL =~ ^(42|43|46|47|49|55|56|58|68|72|76|77|87)$ && $INPUT_ADDITIONAL == 'ttyS2' ]] || [[ $G_HW_MODEL == 73 && $INPUT_ADDITIONAL == 'ttyS'[012] ]] || [[ $G_HW_MODEL =~ ^(76|78|79|80|82|85)$ && $INPUT_ADDITIONAL == 'ttyFIQ0' ]] + if [[ $G_HW_MODEL =~ ^(42|43|46|47|49|55|56|58|68|72|76|77|78|79|80|82|85|87|90)$ && $INPUT_ADDITIONAL =~ ^('ttyS2'|'ttyFIQ0')$ ]] || [[ $G_HW_MODEL == 73 && $INPUT_ADDITIONAL == 'ttyS'[012] ]] then baudrate='1500000' [[ -d /etc/systemd/system/serial-getty@$INPUT_ADDITIONAL.service.d ]] || G_EXEC mkdir "/etc/systemd/system/serial-getty@$INPUT_ADDITIONAL.service.d" diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index eeda29c13f..08de43ed98 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -182,6 +182,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R ;; 81) all_components='visionfive2';; 84) all_components='star64';; + 90) all_components='radxazero3';; *) :;; esac G_EXEC eval "echo 'deb https://dietpi.com/apt $G_DISTRO_NAME $components' > /etc/apt/sources.list.d/dietpi.list" From a0e43d7a9d41d8054c8b14623912cb3a5d8eafe7 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 3 May 2024 01:42:22 +0200 Subject: [PATCH 191/266] v9.4 - DietPi-Obtain_HW_model | On RPi, if no known revision code has been found, but ARMv7/8 detected, fall back to RPi 2 device index, as it cannot be an RPi 1 or Zero (1) then. For this to be checked a little simpler, detect architecture (and distro version) first. --- dietpi/func/dietpi-obtain_hw_model | 93 +++++++++++++++--------------- 1 file changed, 47 insertions(+), 46 deletions(-) diff --git a/dietpi/func/dietpi-obtain_hw_model b/dietpi/func/dietpi-obtain_hw_model index e49ec26e31..1e02062e4d 100755 --- a/dietpi/func/dietpi-obtain_hw_model +++ b/dietpi/func/dietpi-obtain_hw_model @@ -303,6 +303,10 @@ fi G_HW_MANUFACTURER='Embest' + elif (( $G_HW_ARCH > 1 )) + then + # In case of ARMv7/8 architecture, if no model was detected, fall back to RPi 2. + G_HW_MODEL=2 fi } @@ -311,6 +315,49 @@ # NBB: DO NOT REORDER INDEX's. These are now fixed and will never change (due to survey results etc) Obtain_HW_Info(){ + # Get distro ID + local distro=$( Date: Fri, 3 May 2024 15:57:30 +0200 Subject: [PATCH 192/266] v9.4 - DietPi-Software | Update fallback URL - DietPi-WiFiDB | Simplify sed command a little --- dietpi/dietpi-software | 2 +- dietpi/func/dietpi-wifidb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index b627fe7576..e19ec7ec54 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -7530,7 +7530,7 @@ _EOF_ local json=() [[ $PHP_VERSION == 8* ]] || aDEPS+=("php$PHP_VERSION-json") json=('json') - local fallback_url="https://github.com/ampache/ampache/releases/download/6.3.1/ampache-6.3.1_all_php$PHP_VERSION.zip" + local fallback_url="https://github.com/ampache/ampache/releases/download/6.4.0/ampache-6.4.0_all_php$PHP_VERSION.zip" Download_Install "$(curl -sSfL 'https://api.github.com/repos/ampache/ampache/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/ampache-[0-9\.]*_all_php$PHP_VERSION.zip\"$/{print \$4}")" ampache # Reinstall: Preserve configs from old and new paths diff --git a/dietpi/func/dietpi-wifidb b/dietpi/func/dietpi-wifidb index 8b5c168dcb..f2c4fec1de 100755 --- a/dietpi/func/dietpi-wifidb +++ b/dietpi/func/dietpi-wifidb @@ -227,7 +227,7 @@ _EOF_ do G_WHIP_MENU_ARRAY+=("$line" '') - done < <(iwlist "$wifi_iface" scan | sed -n '/^[[:blank:]]*ESSID:/s/^[[:blank:]]*ESSID:"\(.*\)"/\1/p') + done < <(iwlist "$wifi_iface" scan | sed -n 's/^[[:blank:]]*ESSID:"\(.*\)"/\1/p') [[ ${G_WHIP_MENU_ARRAY[0]} ]] || { G_WHIP_MSG 'No WiFi SSID has been found in your area.'; return 1; } From cdacbc021d264499835b2e47389f33f46b3e02e7 Mon Sep 17 00:00:00 2001 From: Joulinar <47155374+Joulinar@users.noreply.github.com> Date: Fri, 3 May 2024 21:28:43 +0200 Subject: [PATCH 193/266] v9.4 (#7056) - DietPi-Software | X.Org X Server: Resolved an issue where an important config files might might have been missing on RPi 5 an potentially Amlogic S905 SBCs, if the config directory /etc/X11/xorg.conf.d did not exist and was not created as part of the related APT packages. Many thanks to @rmscode for reporting this issue: https://dietpi.com/forum/t/19963 --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 11a29214dd..c36f95330e 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -17,6 +17,7 @@ Bug fixes: - DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. - DietPi-Software | OctoPrint: Resolved an issue where the installation failed on RISC-V and ARMv6/7 Bullseye systems, due to changed dependencies. +- DietPi-Software | X.Org X Server: Resolved an issue where an important config files might might have been missing on RPi 5 an potentially Amlogic S905 SBCs, if the config directory /etc/X11/xorg.conf.d did not exist and was not created as part of the related APT packages. Many thanks to @rmscode for reporting this issue: https://dietpi.com/forum/t/19963 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index e19ec7ec54..aa8a442193 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -2657,6 +2657,9 @@ _EOF_ # Generic X server + Mesa OpenGL libraries and utilities aDEPS=('xserver-xorg-core' 'xserver-xorg-input-libinput' 'xinit' 'dbus-user-session' 'xfonts-base' 'x11-xserver-utils' 'x11-utils') + # Disable DPMS and screen blanking + dps_index=$software_id Download_Install '98-dietpi-disable_dpms.conf' /etc/X11/xorg.conf.d/98-dietpi-disable_dpms.conf + # RPi if (( $G_HW_MODEL < 10 )) then @@ -2700,9 +2703,6 @@ Section "Screen" EndSection _EOF_ fi - - # Disable DPMS and screen blanking - dps_index=$software_id Download_Install '98-dietpi-disable_dpms.conf' /etc/X11/xorg.conf.d/98-dietpi-disable_dpms.conf fi if To_Install 152 avahi-daemon # Avahi-Daemon From 3d4b8253411e2b95c49183d1f1006d0eb5a71546 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 4 May 2024 13:28:43 +0200 Subject: [PATCH 194/266] v9.4 - DietPi-Software | X.Org X Server: Fix fix for missing config dir on RPi 5: Download_Install installs aDEPS, hence must stay where it was. --- CHANGELOG.txt | 2 +- dietpi/dietpi-software | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index c36f95330e..58df2a1d7c 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -17,7 +17,7 @@ Bug fixes: - DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. - DietPi-Software | OctoPrint: Resolved an issue where the installation failed on RISC-V and ARMv6/7 Bullseye systems, due to changed dependencies. -- DietPi-Software | X.Org X Server: Resolved an issue where an important config files might might have been missing on RPi 5 an potentially Amlogic S905 SBCs, if the config directory /etc/X11/xorg.conf.d did not exist and was not created as part of the related APT packages. Many thanks to @rmscode for reporting this issue: https://dietpi.com/forum/t/19963 +- DietPi-Software | X.Org X Server: Resolved an issue where an important config file might have been missing on RPi 5 and potentially Amlogic S905 SBCs, if the config directory /etc/X11/xorg.conf.d did not exist and was not created as part of the related APT packages. Many thanks to @rmscode for reporting this issue: https://dietpi.com/forum/t/19963 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index aa8a442193..9cac6e1e92 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -2654,11 +2654,11 @@ _EOF_ if To_Install 6 # X.Org X Server then - # Generic X server + Mesa OpenGL libraries and utilities + # Generic X server and utilities aDEPS=('xserver-xorg-core' 'xserver-xorg-input-libinput' 'xinit' 'dbus-user-session' 'xfonts-base' 'x11-xserver-utils' 'x11-utils') - # Disable DPMS and screen blanking - dps_index=$software_id Download_Install '98-dietpi-disable_dpms.conf' /etc/X11/xorg.conf.d/98-dietpi-disable_dpms.conf + # Pre-create config dir: https://dietpi.com/forum/t/19963 + G_EXEC mkdir -p /etc/X11/xorg.conf.d # RPi if (( $G_HW_MODEL < 10 )) @@ -2703,6 +2703,9 @@ Section "Screen" EndSection _EOF_ fi + + # Disable DPMS and screen blanking + dps_index=$software_id Download_Install '98-dietpi-disable_dpms.conf' /etc/X11/xorg.conf.d/98-dietpi-disable_dpms.conf fi if To_Install 152 avahi-daemon # Avahi-Daemon From d1266cf72a0d022f6095f3ea1f116a90145761ce Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 6 May 2024 22:33:24 +0200 Subject: [PATCH 195/266] v9.4 (#6995) - Image | Add support for Orange Pi Zero 2W --- .build/images/dietpi-build | 1 + .build/images/dietpi-installer | 42 +++++++++++++++--------------- .github/workflows/dietpi-build.yml | 1 + .meta/dietpi-survey_report | 1 + CHANGELOG.txt | 1 + dietpi/dietpi-config | 4 +-- dietpi/func/dietpi-obtain_hw_model | 7 +++++ dietpi/func/dietpi-set_hardware | 18 ++++++------- dietpi/func/dietpi-set_software | 1 + 9 files changed, 44 insertions(+), 32 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index a1465f21d7..e8af5b05ae 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -142,6 +142,7 @@ case $HW_MODEL in 85) iname='ROCK5A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; 86) iname='ASUSTB2' HW_ARCH=3 partition_start=16 root_size=1008;; 87) iname='OrangePi3B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; + 88) iname='OrangePiZero2W' HW_ARCH=3 partition_start=4 root_size=1148;; 89) iname='OrangePi3LTS' HW_ARCH=3 partition_start=4 root_size=892;; 90) iname='RadxaZERO3' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; *) G_DIETPI-NOTIFY 1 "Invalid hardware model \"$HW_MODEL\" passed, aborting..."; exit 1;; diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 3f7becfcee..063da44e33 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -425,6 +425,7 @@ _EOF_ '82' ': Orange Pi 5 Plus' '83.1' ': Orange Pi Zero 3' '83.2' ': Orange Pi Zero 3 (1.5 GB RAM)' + '88' ': Orange Pi Zero 2W' '86' ': ASUS Tinker Board 2' '23' ': Generic Rockchip RK3328' '24' ': Generic Rockchip RK3399' @@ -621,7 +622,7 @@ _EOF_ G_EXEC mv "DietPi-$G_GITBRANCH/.build/images/U-Boot/99-dietpi-uboot" /etc/initramfs/post-update.d/99-dietpi-uboot G_EXEC sed --follow-symlinks -i 's/arm64/arm/' /etc/initramfs/post-update.d/99-dietpi-uboot - elif [[ $G_HW_MODEL =~ ^(12|15|16|40|42|43|44|45|46|47|48|52|54|55|56|57|58|59|60|62|63|64|65|66|67|68|72|73|74|76|77|78|79|80|82|83|85|86|87|89|90)$ ]] + elif [[ $G_HW_MODEL =~ ^(12|15|16|40|42|43|44|45|46|47|48|52|54|55|56|57|58|59|60|62|63|64|65|66|67|68|72|73|74|76|77|78|79|80|82|83|85|86|87|88|89|90)$ ]] then armbian_repo=1 G_EXEC mv "DietPi-$G_GITBRANCH/.build/images/U-Boot/boot.cmd" /boot/boot.cmd @@ -715,30 +716,33 @@ setenv rootuuid "true"' /boot/boot.cmd G_EXEC sed --follow-symlinks -i -e 's/ttyAML0/ttyS2/' -e '/^extraargs=/s/$/ systemd.unified_cgroup_hierarchy=0/' /boot/dietpiEnv.txt # Allwinner 64-bit - elif [[ $G_HW_MODEL =~ ^(40|44|45|57|65|67|83|89)$ ]] + elif [[ $G_HW_MODEL =~ ^(40|44|45|57|65|67|83|88|89)$ ]] then G_EXEC sed --follow-symlinks -Ei '/^setenv (kernel|fdt)_addr_r/d' /boot/boot.cmd G_CONFIG_INJECT 'setenv scriptaddr ' 'setenv scriptaddr "0x45000000"' /boot/boot.cmd G_CONFIG_INJECT 'overlay_path=' 'overlay_path=allwinner' /boot/dietpiEnv.txt + # Device tree case $G_HW_MODEL in 45) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=allwinner/sun50i-h6-pine-h64-model-b.dtb' /boot/dietpiEnv.txt;; + 83) (( $HW_VARIANT == 2 )) && G_CONFIG_INJECT 'fdtfile=' 'fdtfile=allwinner/sun50i-h618-orangepi-zero3.dtb' /boot/dietpiEnv.txt;; + 88) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=allwinner/sun50i-h618-orangepi-zero2w.dtb' /boot/dietpiEnv.txt;; *) :;; esac + # Overlay prefix case $G_HW_MODEL in 40|44) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=sun50i-a64' /boot/dietpiEnv.txt;; 45) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=sun50i-h6' /boot/dietpiEnv.txt;; 57|65|67) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=sun50i-h5' /boot/dietpiEnv.txt;; - 83) - G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=sun50i-h616' /boot/dietpiEnv.txt - (( $HW_VARIANT == 2 )) && G_CONFIG_INJECT 'fdtfile=' 'fdtfile=allwinner/sun50i-h618-orangepi-zero3.dtb' /boot/dietpiEnv.txt - ;; + 83|88) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=sun50i-h616' /boot/dietpiEnv.txt;; *) :;; esac + # Overlays case $G_HW_MODEL in 57|65) G_CONFIG_INJECT 'overlays=' 'overlays=usbhost1 usbhost2' /boot/dietpiEnv.txt;; 67) G_CONFIG_INJECT 'overlays=' 'overlays=analog-codec' /boot/dietpiEnv.txt;; *) :;; esac + # Console args case $G_HW_MODEL in 57|65) G_CONFIG_INJECT 'consoleargs=' 'consoleargs=console=ttyS0,115200' /boot/dietpiEnv.txt;; # headless *) G_EXEC sed --follow-symlinks -i 's/ttyAML0/ttyS0/' /boot/dietpiEnv.txt;; @@ -1005,7 +1009,7 @@ setenv rootuuid "true"' /boot/boot.cmd fi # Skip creating kernel symlinks and remove existing ones - G_DIETPI-NOTIFY 2 'Preventing obsolete kernel and initramfs symlink generation' + G_DIETPI-NOTIFY 2 'Preventing needless kernel and initramfs symlink generation' G_EXEC eval 'echo '\''do_symlinks=0'\'' > /etc/kernel-img.conf' G_EXEC rm -f /{,boot/}{initrd.img,vmlinuz}{,.old} @@ -1119,6 +1123,7 @@ _EOF_ 85) model='rock-5a' kernel='rk35xx' branch='legacy';; 86) model='tinkerboard-2' kernel='rockchip64';; 87) model='orangepi3b' kernel='rockchip64' branch='edge';; + 88) model='orangepizero2w' kernel='sunxi64';; 89) model='orangepi3-lts' kernel='sunxi64';; 90) model='radxa-zero3' kernel='rk35xx' branch='legacy';; *) :;; @@ -1246,7 +1251,7 @@ _EOF_ # Skip creating kernel symlinks and remove existing ones if [[ -L '/vmlinuz' ]] then - G_DIETPI-NOTIFY 2 'Preventing obsolete kernel and initramfs symlink generation' + G_DIETPI-NOTIFY 2 'Preventing needless kernel and initramfs symlink generation' G_EXEC eval 'echo '\''do_symlinks=0'\'' > /etc/kernel-img.conf' G_EXEC rm -f /{initrd.img,vmlinuz}{,.old} fi @@ -1259,6 +1264,9 @@ _EOF_ (( $G_HW_ARCH == 3 )) || a32bit=('raspi-copies-and-fills') if findmnt -M /boot/firmware &> /dev/null then + G_DIETPI-NOTIFY 2 'Preventing needless kernel and initramfs symlink generation' + G_EXEC eval 'echo '\''do_symlinks=0'\'' > /etc/kernel-img.conf' + G_EXEC rm -f /{initrd.img,vmlinuz}{,.old} local kernel=() case $G_HW_MODEL in 0) @@ -1298,14 +1306,6 @@ _EOF_ [[ -f '/etc/apt/trusted.gpg' ]] && G_EXEC rm /etc/apt/trusted.gpg [[ -f '/etc/apt/trusted.gpg~' ]] && G_EXEC rm '/etc/apt/trusted.gpg~' - # Skip creating kernel symlinks and remove existing ones - if [[ -L '/vmlinuz' ]] - then - G_DIETPI-NOTIFY 2 'Preventing obsolete kernel and initramfs symlink generation' - G_EXEC eval 'echo '\''do_symlinks=0'\'' > /etc/kernel-img.conf' - G_EXEC rm -f /{initrd.img,vmlinuz}{,.old} - fi - # Quartz64 elif [[ $G_HW_MODEL == 49 && $(findmnt -Ufnro TARGET -T /boot) == '/' ]] then @@ -1442,7 +1442,7 @@ _EOF_ # Skip creating kernel symlinks and remove existing ones if [[ -L '/vmlinuz' ]] then - G_DIETPI-NOTIFY 2 'Preventing obsolete kernel and initramfs symlink generation' + G_DIETPI-NOTIFY 2 'Preventing needless kernel and initramfs symlink generation' G_EXEC eval 'echo '\''do_symlinks=0'\'' > /etc/kernel-img.conf' G_EXEC rm -f /{initrd.img,vmlinuz}{,.old} fi @@ -1962,8 +1962,8 @@ _EOF_' then /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyS2 - # PINE A64, Pinebook, PINE H64, NenoPi NEO Plus2, ZeroPi, NanoPi NEO, NanoPi M1, NanoPi NEO Air, NenoPi NEO2, NanoPi M1 Plus, NanoPi K1 Plus, ROCK Pi S, VisionFive 2, Orange Pi Zero 3, Star64, Orange Pi 3 LTS - elif [[ $G_HW_MODEL =~ ^(40|44|45|57|59|60|63|64|65|66|67|73|81|83|84|89)$ ]] + # PINE A64, Pinebook, PINE H64, NenoPi NEO Plus2, ZeroPi, NanoPi NEO, NanoPi M1, NanoPi NEO Air, NenoPi NEO2, NanoPi M1 Plus, NanoPi K1 Plus, ROCK Pi S, VisionFive 2, Orange Pi Zero 3, Star64, Orange Pi Zero 2W, Orange Pi 3 LTS + elif [[ $G_HW_MODEL =~ ^(40|44|45|57|59|60|63|64|65|66|67|73|81|83|84|88|89)$ ]] then /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyS0 @@ -2184,8 +2184,8 @@ SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATT SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1", RUN+="/bin/ip l s down dev eth1" SUBSYSTEM=="leds", KERNEL=="user_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="wlan0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev wlan0", RUN+="/bin/ip l s down dev wlan0" _EOF_ - # Orange Pi 3B/Zero 3: Module does not load automatically, but we want it loaded on first boot in case firstrun setup is done via WiFi - elif [[ $G_HW_MODEL =~ ^(83|87)$ ]] + # Orange Pi 3B/Zero 3/Zero 2W: Module does not load automatically, but we want it loaded on first boot in case firstrun setup is done via WiFi + elif [[ $G_HW_MODEL =~ ^(83|87|88)$ ]] then G_EXEC eval 'echo '\''sprdwl_ng'\'' > /etc/modules-load.d/dietpi-enable_wifi.conf' fi diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index 249fd50fc5..601b6a1291 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -92,6 +92,7 @@ jobs: '"-m 85 -d 6", "-m 85 -d 7", "-m 85 -d 8", '\ '"-m 86 -d 6", "-m 86 -d 7", "-m 86 -d 8", '\ '"-m 87 -d 6", "-m 87 -d 7", "-m 87 -d 8", '\ + '"-m 88 -d 6", "-m 88 -d 7", "-m 88 -d 8", '\ '"-m 89 -d 6", "-m 89 -d 7", "-m 89 -d 8", '\ '"-m 90 -d 6", "-m 90 -d 7", "-m 90 -d 8"]' >> "$GITHUB_OUTPUT" elif [ "${{ github.event.inputs.buildargs }}" = 'quartz64' ] diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index 2afeda1bd3..cb2c6a5599 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -92,6 +92,7 @@ shopt -s extglob [85]='ROCK 5A' [86]='ASUS Tinker Board 2' [87]='Orange Pi 3B' + [88]='Orange Pi Zero 2W' [89]='Orange Pi 3 LTS' [90]='Radxa ZERO 3' ) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 58df2a1d7c..4841de64c0 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -5,6 +5,7 @@ New images: - ROCK 4C Plus | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4C Plus, we provide a new image for this particular variant. Many thanks to @lfiorini and @arpegius5555 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6593, https://github.com/MichaIng/DietPi/issues/6935 - Orange Pi 3 LTS | Added support for this Allwinner H6 based SBC. - Radxa ZERO 3 | Added support for this Rockchip RK3566 based SBC, the 3E variant with Ethernet as well as the 3W variant with onboard WiFi. +- Orange Pi Zero 2W | Support for this small form factor SBC with Allwinner H618 SoC was added. Enhancements: - General | Our scripts do now internally enforce the default umask 0022. Many config and install options rely on this, hence it can cause issues when e.g. 0027 (deny read access for "other" users) has been applied on the parent shell. This affects only the (sub)shell of our scripts, while the current and default umask of parent and of shells/consoles remains untouched. diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index 258900fff6..35e9c1bb13 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -1094,8 +1094,8 @@ Re-enabling HDMI requires a reboot. If you need emergency HDMI output, edit the [[ -f '/etc/modprobe.d/dietpi-disable_bluetooth.conf' ]] && bluetooth_state=0 bluetooth_state_text='Off' G_WHIP_MENU_ARRAY+=('Bluetooth' ": [$bluetooth_state_text]") - # Orange Pi Zero 3 specific - if (( $G_HW_MODEL == 83 )) + # Orange Pi Zero 3/Zero 2W specific + if (( $G_HW_MODEL == 83 || $G_HW_MODEL == 88 )) then # SPI state local spi_enabled=$(grep -Ecm1 '^[[:blank:]]*overlays=(.*[[:blank:]])?spi1-cs1-spidev([[:blank:]]|$)' /boot/dietpiEnv.txt) diff --git a/dietpi/func/dietpi-obtain_hw_model b/dietpi/func/dietpi-obtain_hw_model index 1e02062e4d..030bf3cceb 100755 --- a/dietpi/func/dietpi-obtain_hw_model +++ b/dietpi/func/dietpi-obtain_hw_model @@ -12,6 +12,9 @@ # - Generates /boot/dietpi/.hw_model # - Called from /boot/dietpi/preboot, called by /etc/systemd/system/dietpi-preboot.service # + # G_HW_MODEL 90 Radxa ZERO 3 + # G_HW_MODEL 89 Orange Pi 3 LTS + # G_HW_MODEL 88 Orange Pi Zero 2W # G_HW_MODEL 87 Orange Pi 3B # G_HW_MODEL 86 ASUS Tinker Board 2 # G_HW_MODEL 85 ROCK 5A @@ -373,6 +376,10 @@ G_HW_MODEL_NAME='Orange Pi 3 LTS' G_HW_CPUID=5 + elif (( $G_HW_MODEL == 88 )); then + + G_HW_MODEL_NAME='Orange Pi Zero 2W' + elif (( $G_HW_MODEL == 87 )); then G_HW_MODEL_NAME='Orange Pi 3B' diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 1d13bb641e..492bf545e1 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -1112,8 +1112,8 @@ _EOF_ Unknown_Input_Mode fi - # Orange Pi Zero 3 - elif (( $G_HW_MODEL == 83 )) + # Orange Pi Zero 3/Zero 2W + elif (( $G_HW_MODEL == 83 || $G_HW_MODEL == 88 )) then if [[ $INPUT_DEVICE_VALUE == 'enable' ]] then @@ -1148,7 +1148,7 @@ _EOF_ 'hci_uart' ) - [[ $G_HW_MODEL =~ ^(83|87)$ ]] && aBLUETOOTH_MODULES+=('sprdbt_tty') # Orange Pi 3B/Zero 3 + [[ $G_HW_MODEL =~ ^(83|87|88)$ ]] && aBLUETOOTH_MODULES+=('sprdbt_tty') # Orange Pi 3B/Zero 3/Zero 2W if [[ $INPUT_DEVICE_VALUE == 'disable' ]]; then @@ -1244,8 +1244,8 @@ Do you want to continue and disable the serial login console?' || return 1 then (( $G_HW_ONBOARD_WIFI )) && G_EXEC systemctl enable hciuart - # Orange Pi 3B/Zero 3: Module does not load automatically - elif [[ $G_HW_MODEL =~ ^(83|87)$ ]] + # Orange Pi 3B/Zero 3/Zero 2W: Module does not load automatically + elif [[ $G_HW_MODEL =~ ^(83|87|88)$ ]] then modprobe -n sprdbt_tty 2> /dev/null && G_EXEC eval 'echo '\''sprdbt_tty'\'' > /etc/modules-load.d/dietpi-enable_bluetooth.conf' fi @@ -1340,8 +1340,8 @@ Do you want to continue and disable the serial login console?' || return 1 then aWIFI_MODULES+=('bcmdhd') - # + Orange Pi 3B/Zero 3 - elif [[ $G_HW_MODEL =~ ^(83|87)$ ]] + # + Orange Pi 3B/Zero 3/Zero 2W + elif [[ $G_HW_MODEL =~ ^(83|87|88)$ ]] then aWIFI_MODULES+=('sprdwl_ng') fi @@ -1387,8 +1387,8 @@ Do you want to continue and disable the serial login console?' || return 1 then G_EXEC eval 'echo -e '\''options wlan_8192eu rtw_power_mgnt=0\noptions wlan_8812au rtw_power_mgnt=0'\'' > /etc/modprobe.d/dietpi-disable_wifi_powersaving.conf' - # - Orange Pi 3B/Zero 3: Module does not load automatically - elif [[ $G_HW_MODEL =~ ^(83|87)$ ]] + # - Orange Pi 3B/Zero 3/Zero 2W: Module does not load automatically + elif [[ $G_HW_MODEL =~ ^(83|87|88)$ ]] then modprobe -n sprdwl_ng 2> /dev/null && G_EXEC eval 'echo '\''sprdwl_ng'\'' > /etc/modules-load.d/dietpi-enable_wifi.conf' fi diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 08de43ed98..c5bb1cd91f 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -182,6 +182,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R ;; 81) all_components='visionfive2';; 84) all_components='star64';; + 88) all_components='orangepizero2w';; 90) all_components='radxazero3';; *) :;; esac From 743622ef2cfc802cd6a2b5363a1894c1f54ffe1a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 6 May 2024 22:39:35 +0200 Subject: [PATCH 196/266] v9.4 - DietPi-Set_software | Add more APT repo components for SBCs we started to host kernel/U-Boot/firmware fore --- dietpi/func/dietpi-set_software | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index c5bb1cd91f..b7bb255d97 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -123,6 +123,10 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R case $G_HW_MODEL in [0-9]) all_components='rpi';; 10) all_components='odroidc1';; + 40) all_components='pinea64';; + 44) all_components='pinebook';; + 45) all_components='pineh64';; + 48) all_components='nanopir1';; 49) # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed kernel/firmware package # shellcheck disable=SC2154 @@ -141,6 +145,10 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R ;; esac ;; + 56) all_components='nanopineo3';; + 45) all_components='nanopineoplus2';; + 59) all_components='zeropi';; + 60) all_components='nanopineo';; 61) all_components='nanopi2';; 62) # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed U-Boot package @@ -160,7 +168,26 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R esac ;; 63) all_components='nanopim1';; + 64) all_components='nanopineoair';; + 65) + # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed U-Boot package + # shellcheck disable=SC2154 + case $HW_VARIANT in + 1) all_components='nanopineo2';; + 2) all_components='nanopineo2black';; + *) + [[ -f '/etc/apt/sources.list.d/dietpi.list' ]] && all_components=$(sed -n '/ all /{s/^.* all //p;q}' /etc/apt/sources.list.d/dietpi.list) + [[ $all_components ]] || for i in nanopineo2{,black} + do + dpkg-query -s "linux-u-boot-$i-legacy" &> /dev/null || continue + all_components=$i + break + done + ;; + esac + ;; 66) all_components='nanopim1plus';; + 67) all_components='nanopik1plus';; 70) all_components='sparkysbc';; 76) # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed U-Boot package @@ -181,8 +208,10 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R esac ;; 81) all_components='visionfive2';; + 83) all_components='orangepizero3';; 84) all_components='star64';; 88) all_components='orangepizero2w';; + 89) all_components='orangepi3lts';; 90) all_components='radxazero3';; *) :;; esac From 96c735eb56d9bc7167941d9d9474d11219b8182a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 6 May 2024 22:46:05 +0200 Subject: [PATCH 197/266] v9.4 - DietPi-Software | Fix NanoPi NEO Plus2 hardware ID - DietPi-Patches | Update DietPi APT list for several SBCs we added components to our repo for --- .update/patches | 10 ++++++++-- dietpi/func/dietpi-set_software | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.update/patches b/.update/patches index e1e0b951bf..bb8669cd4f 100755 --- a/.update/patches +++ b/.update/patches @@ -1560,8 +1560,14 @@ Patch_9_3() Patch_9_4() { - # Update DietPi APT list for NanoPi R5C - (( $G_HW_MODEL == 76 )) && /boot/dietpi/func/dietpi-set_software apt-mirror dietpi + # Update DietPi APT list for several SBCs we added components to our repo for + if (( $G_HW_MODEL =~ ^(40|44|45|48|56|57||59||60|64|65|67|76|83|88|89|90)$ )) + then + /boot/dietpi/func/dietpi-set_software apt-mirror dietpi + G_AGUP -v + # shellcheck disable=SC2154 + (( $G_AGUP_COUNT )) && G_AGUG + fi if [[ -f '/boot/dietpi/.installed' ]] then diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index b7bb255d97..1d2ba000e6 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -146,7 +146,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R esac ;; 56) all_components='nanopineo3';; - 45) all_components='nanopineoplus2';; + 57) all_components='nanopineoplus2';; 59) all_components='zeropi';; 60) all_components='nanopineo';; 61) all_components='nanopi2';; From d2701918c9ad7ba3cfc526f02be9fb925455359d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 6 May 2024 22:51:45 +0200 Subject: [PATCH 198/266] v9.4 (#7059) - DietPi-WiFiDB | Minor coding --- dietpi/func/dietpi-wifidb | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/dietpi/func/dietpi-wifidb b/dietpi/func/dietpi-wifidb index f2c4fec1de..661652c9a3 100755 --- a/dietpi/func/dietpi-wifidb +++ b/dietpi/func/dietpi-wifidb @@ -207,20 +207,19 @@ _EOF_ # Menus #///////////////////////////////////////////////////////////////////////////////////// - Scan_Wifi(){ - + Scan_Wifi() + { local wifi_iface=$(G_GET_NET -t wlan iface) # Return if no WiFi adapter is detected - [[ ! $wifi_iface ]] && G_WHIP_MSG 'No WiFi adapter was detected on your device. Scanning for interfaces cannot be done.' && return 1 + [[ $wifi_iface ]] || { G_WHIP_MSG 'No WiFi adapter was detected on your device. Scanning for interfaces cannot be done.'; return 1; } + + G_DIETPI-NOTIFY 0 'Scanning for WiFi SSIDs, please wait....' # Assure WiFi adapter is up to allow SSID scanning # - Compared to "ifup", this method does not imply DHCP scanning, which times out when no SSID has been configured yet. ip l set dev "$wifi_iface" up - # Get all SSIDs - G_DIETPI-NOTIFY 0 'Scanning for WiFi SSIDs, please wait....' - # ToDo: We would love to use modern 'iw dev "$wifi_iface" scan' here, but on NanoPi Fire3 with modern USB WiFi adapter this command runs forever without showing any output. Probably the old vendor kernel has something to do with it. G_WHIP_MENU_ARRAY=() while read -r line @@ -235,7 +234,6 @@ _EOF_ aWIFI_SSID[$WIFI_SSID_INDEX]=$G_WHIP_RETURNED_VALUE Change_WifiKey - } Change_WifiSsid(){ From 7560c253af4ef52041db55a76e07908638d7bc12 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 6 May 2024 22:52:23 +0200 Subject: [PATCH 199/266] v9.4 - DietPi-Patches | Syntax --- .update/patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index bb8669cd4f..a1eba3fbce 100755 --- a/.update/patches +++ b/.update/patches @@ -1561,7 +1561,7 @@ Patch_9_3() Patch_9_4() { # Update DietPi APT list for several SBCs we added components to our repo for - if (( $G_HW_MODEL =~ ^(40|44|45|48|56|57||59||60|64|65|67|76|83|88|89|90)$ )) + if [[ $G_HW_MODEL =~ ^(40|44|45|48|56|57||59||60|64|65|67|76|83|88|89|90)$ ]] then /boot/dietpi/func/dietpi-set_software apt-mirror dietpi G_AGUP -v From e1eca1b71961e2d87439c97847509810cfb71745 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 6 May 2024 22:54:59 +0200 Subject: [PATCH 200/266] v9.4 - CHANGELOG | Add entry about solved NanoPi NEO3 issue --- CHANGELOG.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 4841de64c0..a9f98a1d39 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -14,6 +14,7 @@ Enhancements: - DietPi-Software | Snapcast: 64-bit ARM and Debian Bookworm + Trixie will have the now available packages from Snapcast installed, instead of those from the Debian repository. Bug fixes: +- NanoPi NEO3 | Resolved an issue where the Ethernet adapter was not available after reboots. Many thanks to @murraythegoz for reporting this issue: https://github.com/MichaIng/DietPi/issues/6987 - DietPi-VPN | Resolved an issue where installing the IPVanish config failed, due to a changed URL, and startup failed on Bookworm systems since their configs contain a deprecated option. Many thanks to @DreamPhreak and @Michael-Robson for reporting this issue: https://github.com/MichaIng/DietPi/issues/7043 - DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. From be3dacebff7eb2780e6da833f4b56dbd2a983c05 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 6 May 2024 22:56:12 +0200 Subject: [PATCH 201/266] v9.4 - DietPi-Patches | Coding --- .update/patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index a1eba3fbce..56dc3a70af 100755 --- a/.update/patches +++ b/.update/patches @@ -1561,7 +1561,7 @@ Patch_9_3() Patch_9_4() { # Update DietPi APT list for several SBCs we added components to our repo for - if [[ $G_HW_MODEL =~ ^(40|44|45|48|56|57||59||60|64|65|67|76|83|88|89|90)$ ]] + if [[ $G_HW_MODEL =~ ^(40|44|45|48|56|57|59|60|64|65|67|76|83|88|89|90)$ ]] then /boot/dietpi/func/dietpi-set_software apt-mirror dietpi G_AGUP -v From 13898a20a0321ba4267efdfeaf0d8a5401b6a62f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 6 May 2024 23:00:57 +0200 Subject: [PATCH 202/266] v9.4 - RC up --- .update/version | 2 +- CHANGELOG.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.update/version b/.update/version index e2d57b846a..eaecf7dfba 100644 --- a/.update/version +++ b/.update/version @@ -3,7 +3,7 @@ # Available DietPi version G_REMOTE_VERSION_CORE=9 G_REMOTE_VERSION_SUB=4 -G_REMOTE_VERSION_RC=-1 +G_REMOTE_VERSION_RC=0 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/CHANGELOG.txt b/CHANGELOG.txt index a9f98a1d39..6a019a13ea 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,5 +1,5 @@ v9.4 -(2024-05-12) +(2024-05-11) New images: - ROCK 4C Plus | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4C Plus, we provide a new image for this particular variant. Many thanks to @lfiorini and @arpegius5555 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6593, https://github.com/MichaIng/DietPi/issues/6935 From 2a97ec8e0d6c03710d62949c4fa71ecd42c3b650 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 6 May 2024 23:10:43 +0200 Subject: [PATCH 203/266] v9.4 - DietPi-Globals | Update default RC version --- dietpi/func/dietpi-globals | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 314e3c3089..403bdf85b8 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -55,7 +55,7 @@ # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=4 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=-1 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=0 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From 6768bee4483c3a9d38a38a515dbc85ef754fb0da Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 7 May 2024 02:35:03 +0200 Subject: [PATCH 204/266] v9.4 - DietPi-Pre-patches | Typo --- .update/pre-patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/pre-patches b/.update/pre-patches index c041090ab0..92a022d80c 100755 --- a/.update/pre-patches +++ b/.update/pre-patches @@ -425,7 +425,7 @@ then elif apt-mark showauto | grep '^initramfs-tools$' then - G_AGI tiny-initamfs + G_AGI tiny-initramfs G_AGP initramfs-tools # ToDo: Remove existing initramfs images in /boot/initrd-* and /boot/firmware/initramfs* fi From 3edba117009e12fa276f178608d2ec6ac8c3e143 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 7 May 2024 14:01:13 +0200 Subject: [PATCH 205/266] v9.4 - DietPi-Software | frp: Update fallback URL and use new ARM hard-float build on ARMv6/7 --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 9cac6e1e92..f50b3b76bf 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6509,11 +6509,11 @@ _EOF_ 3) local arch='arm64';; 10) local arch='amd64';; 11) local arch='riscv64';; - *) local arch='arm';; + *) local arch='arm_hf';; esac # Download - local fallback_url="https://github.com/fatedier/frp/releases/download/v0.57.0/frp_0.57.0_linux_$arch.tar.gz" + local fallback_url="https://github.com/fatedier/frp/releases/download/v0.58.0/frp_0.58.0_linux_$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/fatedier/frp/releases/latest' | mawk -F\" "/\"browser_download_url\": .*\/frp_[0-9.]*_linux_$arch\.tar\.gz\"/{print \$4}")" G_EXEC cd frp_* From e9bcca66de033b7ff0b1cda389cea0e73a54a9e7 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 7 May 2024 17:22:53 +0200 Subject: [PATCH 206/266] v9.4 - DietPi-Software | Remote.It: Update device registratio docs URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index f50b3b76bf..f580d9a8ba 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6371,7 +6371,7 @@ _EOF_ G_WHIP_MSG "[ INFO ] The installation of Remote.It is complete. \nThe final step is to register your claim code with your desktop application. See the manual below for instructions on how to do this. -\nhttps://docs.remote.it/software/device-package/installation#3.-claim-and-register-the-device +\nhttps://docs.remote.it/software/device-package/installation#id-3.-claim-and-register-the-device \nYour claim code: $(mawk -F\" '/claim/{print $4}' /etc/remoteit/config.json) \nThen this DietPi device will be online as your Remote.It device and you can start using it." From d02b59513f6032eaa59a3b2b6f6df0064b0f10fb Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 8 May 2024 13:25:19 +0200 Subject: [PATCH 207/266] v9.4 - DietPi-Software | Syncthing: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index f580d9a8ba..47060c7dae 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8917,7 +8917,7 @@ _EOF_ *) local arch='arm';; esac - local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.27.6/syncthing-linux-$arch-v1.27.6.tar.gz" + local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.27.7/syncthing-linux-$arch-v1.27.7.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/syncthing/syncthing/releases/latest' | mawk -F\" "/\"browser_download_url\": .*\/syncthing-linux-$arch-[^\"\/]*\.tar\.gz\"/{print \$4}")" G_EXEC mv syncthing-* /opt/syncthing fi From 56770e91aa484c3fbc6cc4006abf2f2e75162555 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 8 May 2024 13:56:15 +0200 Subject: [PATCH 208/266] v9.4 - CHANGELOG | Add v9.4 PR URL --- CHANGELOG.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 6a019a13ea..1798547579 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -21,7 +21,7 @@ Bug fixes: - DietPi-Software | OctoPrint: Resolved an issue where the installation failed on RISC-V and ARMv6/7 Bullseye systems, due to changed dependencies. - DietPi-Software | X.Org X Server: Resolved an issue where an important config file might have been missing on RPi 5 and potentially Amlogic S905 SBCs, if the config directory /etc/X11/xorg.conf.d did not exist and was not created as part of the related APT packages. Many thanks to @rmscode for reporting this issue: https://dietpi.com/forum/t/19963 -As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME +As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/7063 ----------------------------------------------------------------------------------------------------------- From c7a7975f680fe48e2998a138af0f04dbe8e39685 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 8 May 2024 22:49:30 +0200 Subject: [PATCH 209/266] v9.4 - CI | Armbian: Add own version suffix for packages --- .github/workflows/armbian.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 329064ee06..221335980b 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -65,6 +65,31 @@ jobs: git fetch origin main git rebase origin/main fi + - name: Obtain version suffix + run: | + cd build + read -r version < VERSION + case '${{ github.event.inputs.asset }}' in + firmware) package='armbian-firmware';; + uboot) package='linux-uboot-${{ github.event.inputs.board }}-${{ github.event.inputs.board }}';; + kernel) + family=$(. 'config/boards/${{ github.event.inputs.board }}.'* &> /dev/null; echo "$BOARDFAMILY") + echo "Board family is: $family" + family=$(BRANCH='${{ github.event.inputs.branch }}'; . "config/sources/families/$family.conf" &> /dev/null; echo "$LINUXFAMILY") + echo "Linux family is: $family" + package="linux-image-${{ github.event.inputs.branch }}-$family" + ;; + *) echo 'ERROR: Invalid asset "${{ github.event.inputs.asset }}"'; exit 1;; + esac + curl -fO "https://dietpi.com/downloads/binaries/$package.deb" + cur_version=$(dpkg-deb -f "$package.deb" Version) + rm "$package.deb" + cur_suffix=${cur_version#*-dietpi} + echo "Current package version is: $cur_version" + echo "New Armbian version is: $version" + [ "$version-dietpi$cur_suffix" = "$cur_version" ] && version="$version-dietpi$((cur_suffix+1))" || version="$version-dietpi1" + echo "New package version will be: $version" + echo "version" > VERSION - name: Build asset run: | cd build From 1f60b87c5e99b70733a2cc45631d4d57d491e3a0 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 8 May 2024 22:57:41 +0200 Subject: [PATCH 210/266] v9.4 (#7064) - Orange Pi Zero 3 | Resolved an issue on the 1.5 GiB RAM variant, where the Ethernet adapter was not available anymore after soft/warm reboots. --- .build/images/dietpi-build | 3 +-- .build/images/dietpi-installer | 15 +++------------ .github/workflows/dietpi-build.yml | 3 +-- .update/patches | 14 ++++++++++++++ CHANGELOG.txt | 1 + 5 files changed, 20 insertions(+), 16 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index e8af5b05ae..c13fbf7041 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -136,8 +136,7 @@ case $HW_MODEL in 80) iname='OrangePi5' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; 81) iname='VisionFive2' HW_ARCH=11 root_size=639;; 82) iname='OrangePi5Plus' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; - '83.1') iname='OrangePiZero3' HW_ARCH=3 partition_start=4 root_size=1148;; - '83.2') iname='OrangePiZero3-1.5G' HW_ARCH=3 partition_start=4 root_size=1148;; + 83) iname='OrangePiZero3' HW_ARCH=3 partition_start=4 root_size=1148;; 84) iname='Star64' HW_ARCH=11 root_size=639;; 85) iname='ROCK5A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1008;; 86) iname='ASUSTB2' HW_ARCH=3 partition_start=16 root_size=1008;; diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 063da44e33..289cf0cc13 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -423,8 +423,7 @@ _EOF_ '89' ': Orange Pi 3 LTS' '80' ': Orange Pi 5' '82' ': Orange Pi 5 Plus' - '83.1' ': Orange Pi Zero 3' - '83.2' ': Orange Pi Zero 3 (1.5 GB RAM)' + '83' ': Orange Pi Zero 3' '88' ': Orange Pi Zero 2W' '86' ': ASUS Tinker Board 2' '23' ': Generic Rockchip RK3328' @@ -724,7 +723,6 @@ setenv rootuuid "true"' /boot/boot.cmd # Device tree case $G_HW_MODEL in 45) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=allwinner/sun50i-h6-pine-h64-model-b.dtb' /boot/dietpiEnv.txt;; - 83) (( $HW_VARIANT == 2 )) && G_CONFIG_INJECT 'fdtfile=' 'fdtfile=allwinner/sun50i-h618-orangepi-zero3.dtb' /boot/dietpiEnv.txt;; 88) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=allwinner/sun50i-h618-orangepi-zero2w.dtb' /boot/dietpiEnv.txt;; *) :;; esac @@ -1177,15 +1175,8 @@ _EOF_ G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb G_EXEC rm package.deb fi - # Orange Pi Zero 3 1.5G RAM variant: Install original Orange Pi bootloader - if (( $G_HW_MODEL == 83 )) && (( $HW_VARIANT == 2 )) - then - G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb 'https://dietpi.com/downloads/binaries/linux-u-boot-orangepizero3-next_1.5G.deb' - G_AGI linux-{image,dtb}-"$branch-$kernel" ./package.deb - G_EXEC rm package.deb - else - G_AGI linux-{image,dtb}-"$branch-$kernel" "linux-u-boot-$model-$branch" - fi + # Install kernel and bootloader + G_AGI linux-{image,dtb}-"$branch-$kernel" "linux-u-boot-$model-$branch" # Cleanup [[ $G_HW_MODEL != 10 && -f '/boot/uImage' ]] && G_EXEC rm /boot/uImage [[ -f '/boot/.next' ]] && G_EXEC rm /boot/.next diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index 601b6a1291..273bc1a334 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -86,8 +86,7 @@ jobs: '"-m 80 -d 6", "-m 80 -d 7", "-m 80 -d 8", '\ '"-m 81 -d 8", '\ '"-m 82 -d 6", "-m 82 -d 7", "-m 82 -d 8", '\ - '"-m 83.1 -d 6", "-m 83.1 -d 7", "-m 83.1 -d 8", '\ - '"-m 83.2 -d 6", "-m 83.2 -d 7", "-m 83.2 -d 8", '\ + '"-m 83 -d 6", "-m 83 -d 7", "-m 83 -d 8", '\ '"-m 84 -d 8", '\ '"-m 85 -d 6", "-m 85 -d 7", "-m 85 -d 8", '\ '"-m 86 -d 6", "-m 86 -d 7", "-m 86 -d 8", '\ diff --git a/.update/patches b/.update/patches index 56dc3a70af..d489497e72 100755 --- a/.update/patches +++ b/.update/patches @@ -1569,6 +1569,20 @@ Patch_9_4() (( $G_AGUP_COUNT )) && G_AGUG fi + # Orange Pi Zero 3 1.5 GiB RAM: Fix lost Ethernet adapter on reboot: https://github.com/MichaIng/DietPi/issues/6938 + if (( $G_HW_MODEL == 83 )) && dpkg-query -s 'linux-u-boot-orangepizero3-next' &> /dev/null + then + G_DIETPI-NOTIFY 2 'Switching to new U-Boot build which fixes lost Ethernet adapter on reboot ...' + G_AGP linux-u-boot-orangepizero3-next + G_AGI linux-u-boot-orangepizero3-current + # shellcheck disable=SC1091 + . /usr/lib/u-boot/platform_install.sh + # Do not mute progress and error messages + eval "$(declare -f write_uboot_platform | sed -e 's| > /dev/null 2>&1||g' -e 's|status=none|status=progress|g')" + # shellcheck disable=SC2154 + write_uboot_platform "$DIR" "$(lsblk -npo PKNAME "$G_ROOTFS_DEV")" + fi + if [[ -f '/boot/dietpi/.installed' ]] then # GMediaRender diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 1798547579..2e540f0ba3 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -15,6 +15,7 @@ Enhancements: Bug fixes: - NanoPi NEO3 | Resolved an issue where the Ethernet adapter was not available after reboots. Many thanks to @murraythegoz for reporting this issue: https://github.com/MichaIng/DietPi/issues/6987 +- Orange Pi Zero 3 | Resolved an issue on the 1.5 GiB RAM variant, where the Ethernet adapter was not available anymore after soft/warm reboots. - DietPi-VPN | Resolved an issue where installing the IPVanish config failed, due to a changed URL, and startup failed on Bookworm systems since their configs contain a deprecated option. Many thanks to @DreamPhreak and @Michael-Robson for reporting this issue: https://github.com/MichaIng/DietPi/issues/7043 - DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. From f0b049001bd8197b353c4f59a413653a9bd08bab Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 8 May 2024 23:12:42 +0200 Subject: [PATCH 211/266] v9.4 - CI | Armbian: Typo --- .github/workflows/armbian.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 221335980b..47c4fac0fd 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -89,7 +89,7 @@ jobs: echo "New Armbian version is: $version" [ "$version-dietpi$cur_suffix" = "$cur_version" ] && version="$version-dietpi$((cur_suffix+1))" || version="$version-dietpi1" echo "New package version will be: $version" - echo "version" > VERSION + echo "$version" > VERSION - name: Build asset run: | cd build From 03b8282751f6020a116809314868aa589b395b7b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 9 May 2024 00:06:10 +0200 Subject: [PATCH 212/266] v9.4 - DietPi-Set_hardware | Fix condition for Raspberry Pi check, to avoid (visual-only) failure when non-RPi devices enable Bluetooth --- dietpi/func/dietpi-set_hardware | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 492bf545e1..dc70037ac1 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -1240,9 +1240,9 @@ Do you want to continue and disable the serial login console?' || return 1 G_EXEC systemctl enable --now bluetooth # RPi - if (( $G_HW_MODEL > 9 )) + if (( $G_HW_MODEL < 10 )) && (( $G_HW_ONBOARD_WIFI )) then - (( $G_HW_ONBOARD_WIFI )) && G_EXEC systemctl enable hciuart + G_EXEC systemctl enable hciuart # Orange Pi 3B/Zero 3/Zero 2W: Module does not load automatically elif [[ $G_HW_MODEL =~ ^(83|87|88)$ ]] From 101401b7536b00a2f6bddcee1c052ca836ee1352 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 9 May 2024 13:36:30 +0200 Subject: [PATCH 213/266] v9.4 - CI | Skip APT dist/full-upgrade on ARMv6/7 Trixie systems, until time_t transition has finished, as the repo currently contains dependency conflicts - CI | Amiberry: Shutdown system if first run setup failed, and print debug info --- .build/software/Amiberry/container_build.bash | 6 ++++++ .build/software/dietpi-software-build.bash | 3 +++ .github/workflows/dietpi-software.bash | 3 +++ 3 files changed, 12 insertions(+) diff --git a/.build/software/Amiberry/container_build.bash b/.build/software/Amiberry/container_build.bash index ec02d67c2c..ef5063d4a9 100755 --- a/.build/software/Amiberry/container_build.bash +++ b/.build/software/Amiberry/container_build.bash @@ -116,6 +116,9 @@ G_EXEC eval 'echo '\''infocmp "$TERM" > /dev/null 2>&1 || { echo "[ WARN ] Unsup # Workaround for failing IPv4 network connectivity check as GitHub Actions runners do not receive external ICMP echo replies G_CONFIG_INJECT 'CONFIG_CHECK_CONNECTION_IP=' 'CONFIG_CHECK_CONNECTION_IP=127.0.0.1' rootfs/boot/dietpi.txt +# Shutdown on failures before the custom script is executed +G_EXEC sed --follow-symlinks -i 's|Prompt_on_Failure$|{ journalctl -n 50; ss -tulpn; df -h; free -h; poweroff; }|' rootfs/boot/dietpi/dietpi-login + # Avoid DietPi-Survey uploads to not mess with the statistics G_EXEC rm rootfs/root/.ssh/known_hosts @@ -134,6 +137,9 @@ Pin-Priority: -1 _EOF_ fi +# ARMv6/7 Trixie: Temporarily prevent dist-upgrade on Trixie, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. +(( $arch < 3 )) && [[ $DISTRO == 'trixie' ]] && G_EXEC touch rootfs/boot/dietpi/.skip_distro_upgrade + # Automated build cat << _EOF_ >> rootfs/boot/Automation_Custom_Script.sh || Error_Exit 'Failed to generate Automation_Custom_Script.sh' echo '[ INFO ] Running Amiberry build script ...' diff --git a/.build/software/dietpi-software-build.bash b/.build/software/dietpi-software-build.bash index b29492cb9c..922283360b 100644 --- a/.build/software/dietpi-software-build.bash +++ b/.build/software/dietpi-software-build.bash @@ -129,6 +129,9 @@ G_EXEC sed --follow-symlinks -i 's|Prompt_on_Failure$|{ journalctl -n 50; ss -tu # Avoid DietPi-Survey uploads to not mess with the statistics G_EXEC rm rootfs/root/.ssh/known_hosts +# ARMv6/7 Trixie: Temporarily prevent dist-upgrade on Trixie, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. +(( $arch < 3 )) && [[ $DISTRO == 'trixie' ]] && G_EXEC touch rootfs/boot/dietpi/.skip_distro_upgrade + # Automated build cat << _EOF_ > rootfs/boot/Automation_Custom_Script.sh || Error_Exit 'Failed to generate Automation_Custom_Script.sh' #!/bin/dash diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index d735537fa5..397e94220d 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -368,6 +368,9 @@ G_EXEC eval 'echo -e '\''[Service]\nAmbientCapabilities='\'' > rootfs/etc/system # Workaround for sysctl: permission denied on key "net.core.rmem_max" in containers G_EXEC sed --follow-symlinks -i '/# Start DietPi-Software/a\sed -i '\''/G_EXEC sysctl -w net\.core\.rmem_max/d'\'' /boot/dietpi/dietpi-software' rootfs/boot/dietpi/dietpi-login +# ARMv6/7 Trixie: Temporarily prevent dist-upgrade on Trixie, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. +(( $arch < 3 )) && [[ $DISTRO == 'trixie' ]] && G_EXEC touch rootfs/boot/dietpi/.skip_distro_upgrade + # Check for service status, ports and commands # shellcheck disable=SC2016 # - Start all services From d2251bb4b93af6385b32a07f3c1a3a8ebe09dae1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 9 May 2024 15:26:46 +0200 Subject: [PATCH 214/266] v9.4 - Raspberry Pi | On images with new kernel/firmware stack, remove left over initramfs images, and skip it in pre-patches, if any initramfs implementation was manually installed. --- .build/images/dietpi-installer | 2 ++ .update/pre-patches | 18 ++++++------------ 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 289cf0cc13..001d06a338 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1284,6 +1284,8 @@ _EOF_ G_AGI raspi-firmware G_CONFIG_INJECT 'SKIP_INITRAMFS_GEN=' 'SKIP_INITRAMFS_GEN=yes' /etc/default/raspi-firmware G_AGI "${kernel[@]}" raspi-utils raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}" tiny-initramfs + G_EXEC apt-mark auto tiny-initramfs + G_EXEC rm -f /boot/initrd.img-* /boot/firmware/initramfs* else G_AGI raspberrypi-bootloader raspberrypi-kernel libraspberrypi0 libraspberrypi-bin raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}" fi diff --git a/.update/pre-patches b/.update/pre-patches index 92a022d80c..11fbb5afe4 100755 --- a/.update/pre-patches +++ b/.update/pre-patches @@ -415,20 +415,14 @@ fi # v9.4 if (( $G_DIETPI_VERSION_CORE < 9 || ( $G_DIETPI_VERSION_CORE == 9 && $G_DIETPI_VERSION_SUB < 4 ) )) then - if (( $G_HW_MODEL < 10 && $G_DISTRO > 6 )) && dpkg-query -s 'raspi-firmware' &> /dev/null + if (( $G_HW_MODEL < 10 && $G_DISTRO > 6 )) && dpkg-query -s 'raspi-firmware' &> /dev/null && ! apt-mark showmanual | grep -E '^(initramfs-tools|dracut|tiny-initramfs)(-core)?$' then - # Satisfy upcoming initramfs dependency of new kernel packages with slim tiny-initramfs: https://github.com/RPi-Distro/repo/issues/358 + G_DIETPI-NOTIFY 2 'Satisfying initramfs package dependency of raspi-firmware with tiny-initramfs' # https://github.com/RPi-Distro/repo/issues/358 G_CONFIG_INJECT 'SKIP_INITRAMFS_GEN=' 'SKIP_INITRAMFS_GEN=yes' /etc/default/raspi-firmware - if ! dpkg-query -s 'initramfs-tools' &> /dev/null - then - G_AGI tiny-initramfs - - elif apt-mark showauto | grep '^initramfs-tools$' - then - G_AGI tiny-initramfs - G_AGP initramfs-tools - # ToDo: Remove existing initramfs images in /boot/initrd-* and /boot/firmware/initramfs* - fi + G_AGI tiny-initramfs + G_EXEC apt-mark auto tiny-initramfs + G_AGP initramfs-tools + G_EXEC rm -f /boot/initrd.img-* /boot/firmware/initramfs* fi fi From 0c53d73dc6e021058b39a5e3109013ff3e89c321 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 9 May 2024 16:11:51 +0200 Subject: [PATCH 215/266] v9.4 - CI | Armbian: Allow current package download to fail, since we do not host all of them yet --- .github/workflows/armbian.yml | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 47c4fac0fd..ab86ec4f0c 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -81,11 +81,13 @@ jobs: ;; *) echo 'ERROR: Invalid asset "${{ github.event.inputs.asset }}"'; exit 1;; esac - curl -fO "https://dietpi.com/downloads/binaries/$package.deb" - cur_version=$(dpkg-deb -f "$package.deb" Version) - rm "$package.deb" - cur_suffix=${cur_version#*-dietpi} - echo "Current package version is: $cur_version" + if curl -fO "https://dietpi.com/downloads/binaries/$package.deb" + then + cur_version=$(dpkg-deb -f "$package.deb" Version) + rm "$package.deb" + cur_suffix=${cur_version#*-dietpi} + echo "Current package version is: $cur_version" + fi echo "New Armbian version is: $version" [ "$version-dietpi$cur_suffix" = "$cur_version" ] && version="$version-dietpi$((cur_suffix+1))" || version="$version-dietpi1" echo "New package version will be: $version" From a8ef0d7e8b3db0a59cb51e3067ff196e96f4db61 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 11 May 2024 01:41:05 +0200 Subject: [PATCH 216/266] v9.4 - RC up --- .update/version | 2 +- dietpi/func/dietpi-globals | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.update/version b/.update/version index eaecf7dfba..dfc5291528 100644 --- a/.update/version +++ b/.update/version @@ -3,7 +3,7 @@ # Available DietPi version G_REMOTE_VERSION_CORE=9 G_REMOTE_VERSION_SUB=4 -G_REMOTE_VERSION_RC=0 +G_REMOTE_VERSION_RC=1 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 403bdf85b8..0c51d713cc 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -55,7 +55,7 @@ # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=4 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=0 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=1 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From b1cbc54ff68a6abbf41295c820d4267359331b7a Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 11 May 2024 01:52:42 +0200 Subject: [PATCH 217/266] v9.4 (#7067) - Odroid XU4 | Update boot.ini for Linux 6.1/6.6 --- .build/images/OdroidXU4/boot.ini | 87 +++++++------------------------- .build/images/dietpi-installer | 7 +-- .update/patches | 21 +++++--- CHANGELOG.txt | 1 + dietpi/dietpi-config | 14 ++--- dietpi/func/dietpi-set_hardware | 22 +++++++- dietpi/func/dietpi-set_software | 1 + 7 files changed, 60 insertions(+), 93 deletions(-) diff --git a/.build/images/OdroidXU4/boot.ini b/.build/images/OdroidXU4/boot.ini index efcbd66771..e86febe9f7 100644 --- a/.build/images/OdroidXU4/boot.ini +++ b/.build/images/OdroidXU4/boot.ini @@ -4,24 +4,25 @@ ODROIDXU-UBOOT-CONFIG setenv initrd_high "0xffffffff" setenv fdt_high "0xffffffff" -# MAC address configuration -setenv macaddr "00:1e:06:61:7a:72" - # Kernel command-line parameters setenv bootrootfs "root=/dev/mmcblk0p1 rootfstype=ext4 rootwait ro console=ttySAC2,115200n8 console=tty1 consoleblank=0 net.ifnames=0" -# HDMI/DVI selection: "hdmi" or "dvi" -# - DVI mode disables HDMI sound -setenv vout "hdmi" - -# HDMI Hot Plug Detect -# - "false" disables auto-detection and forces HDMI output. -# - "true" enables HDMI detection based on cable connection. -setenv HPD "true" - # HDMI CEC: "false" or "true", defaults to "true" #setenv cecenable "true" +# Disable ODROID-VU7 touchscreen support: "false" or "true", defaults to "true" +#setenv disable_vu7 "true" + +# ODROID CloudShell 2 TFT LCD and FAN control via I2C bus: "false" or "true", defaults to "false" +#setenv cs2enable "false" + +# Device tree overlays +# - See /boot/dtb/overlays or /boot/dtb for available overlays (*.dtbo files): defaults to empty string "" +#setenv overlays "i2c0" + +# DDR frequency [MHz]: "633", "728", "825" or "933", defaults to "825" +#setenv ddr_freq "825" + # HDMI resolution # - Uncomment only ONE line! Leave all commented for automatic selection. # - Uncomment only the setenv line! @@ -123,71 +124,21 @@ setenv HPD "true" #setenv videoconfig "drm_kms_helper.edid_firmware=edid/480x800.bin" # ----------------------------------------------- -# Disable ODROID-VU7 touchscreen support: "false" or "true", defaults to "true" -#setenv disable_vu7 "true" - -# ODROID CloudShell 2 TFT LCD and FAN control via I2C bus: "false" or "true", defaults to "false" -#setenv cs2enable "false" - -# Device tree overlays -# - See /boot/dtb/overlays for available overlays: defaults to empty string "" -#setenv overlays "i2c0" - -# CPU governor -# - DietPi will override this setting to user configured in dietpi-config > Performance Options > CPU governor -setenv governor "performance" - -# DDR frequency [MHz]: "633", "728", "825" or "933", defaults to "825" -#setenv ddr_freq "825" - -# TMDS data amplitude control. -# - 1LSB corresponds to 20 mVdiff amplitude level -# - tx_amp_lvl : 0 = 760 mVdiff(Min), 31 = 1380 mVdiff(Max) -# - Hardkernel default: hdmi_tx_amp_lvl = 31(1380 mVdiff) -setenv hdmi_tx_amp_lvl "31" - -# TMDS data amplitude fine control for each channel -# - 1LSB corresponds to 20 mVdiff amplitude level -# - tx_lvl : 0 = 0 mVdiff(Min), 3 = 60 mVdiff(Max) -# - Hardkernel default: hdmi_tx_lvl_ch0=hdmi_tx_lvl_ch1=hdmi_tx_lvl_ch2 = 3 -setenv hdmi_tx_lvl_ch0 "3" -setenv hdmi_tx_lvl_ch1 "3" -setenv hdmi_tx_lvl_ch2 "3" - -# TMDS data pre-emphasis level control -# - 1LSB corresponds to -0.45dB emphasis level except for 1 -# - tx_emp_lvl : 0 = 0 db(Min), 1 = -0.25 db, 2 = 0.7 db, 15 = -7.45 db(Max) -# - Hardkernel default: hdmi_tx_emp_lvl = 6 (-2.50 db) -setenv hdmi_tx_emp_lvl "6" - -# TMDS clock amplitude control -# - 1LSB corresponds to 20 mVdiff amplitude level. -# - clk_amp_lvl : 0 = 790 mVdiff(Min), 31 = 1410 mVdiff(Max) -# - Hardkernel default hdmi_clk_amp_lvl = 31 (1410 mVdiff) -setenv hdmi_clk_amp_lvl "31" - -# TMDS data source termination resistor control -# - tx_res : 0 = Source Termination OFF(Min), 1 = 200 ohm, 2 = 300 ohm, 3 = 120 ohm(Max) -# - Hardkernel default hdmi_tx_res = 0 (Source Termination OFF) -setenv hdmi_tx_res "0" - ### DO NOT EDIT ANYTHING BELOW THIS LINE ### -setenv hdmi_phy_control "hdmi_tx_amp_lvl=${hdmi_tx_amp_lvl} hdmi_tx_lvl_ch0=${hdmi_tx_lvl_ch0} hdmi_tx_lvl_ch1=${hdmi_tx_lvl_ch1} hdmi_tx_lvl_ch2=${hdmi_tx_lvl_ch2} hdmi_tx_emp_lvl=${hdmi_tx_emp_lvl} hdmi_clk_amp_lvl=${hdmi_clk_amp_lvl} hdmi_tx_res=${hdmi_tx_res} HPD=${HPD} vout=${vout}" - # Load kernel, initrd and dtb in that sequence -ext4load mmc 0:1 0x40008000 /boot/zImage || fatload mmc 0:1 0x40008000 zImage || ext4load mmc 0:1 0x40008000 zImage -ext4load mmc 0:1 0x42000000 /boot/uInitrd || fatload mmc 0:1 0x42000000 uInitrd || ext4load mmc 0:1 0x42000000 uInitrd +load mmc 0:1 0x40008000 /boot/zImage || load mmc 0:1 0x40008000 zImage +load mmc 0:1 0x42000000 /boot/uInitrd || load mmc 0:1 0x42000000 uInitrd if test "${board_name}" = "xu4"; then setenv fdtfile "exynos5422-odroidxu4.dtb"; fi if test "${board_name}" = "xu3"; then setenv fdtfile "exynos5422-odroidxu3.dtb"; fi if test "${board_name}" = "xu3l"; then setenv fdtfile "exynos5422-odroidxu3-lite.dtb"; fi if test "${board_name}" = "hc1"; then setenv fdtfile "exynos5422-odroidhc1.dtb"; fi -ext4load mmc 0:1 0x44000000 /boot/dtb/${fdtfile} || fatload mmc 0:1 0x44000000 dtb/${fdtfile} || ext4load mmc 0:1 0x44000000 dtb/${fdtfile} +load mmc 0:1 0x44000000 /boot/dtb/${fdtfile} || load mmc 0:1 0x44000000 dtb/${fdtfile} # Set FDT address fdt addr 0x44000000 -if test "${cecenable}" = "false"; then fdt rm /cec@101B0000; fi +if test "${cecenable}" = "false"; then fdt rm /soc/cec@101b0000; fi if test "${disable_vu7}" = "false"; then setenv hid_quirks "usbhid.quirks=0x0eef:0x0005:0x0004"; fi # Add overlays for CloudShell @@ -205,7 +156,7 @@ fi if test "x${overlays}" != "x"; then fdt resize 8192 for overlay in ${overlays}; do - ext4load mmc 0:1 0x60000000 /boot/dtb/overlays/${overlay}.dtbo || fatload mmc 0:1 0x60000000 dtb/overlays/${overlay}.dtbo || ext4load mmc 0:1 0x60000000 dtb/overlays/${overlay}.dtbo + load mmc 0:1 0x60000000 /boot/dtb/${overlay}.dtbo || load mmc 0:1 0x60000000 /boot/dtb/overlays/${overlay}.dtbo || load mmc 0:1 0x60000000 dtb/${overlay}.dtbo || load mmc 0:1 0x60000000 dtb/overlays/${overlay}.dtbo fdt apply 0x60000000 done fi @@ -214,7 +165,7 @@ fi if test "x${ddr_freq}" != "x"; then dmc "${ddr_freq}"; fi # Final boot args (DRM debugging: drm.debug=0xff) -setenv bootargs "${bootrootfs} ${videoconfig} smsc95xx.macaddr=${macaddr} governor=${governor} ${hdmi_phy_control} ${hid_quirks}" +setenv bootargs "${bootrootfs} ${videoconfig} ${hid_quirks}" # Boot the board bootz 0x40008000 0x42000000 0x44000000 diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 001d06a338..4eb8b9588a 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1186,12 +1186,7 @@ _EOF_ # Compile U-Boot script [[ -f '/boot/boot.cmd' ]] && G_EXEC mkimage -C none -A "$arch" -T script -d /boot/boot.cmd /boot/boot.scr # Flash U-Boot - # shellcheck disable=SC1091 - . /usr/lib/u-boot/platform_install.sh - # - Do not mute progress and error messages - eval "$(declare -f write_uboot_platform | sed -e 's| > /dev/null 2>&1||g' -e 's|status=none|status=progress|g')" - # shellcheck disable=SC2154 - write_uboot_platform "$DIR" "$BOOT_DEVICE" + /boot/dietpi/func/dietpi-set_hardware flash-u-boot-mmc "$BOOT_DEVICE" # Odroid C1 cleanup: https://dietpi.com/forum/t/odroid-c1-not-booting-after-kernel-upgrade/17818 if (( $G_HW_MODEL == 10 )) diff --git a/.update/patches b/.update/patches index d489497e72..973ed5f67d 100755 --- a/.update/patches +++ b/.update/patches @@ -1561,7 +1561,7 @@ Patch_9_3() Patch_9_4() { # Update DietPi APT list for several SBCs we added components to our repo for - if [[ $G_HW_MODEL =~ ^(40|44|45|48|56|57|59|60|64|65|67|76|83|88|89|90)$ ]] + if [[ $G_HW_MODEL =~ ^(11|40|44|45|48|56|57|59|60|64|65|67|76|83|88|89|90)$ ]] then /boot/dietpi/func/dietpi-set_software apt-mirror dietpi G_AGUP -v @@ -1569,18 +1569,23 @@ Patch_9_4() (( $G_AGUP_COUNT )) && G_AGUG fi + # Odroid XU4 + if (( $G_HW_MODEL == 11 )) + then + G_DIETPI-NOTIFY 2 'Migrating boot.ini to support new Linux 6.6 device tree overlay locations' + /boot/dietpi/func/dietpi-set_hardware flash-u-boot-mmc + # shellcheck disable=SC2016 + G_EXEC sed -i '\|/boot/dtb/overlays/${overlay}.dtbo|c load mmc 0:1 0x60000000 /boot/dtb/${overlay}.dtbo || load mmc 0:1 0x60000000 /boot/dtb/overlays/${overlay}.dtbo || load mmc 0:1 0x60000000 dtb/${overlay}.dtbo || load mmc 0:1 0x60000000 dtb/overlays/${overlay}.dtbo' /boot/boot.ini + G_DIETPI-NOTIFY 2 'Fixing CEC toggle in boot.ini' + G_EXEC sed -i 's|rm /cec@101B0000;|rm /soc/cec@101b0000;|' /boot/boot.ini + # Orange Pi Zero 3 1.5 GiB RAM: Fix lost Ethernet adapter on reboot: https://github.com/MichaIng/DietPi/issues/6938 - if (( $G_HW_MODEL == 83 )) && dpkg-query -s 'linux-u-boot-orangepizero3-next' &> /dev/null + elif (( $G_HW_MODEL == 83 )) && dpkg-query -s 'linux-u-boot-orangepizero3-next' &> /dev/null then G_DIETPI-NOTIFY 2 'Switching to new U-Boot build which fixes lost Ethernet adapter on reboot ...' G_AGP linux-u-boot-orangepizero3-next G_AGI linux-u-boot-orangepizero3-current - # shellcheck disable=SC1091 - . /usr/lib/u-boot/platform_install.sh - # Do not mute progress and error messages - eval "$(declare -f write_uboot_platform | sed -e 's| > /dev/null 2>&1||g' -e 's|status=none|status=progress|g')" - # shellcheck disable=SC2154 - write_uboot_platform "$DIR" "$(lsblk -npo PKNAME "$G_ROOTFS_DEV")" + /boot/dietpi/func/dietpi-set_hardware flash-u-boot-mmc fi if [[ -f '/boot/dietpi/.installed' ]] diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 2e540f0ba3..93e83feb40 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -11,6 +11,7 @@ Enhancements: - General | Our scripts do now internally enforce the default umask 0022. Many config and install options rely on this, hence it can cause issues when e.g. 0027 (deny read access for "other" users) has been applied on the parent shell. This affects only the (sub)shell of our scripts, while the current and default umask of parent and of shells/consoles remains untouched. - NanoPi R5C | New images, or when flashing the new bootloader binary via dietpi-config > Advanced Options > Update MMC bootloader, support M.2 WiFi modules. - Orange Pi 3B | Added an option for updating the SPI bootloader via dietpi-config > Advanced Options > Update SPI bootloader. +- Odroid XU4 | The kernel will be upgraded to Linux 6.6. - DietPi-Software | Snapcast: 64-bit ARM and Debian Bookworm + Trixie will have the now available packages from Snapcast installed, instead of those from the Debian repository. Bug fixes: diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index 35e9c1bb13..cff560b470 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -1050,8 +1050,8 @@ Re-enabling HDMI requires a reboot. If you need emergency HDMI output, edit the # Armbian U-Boot update if [[ -f '/usr/lib/u-boot/platform_install.sh' ]] then - local rootdev=$(lsblk -npo PKNAME "$G_ROOTFS_DEV") - G_WHIP_MENU_ARRAY+=('Update MMC bootloader' ": Flash current U-Boot to $rootdev") + local bootdev=$(lsblk -npo PKNAME "$(findmnt -Ufnro SOURCE -T /boot)") + G_WHIP_MENU_ARRAY+=('Update MMC bootloader' ": Flash current U-Boot to $bootdev") fi # RPi 4/5 EEPROM update: https://www.raspberrypi.org/documentation/hardware/raspberrypi/booteeprom.md @@ -1214,14 +1214,9 @@ Further information: https://www.raspberrypi.org/documentation/hardware/raspberr elif [[ $G_WHIP_RETURNED_VALUE == 'Update MMC bootloader' ]]; then G_WHIP_YESNO "[ INFO ] MMC bootloader update -\nThis will flash the U-Boot image of the installed linux-u-boot-* package to the MMC device $rootdev. +\nThis will flash the U-Boot image of the installed linux-u-boot-* package to the MMC device $bootdev. \nDo you want to continue?" || return 0 - # shellcheck disable=SC1091 - . /usr/lib/u-boot/platform_install.sh - # Do not mute progress and error messages - eval "$(declare -f write_uboot_platform | sed -e 's| > /dev/null 2>&1||g' -e 's|status=none|status=progress|g')" - # shellcheck disable=SC2154 - write_uboot_platform "$DIR" "$rootdev" + /boot/dietpi/func/dietpi-set_hardware flash-u-boot-mmc "$bootdev" elif [[ $G_WHIP_RETURNED_VALUE == 'Update SPI bootloader' ]]; then @@ -1261,6 +1256,7 @@ Further information: https://www.raspberrypi.org/documentation/hardware/raspberr \nDo you want to continue?' || return 0 # shellcheck disable=SC1091 . /usr/lib/u-boot/platform_install.sh + # shellcheck disable=SC2154 [[ -f $DIR/rkspi_loader.img ]] || { G_WHIP_MSG "[FAILED] SPI U-Boot image missing\n\nThe expected U-Boot image at $DIR/rkspi_loader.img could not be found. Please report this to our GitHub or forum, so we can check back and in case update this dietpi-config option."; return 1; } # shellcheck disable=SC2154 G_EXEC_OUTPUT=1 G_EXEC dd if="$DIR/rkspi_loader.img" of=/dev/mtdblock0 oflag=direct conv=notrunc status=progress diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index dc70037ac1..1cf1e5a6de 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -30,8 +30,9 @@ $FP_SCRIPT rpi-camera enable/disable $FP_SCRIPT rpi-codec enable/disable $FP_SCRIPT rpi-opengl vc4-kms-v3d/vc4-fkms-v3d/disable $FP_SCRIPT rpi3_usb_boot enable -$FP_SCRIPT rpi-eeprom Update RPi 4 EEPROM bootloader and USB firmware +$FP_SCRIPT rpi-eeprom Update RPi 4/5 EEPROM bootloader and USB firmware $FP_SCRIPT vf2-spi-update Update StarFive VisionFive 2 SPI bootloader +$FP_SCRIPT flash-u-boot-mmc [] Flash U-Boot binary to eMMC/SD card, taking device path as optional argument, else flashes to /boot drive $FP_SCRIPT gpudriver none|intel|nvidia|amd|custom $FP_SCRIPT qemu-guest-agent|qga enable/disable " #//////////////////////////////////// @@ -215,7 +216,7 @@ _EOF_ #///////////////////////////////////////////////////////////////////////////////////// RPi_EEPROM() { - (( $G_HW_MODEL > 3 )) || { Unsupported_Input_Name; return 1; } # Exit path for non-RPi 4/5 + (( $G_HW_MODEL > 3 && $G_HW_MODEL < 10 )) || { Unsupported_Input_Name; return 1; } # Exit path for non-RPi 4/5 # Install required APT package G_AG_CHECK_INSTALL_PREREQ rpi-eeprom @@ -243,6 +244,22 @@ _EOF_ G_EXEC rm u-boot-spl.bin.normal.out visionfive2_fw_payload.img } + #///////////////////////////////////////////////////////////////////////////////////// + # flash-u-boot-mmc + #///////////////////////////////////////////////////////////////////////////////////// + Flash_U-Boot_MMC() + { + [[ -f '/usr/lib/u-boot/platform_install.sh' ]] || { G_DIETPI-NOTIFY 1 'Flash script /usr/lib/u-boot/platform_install.sh not found. Aborting ...'; return 1; } + [[ $INPUT_DEVICE_VALUE ]] || INPUT_DEVICE_VALUE=$(lsblk -npo PKNAME "$(findmnt -Ufnro SOURCE -T /boot)") + [[ -b $INPUT_DEVICE_VALUE ]] || { G_DIETPI-NOTIFY 1 "Block device \"$INPUT_DEVICE_VALUE\" not found. Aborting ..."; return 1; } + # shellcheck disable=SC1091 + . /usr/lib/u-boot/platform_install.sh || return 1 + # Do not mute progress and error messages + eval "$(declare -f write_uboot_platform | sed -e 's| > /dev/null 2>&1||g' -e 's|status=none|status=progress|g')" + # shellcheck disable=SC2154 + write_uboot_platform "$DIR" "$rootdev" + } + #///////////////////////////////////////////////////////////////////////////////////// # gpumemsplit #///////////////////////////////////////////////////////////////////////////////////// @@ -2381,6 +2398,7 @@ _EOF_ 'rpi3_usb_boot') RPi_USB_Boot_Main;; 'rpi-eeprom') RPi_EEPROM;; 'vf2-spi-update') VF2_SPI_Update;; + 'flash-u-boot-mmc') Flash_U-Boot_MMC || EXIT_CODE=1;; 'headless') Headless_Main;; 'gpudriver') GPUDriver_Main;; 'qemu-guest-agent'|'qga') QEMU_Guest_Agent_Main;; diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 1d2ba000e6..929d90b182 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -123,6 +123,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R case $G_HW_MODEL in [0-9]) all_components='rpi';; 10) all_components='odroidc1';; + 11) all_components='odroidxu4';; 40) all_components='pinea64';; 44) all_components='pinebook';; 45) all_components='pineh64';; From 5d137607bb10e98ff190899dd8f65813d0a6e720 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 11 May 2024 02:06:43 +0200 Subject: [PATCH 218/266] v9.4 - CHANGELOG | Add missing dietpi-config bug fix entry --- CHANGELOG.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 93e83feb40..253b05b59a 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -19,6 +19,7 @@ Bug fixes: - Orange Pi Zero 3 | Resolved an issue on the 1.5 GiB RAM variant, where the Ethernet adapter was not available anymore after soft/warm reboots. - DietPi-VPN | Resolved an issue where installing the IPVanish config failed, due to a changed URL, and startup failed on Bookworm systems since their configs contain a deprecated option. Many thanks to @DreamPhreak and @Michael-Robson for reporting this issue: https://github.com/MichaIng/DietPi/issues/7043 - DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 +- DietPi-Config | Resolved a visual-only failure message on non-RPi systems, when enabling Bluetooth, and an actual failure doing so on Orange Pi Zero 3, Orange Pi 3B and Orange Pi Zero 2W, since the required kernel module "sprdbt_tty" was not loaded. Many thanks to @b9AcE for reporting this issue: https://dietpi.com/forum/t/19929/45 - DietPi-Software | Snapcast: Resolved an issue where version 0.27.0 was installed, because since version 0.28.0, Snapcast is provided with client and server packages wrapped into one archive, instead having individual downloads for each package. - DietPi-Software | OctoPrint: Resolved an issue where the installation failed on RISC-V and ARMv6/7 Bullseye systems, due to changed dependencies. - DietPi-Software | X.Org X Server: Resolved an issue where an important config file might have been missing on RPi 5 and potentially Amlogic S905 SBCs, if the config directory /etc/X11/xorg.conf.d did not exist and was not created as part of the related APT packages. Many thanks to @rmscode for reporting this issue: https://dietpi.com/forum/t/19963 From 0ab8c429a4cfbb5f0565943acbb09841d704719d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 11 May 2024 18:56:55 +0200 Subject: [PATCH 219/266] v9.4 - DietPi-Patches | Fix syntax for replacing overlay load commands, to assure indentation - DietPi-Set_hardware | Fix variable name for flashing U-Boot t SD/eMMC - DietPi-CloudShell | On Odroid XU4, when using the CloudShell 2 LCD, during configured auto screen off times, the backlight power of the LCD will be disabled as well, to safe energy and avoid still visible black display content. Many thanks to @smac for suggesting this enhancement: https://dietpi.com/forum/t/15331/55 - DietPi-Config | Added an option to the LCD display menu to toggle the Odroid XU4 CloudShell 2 LCD. - DietPi-Config | Fix detection for Odroid IR remote state - DietPi-Set_hardware | Cleanup Odroid LCD and IR functions, remove handling/config of kernel modules which do not exist anymore since Linux 5.4 --- .update/patches | 7 +- CHANGELOG.txt | 2 + dietpi/dietpi-cloudshell | 5 ++ dietpi/dietpi-config | 9 ++- dietpi/func/dietpi-set_hardware | 116 +++++++++++++++----------------- 5 files changed, 72 insertions(+), 67 deletions(-) diff --git a/.update/patches b/.update/patches index 973ed5f67d..45deca45e0 100755 --- a/.update/patches +++ b/.update/patches @@ -1575,9 +1575,12 @@ Patch_9_4() G_DIETPI-NOTIFY 2 'Migrating boot.ini to support new Linux 6.6 device tree overlay locations' /boot/dietpi/func/dietpi-set_hardware flash-u-boot-mmc # shellcheck disable=SC2016 - G_EXEC sed -i '\|/boot/dtb/overlays/${overlay}.dtbo|c load mmc 0:1 0x60000000 /boot/dtb/${overlay}.dtbo || load mmc 0:1 0x60000000 /boot/dtb/overlays/${overlay}.dtbo || load mmc 0:1 0x60000000 dtb/${overlay}.dtbo || load mmc 0:1 0x60000000 dtb/overlays/${overlay}.dtbo' /boot/boot.ini + G_EXEC sed --follow-symlinks -i '\|/boot/dtb/overlays/${overlay}.dtbo|c\ load mmc 0:1 0x60000000 /boot/dtb/${overlay}.dtbo || load mmc 0:1 0x60000000 /boot/dtb/overlays/${overlay}.dtbo || load mmc 0:1 0x60000000 dtb/${overlay}.dtbo || load mmc 0:1 0x60000000 dtb/overlays/${overlay}.dtbo' /boot/boot.ini G_DIETPI-NOTIFY 2 'Fixing CEC toggle in boot.ini' - G_EXEC sed -i 's|rm /cec@101B0000;|rm /soc/cec@101b0000;|' /boot/boot.ini + G_EXEC sed --follow-symlinks -i 's|rm /cec@101B0000;|rm /soc/cec@101b0000;|' /boot/boot.ini + G_DIETPI-NOTIFY 2 'Cleaning up obsolete configs' + [[ -f '/etc/modprobe.d/odroid-cloudshell.conf' ]] && G_EXEC rm /etc/modprobe.d/odroid-cloudshell.conf + G_EXEC sed --follow-symlinks -Ei '/^[[:blank:]]*(gpioplug-ir-recv|fbtft_device)[[:blank:]]*$/d' /etc/modules # Orange Pi Zero 3 1.5 GiB RAM: Fix lost Ethernet adapter on reboot: https://github.com/MichaIng/DietPi/issues/6938 elif (( $G_HW_MODEL == 83 )) && dpkg-query -s 'linux-u-boot-orangepizero3-next' &> /dev/null diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 253b05b59a..3d0024d5e9 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -12,6 +12,8 @@ Enhancements: - NanoPi R5C | New images, or when flashing the new bootloader binary via dietpi-config > Advanced Options > Update MMC bootloader, support M.2 WiFi modules. - Orange Pi 3B | Added an option for updating the SPI bootloader via dietpi-config > Advanced Options > Update SPI bootloader. - Odroid XU4 | The kernel will be upgraded to Linux 6.6. +- DietPi-CloudShell | On Odroid XU4, when using the CloudShell 2 LCD, during configured auto screen off times, the backlight power of the LCD will be disabled as well, to safe energy and avoid still visible black display content. Many thanks to @smac for suggesting this enhancement: https://dietpi.com/forum/t/15331/55 +- DietPi-Config | Added an option to the LCD display menu to toggle the Odroid XU4 CloudShell 2 LCD. - DietPi-Software | Snapcast: 64-bit ARM and Debian Bookworm + Trixie will have the now available packages from Snapcast installed, instead of those from the Debian repository. Bug fixes: diff --git a/dietpi/dietpi-cloudshell b/dietpi/dietpi-cloudshell index d5927cee6c..1198b1afcf 100755 --- a/dietpi/dietpi-cloudshell +++ b/dietpi/dietpi-cloudshell @@ -53,6 +53,9 @@ setterm --blank 1 --powersave on # Blank after 1 minute as force requires a poke to bring it back up BLANK_SCREEN_ACTIVE=1 + # Odroid XU4 CloudShell 2 backlight + [[ $G_HW_MODEL == 11 && -f '/sys/class/backlight/fb_hktft32/bl_power' ]] && echo 0 > /sys/class/backlight/fb_hktft32/bl_power + # Turn screen on elif (( $BLANK_SCREEN_TIME_HOUR_END == $current_hour )); then @@ -68,6 +71,8 @@ setterm --blank 0 --powersave off BLANK_SCREEN_ACTIVE=0 + # Odroid XU4 CloudShell 2 backlight + [[ $G_HW_MODEL == 11 && -f '/sys/class/backlight/fb_hktft32/bl_power' ]] && echo 1 > /sys/class/backlight/fb_hktft32/bl_power } # Converts a byte int to string, in human readable byte format. diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index cff560b470..f97fc96d59 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -216,11 +216,10 @@ # Remote local odroid_remote_text='Off' local odroid_remote_enabled=0 - if [[ -f '/etc/systemd/system/odroid-remote.service' ]]; then - + if grep -Eq '^[[:blank:]]*(gpio-ir-recv|meson_ir)[[:blank:]]*$' /etc/modules || systemctl -q is-enabled lircd 2> /dev/null + then odroid_remote_text='On' odroid_remote_enabled=1 - fi G_WHIP_MENU_ARRAY+=('10' ": Odroid remote : [$odroid_remote_text]") @@ -260,7 +259,7 @@ else G_WHIP_MENU_ARRAY+=('odroid-lcd35' ': 480x320 panel with touch input') - (( $G_HW_MODEL == 11 )) && G_WHIP_MENU_ARRAY+=('odroid-cloudshell' ': 320x240 panel') + (( $G_HW_MODEL == 11 )) && G_WHIP_MENU_ARRAY+=('odroid-cloudshell' ': 320x240 panel' 'odroid-cloudshell2' ': Odroid XU4 CloudShell 2 LCD') fi @@ -330,7 +329,7 @@ A long (or insufficiently manufactured) cable may required a higher boost settin /boot/dietpi/func/dietpi-set_hardware remoteir none && REBOOT_REQUIRED=1 - elif G_WHIP_YESNO 'This will enable the IR modules, setup Lirc and the Odroid Remote for Odroid C1, C2 and XU4 Cloudshell. + elif G_WHIP_YESNO 'This will enable the IR modules, setup Lirc and the Odroid Remote for Odroid C1, C2 and XU4 CloudShell. \nNB: Other remotes can be configured by running "irrecord" and applying the codes to "/etc/lirc/lircd.conf"\n\nDo you wish to continue?'; then /boot/dietpi/func/dietpi-set_hardware remoteir odroid_remote && REBOOT_REQUIRED=1 diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 1cf1e5a6de..f2ad38477b 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -257,7 +257,7 @@ _EOF_ # Do not mute progress and error messages eval "$(declare -f write_uboot_platform | sed -e 's| > /dev/null 2>&1||g' -e 's|status=none|status=progress|g')" # shellcheck disable=SC2154 - write_uboot_platform "$DIR" "$rootdev" + write_uboot_platform "$DIR" "$INPUT_DEVICE_VALUE" } #///////////////////////////////////////////////////////////////////////////////////// @@ -332,65 +332,52 @@ _EOF_ #///////////////////////////////////////////////////////////////////////////////////// # remoteir #///////////////////////////////////////////////////////////////////////////////////// - RemoteIR_Prereqs(){ G_AG_CHECK_INSTALL_PREREQ lirc; } - - RemoteIR_Reset(){ - + RemoteIR_Reset() + { # Disable JustBoom - if (( $G_HW_MODEL < 10 )); then - - if [[ -f '/etc/systemd/system/justboom-ir-mpd.service' ]]; then - + if (( $G_HW_MODEL < 10 )) + then + if [[ -f '/etc/systemd/system/justboom-ir-mpd.service' ]] + then G_EXEC systemctl disable --now justboom-ir-mpd G_EXEC rm /etc/systemd/system/justboom-ir-mpd.service - fi [[ -d '/etc/systemd/system/justboom-ir-mpd.service.d' ]] && G_EXEC rm -R /etc/systemd/system/justboom-ir-mpd.service.d - G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*dtoverlay=gpio-ir/d' /boot/config.txt # Disable Odroids - elif (( $G_HW_MODEL < 20 )); then - - if [[ -f '/etc/systemd/system/odroid-remote.service' ]]; then - - G_EXEC systemctl disable --now odroid-remote - G_EXEC rm /etc/systemd/system/odroid-remote.service - + elif (( $G_HW_MODEL < 20 )) + then + if systemctl -q is-active lircd || systemctl -q is-enabled lircd 2> /dev/null + then + G_EXEC systemctl disable --now lircd fi - [[ -d '/etc/systemd/system/odroid-remote.service.d' ]] && G_EXEC rm -R /etc/systemd/system/odroid-remote.service.d - + G_EXEC sed --follow-symlinks -Ei '/^[[:blank:]]*(gpio-ir-recv|meson_ir)[[:blank:]]*$/d' /etc/modules fi - } - RemoteIR_Main(){ - + RemoteIR_Main() + { (( $G_HW_MODEL > 19 )) && { Unsupported_Input_Name; return 1; } # Exit path for non-Odroid/non-RPi RemoteIR_Reset - if [[ $INPUT_DEVICE_VALUE == 'odroid_remote' ]]; then - + if [[ $INPUT_DEVICE_VALUE == 'odroid_remote' ]] + then (( $G_HW_MODEL > 9 )) || { Unsupported_Input_Mode; return 1; } # Exit path for non-Odroid - RemoteIR_Prereqs - - # XU4 Cloudshell - if (( $G_HW_MODEL == 11 )); then + G_AG_CHECK_INSTALL_PREREQ lirc - # Modules - local string='options gpioplug_ir_recv gpio_nr=24 active_low=1' - G_CONFIG_INJECT "$string" "$string" /etc/modprobe.d/odroid-cloudshell.conf + # Kernel modules + # - XU4 CloudShell + if (( $G_HW_MODEL == 11 )) + then G_CONFIG_INJECT 'gpio-ir-recv' 'gpio-ir-recv' /etc/modules - G_CONFIG_INJECT 'gpioplug-ir-recv' 'gpioplug-ir-recv' /etc/modules - - # C2 - elif (( $G_HW_MODEL == 12 )); then - # Module + # - C2 + elif (( $G_HW_MODEL == 12 )) + then G_CONFIG_INJECT 'meson_ir' 'meson_ir' /etc/modules - fi # Config @@ -433,12 +420,13 @@ _EOF_ # Service G_EXEC systemctl enable --now lircd - elif [[ $INPUT_DEVICE_VALUE == 'justboom_ir_remote' ]]; then - + elif [[ $INPUT_DEVICE_VALUE == 'justboom_ir_remote' ]] + then (( $G_HW_MODEL > 9 )) && { Unsupported_Input_Mode; return 1; } # Exit path for non-RPi - RemoteIR_Prereqs + G_AG_CHECK_INSTALL_PREREQ lirc mpc + # Device tree overlay G_CONFIG_INJECT 'dtoverlay=gpio-ir' 'dtoverlay=gpio-ir,gpio_pin=25' /boot/config.txt # Config @@ -490,9 +478,6 @@ begin remote end remote _EOF_ - # MPD control - G_AG_CHECK_INSTALL_PREREQ mpc - cat << '_EOF_' > /root/.lircrc begin prog = irexec @@ -555,12 +540,10 @@ _EOF_ G_EXEC systemctl daemon-reload G_EXEC systemctl enable --now justboom-ir-mpd - elif [[ $INPUT_DEVICE_VALUE != 'none' ]]; then - + elif [[ $INPUT_DEVICE_VALUE != 'none' ]] + then Unknown_Input_Mode - fi - } #///////////////////////////////////////////////////////////////////////////////////// @@ -660,11 +643,13 @@ _EOF_ 'odroid-lcd35') Lcd_Panel_OdroidLCD35_Enable;; 'waveshare32') Lcd_Panel_Waveshare32_Enable;; 'odroid-cloudshell') Lcd_Panel_Odroidcloudshell_Enable;; + 'odroid-cloudshell2') Lcd_Panel_Odroidcloudshell2_Enable;; 'esp01215e') Lcd_Panel_ESP01215E_Enable;; 'allo-boss2-oled') OLED_Allo_Boss2_Enable;; 'none') Lcd_Panel_Waveshare32_Disable Lcd_Panel_Odroidcloudshell_Disable + Lcd_Panel_Odroidcloudshell2_Disable Lcd_Panel_OdroidLCD35_Disable Lcd_Panel_ESP01215E_Disable OLED_Allo_Boss2_Disable @@ -848,23 +833,34 @@ _EOF_ } - # Odroid CloudShell - Lcd_Panel_Odroidcloudshell_Enable(){ - - echo 'options fbtft_device name=hktft9340 busnum=1 rotate=270' > /etc/modprobe.d/odroid-cloudshell.conf - + # Odroid CloudShell: ToDo: Broken after fbtft_device kernel module does not exist anymore with Linux 5.4/6.1/6.6... + Lcd_Panel_Odroidcloudshell_Enable() + { G_CONFIG_INJECT 'spi_s3c64xx' 'spi_s3c64xx' /etc/modules - G_CONFIG_INJECT 'fbtft_device' 'fbtft_device' /etc/modules - echo 'fbtft_device' >> /etc/modules # XU4 4.9 workaround: https://github.com/MichaIng/DietPi/issues/926#issuecomment-299480918 - } - Lcd_Panel_Odroidcloudshell_Disable(){ + Lcd_Panel_Odroidcloudshell_Disable() + { + G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*spi_s3c64xx[[:blank:]]*/d' /etc/modules + } - [[ -f '/etc/modprobe.d/odroid-cloudshell.conf' ]] && G_EXEC rm /etc/modprobe.d/odroid-cloudshell.conf - G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*spi_s3c64xx/d' /etc/modules - G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*fbtft_device/d' /etc/modules + # Odroid CloudShell 2 + Lcd_Panel_Odroidcloudshell2_Enable() + { + (( $G_HW_MODEL == 11 )) && { Unsupported_Input_Mode; return 1; } # Odroid XU4 only + # Device tree overlay + G_CONFIG_INJECT 'setenv[[:blank:]]+cs2enable[[:blank:]]' 'setenv cs2enable "true"' /boot/boot.ini 'ODROIDXU-UBOOT-CONFIG' + # udev rule to enable backlight power + G_EXEC eval 'echo '\''SUBSYSTEM=="backlight", KERNEL=="fb_hktft32", ACTION=="add", ATTR{bl_power}="1"'\'' > /etc/udev/rules.d/dietpi-odroid-cloudshell2.rules' + } + Lcd_Panel_Odroidcloudshell2_Disable() + { + (( $G_HW_MODEL == 11 )) && { Unsupported_Input_Mode; return 1; } # Odroid XU4 only + # udev rule to enable backlight power + [[ -f '/etc/udev/rules.d/dietpi-odroid-cloudshell2.rules' ]] && G_EXEC rm /etc/udev/rules.d/dietpi-odroid-cloudshell2.rules + # Device tree overlay + G_CONFIG_INJECT 'setenv[[:blank:]]+cs2enable[[:blank:]]' '#setenv cs2enable "false"' /boot/boot.ini 'ODROIDXU-UBOOT-CONFIG' } # Odroid LCD 3.5 From fd8b25d2576997a82398800c5fc4e54fc4c4278f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 11 May 2024 19:20:41 +0200 Subject: [PATCH 220/266] v9.4 - DietPi-Set_hardware | Fix CloudShell 2 device condition --- dietpi/func/dietpi-set_hardware | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index f2ad38477b..4f30d16418 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -847,7 +847,7 @@ _EOF_ # Odroid CloudShell 2 Lcd_Panel_Odroidcloudshell2_Enable() { - (( $G_HW_MODEL == 11 )) && { Unsupported_Input_Mode; return 1; } # Odroid XU4 only + (( $G_HW_MODEL == 11 )) || { Unsupported_Input_Mode; return 1; } # Odroid XU4 only # Device tree overlay G_CONFIG_INJECT 'setenv[[:blank:]]+cs2enable[[:blank:]]' 'setenv cs2enable "true"' /boot/boot.ini 'ODROIDXU-UBOOT-CONFIG' # udev rule to enable backlight power @@ -856,7 +856,7 @@ _EOF_ Lcd_Panel_Odroidcloudshell2_Disable() { - (( $G_HW_MODEL == 11 )) && { Unsupported_Input_Mode; return 1; } # Odroid XU4 only + (( $G_HW_MODEL == 11 )) || { Unsupported_Input_Mode; return 1; } # Odroid XU4 only # udev rule to enable backlight power [[ -f '/etc/udev/rules.d/dietpi-odroid-cloudshell2.rules' ]] && G_EXEC rm /etc/udev/rules.d/dietpi-odroid-cloudshell2.rules # Device tree overlay From 1cb56318ca59f21d8b91b12451570425584b333f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 11 May 2024 19:48:21 +0200 Subject: [PATCH 221/266] v9.4 - DietPi-Set_hardware | Reset all LCD settings before applying a new one, so that changes from one to another, without selecting "none" in between, works cleanly. For this, assure that all "Disable" functions are skipped on unsupported SBCs. Also hard fail when calling the "lcdpanel" command or giving an invalid/unsupported LCD name, or if an error-handled command fails. --- dietpi/func/dietpi-set_hardware | 53 +++++++++++++++++---------------- 1 file changed, 28 insertions(+), 25 deletions(-) diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 4f30d16418..af4a19e95d 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -639,25 +639,25 @@ _EOF_ #///////////////////////////////////////////////////////////////////////////////////// Lcd_Panel_Main() { + (( $G_HW_MODEL > 19 )) && { Unsupported_Input_Name; return 1; } # Exit path for non-RPi/non-Odroid + + # Reset all LCDs + Lcd_Panel_Waveshare32_Disable + Lcd_Panel_Odroidcloudshell_Disable + Lcd_Panel_Odroidcloudshell2_Disable + Lcd_Panel_OdroidLCD35_Disable + Lcd_Panel_ESP01215E_Disable + OLED_Allo_Boss2_Disable + case $INPUT_DEVICE_VALUE in - 'odroid-lcd35') Lcd_Panel_OdroidLCD35_Enable;; - 'waveshare32') Lcd_Panel_Waveshare32_Enable;; - 'odroid-cloudshell') Lcd_Panel_Odroidcloudshell_Enable;; - 'odroid-cloudshell2') Lcd_Panel_Odroidcloudshell2_Enable;; - 'esp01215e') Lcd_Panel_ESP01215E_Enable;; - 'allo-boss2-oled') OLED_Allo_Boss2_Enable;; - 'none') - Lcd_Panel_Waveshare32_Disable - Lcd_Panel_Odroidcloudshell_Disable - Lcd_Panel_Odroidcloudshell2_Disable - Lcd_Panel_OdroidLCD35_Disable - Lcd_Panel_ESP01215E_Disable - OLED_Allo_Boss2_Disable - ;; - *) - Unknown_Input_Mode - return 1 - ;; + 'odroid-lcd35') Lcd_Panel_OdroidLCD35_Enable || return 1;; + 'waveshare32') Lcd_Panel_Waveshare32_Enable || return 1;; + 'odroid-cloudshell') Lcd_Panel_Odroidcloudshell_Enable || return 1;; + 'odroid-cloudshell2') Lcd_Panel_Odroidcloudshell2_Enable || return 1;; + 'esp01215e') Lcd_Panel_ESP01215E_Enable || return 1;; + 'allo-boss2-oled') OLED_Allo_Boss2_Enable || return 1;; + 'none') :;; + *) Unknown_Input_Mode; return 1;; esac # Update dietpi.txt entry @@ -666,6 +666,8 @@ _EOF_ Lcd_Panel_ESP01215E_Enable(){ + (( $G_HW_MODEL > 9 )) && { Unsupported_Input_Mode; return 1; } # Exit path for non-RPi + G_CONFIG_INJECT 'framebuffer_width=' 'framebuffer_width=1024' /boot/config.txt G_CONFIG_INJECT 'framebuffer_height=' 'framebuffer_height=600' /boot/config.txt G_CONFIG_INJECT 'SOFTWARE_CHROMIUM_RES_X=' "SOFTWARE_CHROMIUM_RES_X=1024" /boot/dietpi.txt @@ -715,8 +717,6 @@ _EOF_ Lcd_Panel_Waveshare32_Enable(){ - (( $G_HW_MODEL > 19 )) && { Unsupported_Input_Mode; return 1; } # Exit path for non-RPi/non-Odroid - # Disable 1st to reset any existing installations Lcd_Panel_Waveshare32_Disable @@ -836,11 +836,13 @@ _EOF_ # Odroid CloudShell: ToDo: Broken after fbtft_device kernel module does not exist anymore with Linux 5.4/6.1/6.6... Lcd_Panel_Odroidcloudshell_Enable() { + (( $G_HW_MODEL == 11 )) || { Unsupported_Input_Mode; return 1; } # Odroid XU4 only G_CONFIG_INJECT 'spi_s3c64xx' 'spi_s3c64xx' /etc/modules } Lcd_Panel_Odroidcloudshell_Disable() { + (( $G_HW_MODEL == 11 )) || return 0 G_EXEC sed --follow-symlinks -i '/^[[:blank:]]*spi_s3c64xx[[:blank:]]*/d' /etc/modules } @@ -856,7 +858,7 @@ _EOF_ Lcd_Panel_Odroidcloudshell2_Disable() { - (( $G_HW_MODEL == 11 )) || { Unsupported_Input_Mode; return 1; } # Odroid XU4 only + (( $G_HW_MODEL == 11 )) || return 0 # udev rule to enable backlight power [[ -f '/etc/udev/rules.d/dietpi-odroid-cloudshell2.rules' ]] && G_EXEC rm /etc/udev/rules.d/dietpi-odroid-cloudshell2.rules # Device tree overlay @@ -866,7 +868,7 @@ _EOF_ # Odroid LCD 3.5 Lcd_Panel_OdroidLCD35_Enable(){ - (( $G_HW_MODEL > 9 && $G_HW_MODEL < 20 )) || { Unsupported_Input_Mode; return 1; } # Exit path for non-Odroid + (( $G_HW_MODEL > 9 )) || { Unsupported_Input_Mode; return 1; } # Exit path for non-Odroid # Reset to disabled Lcd_Panel_OdroidLCD35_Disable @@ -970,7 +972,9 @@ EndSection _EOF_ } - Lcd_Panel_OdroidLCD35_Disable(){ + Lcd_Panel_OdroidLCD35_Disable() + { + (( $G_HW_MODEL > 9 )) || return 0 # Skip on non-Odroid [[ -f '/etc/X11/xorg.conf.d/99-calibration.conf' ]] && G_EXEC rm /etc/X11/xorg.conf.d/99-calibration.conf [[ -f '/etc/modprobe.d/odroid-lcd35.conf' ]] && G_EXEC rm /etc/modprobe.d/odroid-lcd35.conf @@ -981,7 +985,6 @@ _EOF_ fi [[ -d '/etc/systemd/system/odroid-lcd35.service.d' ]] && G_EXEC rm -R /etc/systemd/system/odroid-lcd35.service.d [[ -f '/etc/X11/xorg.conf.d/99-odroid-lcd35.conf' ]] && G_EXEC rm /etc/X11/xorg.conf.d/99-odroid-lcd35.conf - } OLED_Allo_Boss2_Enable(){ @@ -2384,7 +2387,7 @@ _EOF_ 'wificountrycode') Wifi_Countrycode_Main;; 'i2c') I2c_Main;; 'spi') SPI_Main;; - 'lcdpanel') Lcd_Panel_Main;; + 'lcdpanel') Lcd_Panel_Main || EXIT_CODE=1;; 'rpi-opengl') RPi_OpenGL_Main;; 'eth-forcespeed') Eth_Force_Speed_Main;; 'remoteir') RemoteIR_Main;; From 1e8c0af3c0b693c55e3d1b9fcd47b01b7e51a485 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 11 May 2024 23:56:47 +0200 Subject: [PATCH 222/266] v9.4 - APT | Add repo components for all RK3588 SBCs --- .update/patches | 2 +- dietpi/func/dietpi-set_software | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index 45deca45e0..85738f9809 100755 --- a/.update/patches +++ b/.update/patches @@ -1561,7 +1561,7 @@ Patch_9_3() Patch_9_4() { # Update DietPi APT list for several SBCs we added components to our repo for - if [[ $G_HW_MODEL =~ ^(11|40|44|45|48|56|57|59|60|64|65|67|76|83|88|89|90)$ ]] + if [[ $G_HW_MODEL =~ ^(11|40|44|45|48|56|57|59|60|64|65|67|76|78|79|80|82|83|85|88|89|90)$ ]] then /boot/dietpi/func/dietpi-set_software apt-mirror dietpi G_AGUP -v diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 929d90b182..0b6631f002 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -208,9 +208,31 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R ;; esac ;; + 78) all_components='rock5b';; + 79) + # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed U-Boot package + # shellcheck disable=SC2154 + case $HW_VARIANT in + 1|2) all_components='nanopir6s';; # R6C shares R6S component (and bootloader) for now + 3) all_components='nanopct6';; + *) + [[ -f '/etc/apt/sources.list.d/dietpi.list' ]] && all_components=$(sed -n '/ all /{s/^.* all //p;q}' /etc/apt/sources.list.d/dietpi.list) + # shellcheck disable=SC2043 + [[ $all_components ]] || for i in nano{pi-r6s,pct6} + do + dpkg-query -s "linux-u-boot-$i-current" &> /dev/null || continue + all_components=${i/-//} + break + done + ;; + esac + ;; + 80) all_components='orangepi5';; 81) all_components='visionfive2';; + 82) all_components='orangepi5plus';; 83) all_components='orangepizero3';; 84) all_components='star64';; + 85) all_components='rock5a';; 88) all_components='orangepizero2w';; 89) all_components='orangepi3lts';; 90) all_components='radxazero3';; From 35c72b15af53c6e2fa196d813e43af335f2b6d48 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 12 May 2024 00:23:57 +0200 Subject: [PATCH 223/266] v9.4 - DietPi-CloudShell | Do not disable screen blanking when it has been disabled already --- dietpi/dietpi-cloudshell | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) diff --git a/dietpi/dietpi-cloudshell b/dietpi/dietpi-cloudshell index 1198b1afcf..3d2e91e048 100755 --- a/dietpi/dietpi-cloudshell +++ b/dietpi/dietpi-cloudshell @@ -39,15 +39,13 @@ BLANK_SCREEN_TIME_HOUR_END=0 # This will only work if dietpi-cloudshell was started via dietpi-autostart/dietpi-login, as the setterm power options can only be applied when the command originates from the same terminal without redirects. - RUN_BLANK_SCREEN_AT_SPECIFIC_TIME(){ - + RUN_BLANK_SCREEN_AT_SPECIFIC_TIME() + { local current_hour=$(date '+%-H') # Turn screen off - if (( ! $BLANK_SCREEN_ACTIVE )); then - - (( $BLANK_SCREEN_TIME_HOUR_START == $current_hour )) || return - + if (( ! $BLANK_SCREEN_ACTIVE && $BLANK_SCREEN_TIME_HOUR_START == $current_hour )) + then clear echo -e '\n\nScreen will be powered down in under 1 minute\n' setterm --blank 1 --powersave on # Blank after 1 minute as force requires a poke to bring it back up @@ -57,12 +55,10 @@ [[ $G_HW_MODEL == 11 && -f '/sys/class/backlight/fb_hktft32/bl_power' ]] && echo 0 > /sys/class/backlight/fb_hktft32/bl_power # Turn screen on - elif (( $BLANK_SCREEN_TIME_HOUR_END == $current_hour )); then - + elif (( $BLANK_SCREEN_ACTIVE && $BLANK_SCREEN_TIME_HOUR_END == $current_hour )) + then Disable_Screen_Blanking - fi - } Disable_Screen_Blanking(){ @@ -1504,8 +1500,7 @@ _EOF_ if [[ $G_WHIP_RETURNED_VALUE == 'Toggle' ]];then - ((BLANK_SCREEN_AT_SPECIFIC_TIME_ENABLED++)) - (( $BLANK_SCREEN_AT_SPECIFIC_TIME_ENABLED > 1 )) && BLANK_SCREEN_AT_SPECIFIC_TIME_ENABLED=0 + BLANK_SCREEN_AT_SPECIFIC_TIME_ENABLED=$(( ! $BLANK_SCREEN_AT_SPECIFIC_TIME_ENABLED )) elif [[ $G_WHIP_RETURNED_VALUE == 'Start time' ]];then From a3e0848eb239a62d6da32d31f3de94273d798aec Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 12 May 2024 14:53:23 +0200 Subject: [PATCH 224/266] v9.4 - RC up - DietPi-Patches | Avoid doubled apt update/upgrade when systems upgrade from before DietPi v9.3 --- .update/patches | 14 +++++++------- .update/version | 2 +- dietpi/func/dietpi-globals | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.update/patches b/.update/patches index 85738f9809..2fa977e1d3 100755 --- a/.update/patches +++ b/.update/patches @@ -1546,6 +1546,7 @@ Patch_9_2() fi } +PATCH_9_3_RAN=0 Patch_9_3() { # Purge ancient vmtouch which prevents /boot from being unmounted e.g. for RPi firmware migration: https://github.com/MichaIng/DietPi/issues/6819, https://github.com/MichaIng/DietPi/issues/6976 @@ -1553,20 +1554,19 @@ Patch_9_3() # Add DietPi APT repo /boot/dietpi/func/dietpi-set_software apt-mirror dietpi - G_AGUP -v - # shellcheck disable=SC2154 - (( $G_AGUP_COUNT )) && G_AGUG + G_AGUP + G_AGUG + PATCH_9_3_RAN=1 } Patch_9_4() { # Update DietPi APT list for several SBCs we added components to our repo for - if [[ $G_HW_MODEL =~ ^(11|40|44|45|48|56|57|59|60|64|65|67|76|78|79|80|82|83|85|88|89|90)$ ]] + if [[ $PATCH_9_3_RAN == 0 && $G_HW_MODEL =~ ^(11|40|44|45|48|56|57|59|60|64|65|67|76|78|79|80|82|83|85|88|89|90)$ ]] then /boot/dietpi/func/dietpi-set_software apt-mirror dietpi - G_AGUP -v - # shellcheck disable=SC2154 - (( $G_AGUP_COUNT )) && G_AGUG + G_AGUP + G_AGUG fi # Odroid XU4 diff --git a/.update/version b/.update/version index dfc5291528..9e903dac26 100644 --- a/.update/version +++ b/.update/version @@ -3,7 +3,7 @@ # Available DietPi version G_REMOTE_VERSION_CORE=9 G_REMOTE_VERSION_SUB=4 -G_REMOTE_VERSION_RC=1 +G_REMOTE_VERSION_RC=2 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 0c51d713cc..d3bda29db1 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -55,7 +55,7 @@ # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=4 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=1 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=2 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From d67ced4d9decd1810e3484df1f5d071e72b1a447 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 12 May 2024 16:31:21 +0200 Subject: [PATCH 225/266] v9.4 - DietPi config partition | To assure that elsewhere stored and copied config files are treated newer than the ones on the root filesystem, set mtime of those to 1 second after epoch. Set mtime of those on the config partition to 0 seconds after epoch, so, in case they were never touched, they won't be copied. Any (last) edited config file takes hence precedence over the one on the rootfs. Add boot.ini and extlinux.conf to the handled config files. For those, as well as dietpiEnv.txt, if the file from the config partition was copied, hence the one on the effective boot partition overwritten, reboot the system, so the change is effective for 1st boot setup. Such bootloader config files never need to be copied from the RPi boot/firmware partition, since they are effective only there, which is also the reason config.txt and cmdline.txt are not copied. Also update and rephrase the README. --- .build/images/dietpi-imager | 31 ++++++++++++------- .../dietpi/services/fs_partition_resize.sh | 26 +++++++++++++--- 2 files changed, 40 insertions(+), 17 deletions(-) diff --git a/.build/images/dietpi-imager b/.build/images/dietpi-imager index e1d975a6e4..c830d408a5 100755 --- a/.build/images/dietpi-imager +++ b/.build/images/dietpi-imager @@ -529,9 +529,12 @@ G_EXEC mount "${FP_ROOT_DEV::-1}1" "$fat_mountpoint" G_EXEC mount "$FP_ROOT_DEV" "$root_mountpoint" G_DIETPI-NOTIFY 2 'Copying dietpi.txt and other config files to the DIETPISETUP partition' - for f in 'dietpi.txt' 'dietpi-wifi.txt' 'unattended_pivpn.conf' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' + for f in 'dietpi.txt' 'dietpi-wifi.txt' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' 'unattended_pivpn.conf' do - [[ -f $root_mountpoint/boot/$f ]] && G_EXEC cp "$root_mountpoint/boot/$f" "$fat_mountpoint/" + [[ -f $root_mountpoint/boot/$f ]] || continue + G_EXEC cp "$root_mountpoint/boot/$f" "$fat_mountpoint/" + TZ=UTC G_EXEC touch -t '197001010000' "$fat_mountpoint/$f" + TZ=UTC G_EXEC touch -t '197001010001' "$root_mountpoint/boot/$f" done G_EXEC umount "$root_mountpoint" "$fat_mountpoint" G_EXEC rmdir "$root_mountpoint" "$fat_mountpoint" @@ -558,22 +561,26 @@ G_EXEC mount "$new_dos_part" "$fat_mountpoint" G_EXEC mount "$FP_ROOT_DEV" "$root_mountpoint" G_DIETPI-NOTIFY 2 'Copying dietpi.txt and other config files to the DIETPISETUP partition' - for f in 'dietpi.txt' 'dietpi-wifi.txt' 'dietpiEnv.txt' 'unattended_pivpn.conf' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' + for f in 'dietpi.txt' 'dietpi-wifi.txt' 'dietpiEnv.txt' 'boot.ini' 'extlinux/extlinux.conf' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' 'unattended_pivpn.conf' do - [[ -f $root_mountpoint/boot/$f ]] && G_EXEC cp "$root_mountpoint/boot/$f" "$fat_mountpoint/" + [[ -f $root_mountpoint/boot/$f ]] || continue + G_EXEC cp "$root_mountpoint/boot/$f" "$fat_mountpoint/" + TZ=UTC G_EXEC touch -t '197001010000' "$fat_mountpoint/${f#extlinux/}" + TZ=UTC G_EXEC touch -t '197001010001' "$root_mountpoint/boot/$f" done - cat << '_EOF_' > "$fat_mountpoint/Readme-DietPi-Config.txt" -DietPi pre-boot configuration + cat << '_EOF_' > "$fat_mountpoint/README.txt" +DietPi config partition -You can edit the files in this folder to setup some configuration options -or even a completely automated install. Please check the documentation and -dietpi.txt for details: https://dietpi.com/docs/install/ +This FAT partition is a place for relevant configuration files to pre-configure and automate your DietPi setup. +Those files will be copied into the root filesystem on first boot, if modified, to become effective, and the partition will be removed. -This folder also supports the following additional files. Please ensure that -they have UNIX style LF line endings: -- unattended_pivpn.conf +Apart of editing the existing files, you can also create the following for further automation: - Automation_Custom_PreScript.sh - Automation_Custom_Script.sh +- unattended_pivpn.conf + +For details, please check our documentation and dietpi.txt itself: +https://dietpi.com/docs/usage/#how-to-do-an-automatic-base-installation-at-first-boot-dietpi-automation _EOF_ G_EXEC umount "$root_mountpoint" "$fat_mountpoint" G_EXEC rmdir "$root_mountpoint" "$fat_mountpoint" diff --git a/rootfs/var/lib/dietpi/services/fs_partition_resize.sh b/rootfs/var/lib/dietpi/services/fs_partition_resize.sh index 5640c5142e..abc554bfca 100755 --- a/rootfs/var/lib/dietpi/services/fs_partition_resize.sh +++ b/rootfs/var/lib/dietpi/services/fs_partition_resize.sh @@ -2,6 +2,7 @@ { # Error out on command failures set -e + EXIT_CODE=0 Reboot_to_load_Partition_table() { @@ -41,6 +42,7 @@ echo "[ INFO ] Detected root drive $ROOT_DRIVE with root partition $ROOT_PART" # Check if the last partition contains a FAT filesystem with DIETPISETUP label + REBOOT=0 LAST_PART=$(lsblk -nrbo FSTYPE,LABEL "$ROOT_DRIVE" | tail -1) if [[ $LAST_PART == 'vfat DIETPISETUP' ]] then @@ -49,9 +51,20 @@ # Mount it and copy files if present and newer TMP_MOUNT=$(mktemp -d) mount -v "$SETUP_PART" "$TMP_MOUNT" - for f in 'dietpi.txt' 'dietpi-wifi.txt' 'dietpiEnv.txt' 'unattended_pivpn.conf' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' + for f in 'dietpi.txt' 'dietpi-wifi.txt' 'dietpiEnv.txt' 'boot.ini' 'extlinux.conf' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' 'unattended_pivpn.conf' do - [[ -f $TMP_MOUNT/$f ]] && cp -uv "$TMP_MOUNT/$f" /boot/ + [[ -f $TMP_MOUNT/$f ]] || continue + if [[ $f == 'extlinux.conf' ]] + then + mkdir -pv /boot/extlinux + [[ -f '/boot/extlinux/extlinux.conf' ]] && mtime=$(date -r '/boot/extlinux/extlinux.conf' '+%s') || mtime=0 + cp -uv "$TMP_MOUNT/$f" /boot/extlinux/ + (( $(date -r '/boot/extlinux/extlinux.conf' '+%s') > $mtime )) && REBOOT=1 + else + [[ ( $f == 'dietpiEnv.txt' || $f == 'boot.ini' ) && -f /boot/$f ]] && mtime=$(date -r "/boot/$f" '+%s') || mtime=0 + cp -uv "$TMP_MOUNT/$f" /boot/ + [[ $f == 'dietpiEnv.txt' || $f == 'boot.ini' ]] && (( $(date -r "/boot/$f" '+%s') '+%s') > $mtime )) && REBOOT=1 + fi done umount -v "$SETUP_PART" rmdir -v "$TMP_MOUNT" @@ -65,7 +78,7 @@ # Mount it and copy files if present and newer TMP_MOUNT=$(mktemp -d) mount -v "$BOOT_PART" "$TMP_MOUNT" - for f in 'dietpi.txt' 'dietpi-wifi.txt' 'dietpiEnv.txt' 'unattended_pivpn.conf' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' + for f in 'dietpi.txt' 'dietpi-wifi.txt' 'Automation_Custom_PreScript.sh' 'Automation_Custom_Script.sh' 'unattended_pivpn.conf' do [[ -f $TMP_MOUNT/$f ]] && cp -uv "$TMP_MOUNT/$f" /boot/ done @@ -113,9 +126,12 @@ 'btrfs') btrfs filesystem resize max /;; *) echo "[FAILED] Unsupported root filesystem type ($ROOT_FSTYPE). Aborting..." - exit 1 + EXIT_CODE=1 ;; esac - exit 0 + # Reboot if needed + (( $REBOOT )) && reboot + + exit "$EXIT_CODE" } From e5e8e60c9b32df85b32bb7a88e054d3f05348b5c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 12 May 2024 16:44:24 +0200 Subject: [PATCH 226/266] v9.4 - DietPi-FS_partition_resize | Typo --- rootfs/var/lib/dietpi/services/fs_partition_resize.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rootfs/var/lib/dietpi/services/fs_partition_resize.sh b/rootfs/var/lib/dietpi/services/fs_partition_resize.sh index abc554bfca..f99f7d913f 100755 --- a/rootfs/var/lib/dietpi/services/fs_partition_resize.sh +++ b/rootfs/var/lib/dietpi/services/fs_partition_resize.sh @@ -63,7 +63,7 @@ else [[ ( $f == 'dietpiEnv.txt' || $f == 'boot.ini' ) && -f /boot/$f ]] && mtime=$(date -r "/boot/$f" '+%s') || mtime=0 cp -uv "$TMP_MOUNT/$f" /boot/ - [[ $f == 'dietpiEnv.txt' || $f == 'boot.ini' ]] && (( $(date -r "/boot/$f" '+%s') '+%s') > $mtime )) && REBOOT=1 + [[ $f == 'dietpiEnv.txt' || $f == 'boot.ini' ]] && (( $(date -r "/boot/$f" '+%s') > $mtime )) && REBOOT=1 fi done umount -v "$SETUP_PART" From 61a24e354b09c1aaeb527432ade96a91a4faf476 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 12 May 2024 21:46:59 +0200 Subject: [PATCH 227/266] v9.4 - Orange Pi 5 Plus | Resolved an issue where the Ethernet interface names eth0/eth1 could swap on (re)boot. We add a udev rule which assures they are named persistently based on the PCI bus identifier. In case you created own udev rules to mitigate the issue, please check whether they conflict and decide whether to use ours or your solution. The DietPi update will also inform you about this change with a prompt. Many thanks to @dirkhh and many others for reporting this issue: https://github.com/MichaIng/DietPi/issues/6592 --- .build/images/dietpi-installer | 9 +++++++++ .update/patches | 13 +++++++++++++ CHANGELOG.txt | 1 + 3 files changed, 23 insertions(+) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 4eb8b9588a..440f046afd 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -2171,6 +2171,15 @@ _EOF_ SUBSYSTEM=="leds", KERNEL=="wan_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth0", RUN+="/bin/ip l s down dev eth0" SUBSYSTEM=="leds", KERNEL=="lan1_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="eth1", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev eth1", RUN+="/bin/ip l s down dev eth1" SUBSYSTEM=="leds", KERNEL=="user_led", ACTION=="add", ATTR{trigger}="netdev", ATTR{device_name}="wlan0", ATTR{link}="1", ATTR{rx}="1", ATTR{tx}="1", RUN+="/bin/ip l s up dev wlan0", RUN+="/bin/ip l s down dev wlan0" +_EOF_ + # Orange Pi 5 Plus + elif (( $G_HW_MODEL == 82 )) + then + G_DIETPI-NOTIFY 2 'Assuring persistent classic Ethernet interface names: /etc/udev/rules.d/99-dietpi-orangepi5plus.rules' + cat << '_EOF_' > /etc/udev/rules.d/99-dietpi-orangepi5plus.rules +SUBSYSTEM=="net", KERNEL=="eth0", KERNELS=="0004:41:00.0", RUN:="/bin/true" +SUBSYSTEM=="net", KERNEL=="eth1", KERNELS=="0003:31:00.0", NAME="to_eth0", RUN:="/bin/true" +SUBSYSTEM=="net", KERNEL=="to_eth0", RUN="/bin/ip l s dev eth0 name eth1", RUN+="/bin/ip l s dev to_eth0 name eth0", RUN+="/bin/udevadm trigger -c add /sys/class/net/eth0 /sys/class/net/eth1" _EOF_ # Orange Pi 3B/Zero 3/Zero 2W: Module does not load automatically, but we want it loaded on first boot in case firstrun setup is done via WiFi elif [[ $G_HW_MODEL =~ ^(83|87|88)$ ]] diff --git a/.update/patches b/.update/patches index 2fa977e1d3..b3ddc055e3 100755 --- a/.update/patches +++ b/.update/patches @@ -1582,6 +1582,19 @@ Patch_9_4() [[ -f '/etc/modprobe.d/odroid-cloudshell.conf' ]] && G_EXEC rm /etc/modprobe.d/odroid-cloudshell.conf G_EXEC sed --follow-symlinks -Ei '/^[[:blank:]]*(gpioplug-ir-recv|fbtft_device)[[:blank:]]*$/d' /etc/modules + # Orange Pi 5 Plus + elif (( $G_HW_MODEL == 82 )) + then + G_DIETPI-NOTIFY 2 'Assuring persistent classic Ethernet interface names: /etc/udev/rules.d/99-dietpi-orangepi5plus.rules' + G_WHIP_MSG '[ WARN ] Persistent eth0/eth1 interface names will be applied +\nSince classic interface names are randomly applied among the two onboard Ethernet adapters, we install a udev rule, which assures they remain the same on each (re)boot: +- /etc/udev/rules.d/99-dietpi-orangepi5plus.rules +\nIf you applied an own workaround via /etc/network/interfaces or similar, this will not be affected. But if you created own udev rules to mitigate the issue, please check whether those conflict with ours. Of course you can remove or rename above file to maintain status quo.' + cat << '_EOF_' > /etc/udev/rules.d/99-dietpi-orangepi5plus.rules +SUBSYSTEM=="net", KERNEL=="eth0", KERNELS=="0004:41:00.0", RUN:="/bin/true" +SUBSYSTEM=="net", KERNEL=="eth1", KERNELS=="0003:31:00.0", NAME="to_eth0", RUN:="/bin/true" +SUBSYSTEM=="net", KERNEL=="to_eth0", RUN="/bin/ip l s dev eth0 name eth1", RUN+="/bin/ip l s dev to_eth0 name eth0", RUN+="/bin/udevadm trigger -c add /sys/class/net/eth0 /sys/class/net/eth1" +_EOF_ # Orange Pi Zero 3 1.5 GiB RAM: Fix lost Ethernet adapter on reboot: https://github.com/MichaIng/DietPi/issues/6938 elif (( $G_HW_MODEL == 83 )) && dpkg-query -s 'linux-u-boot-orangepizero3-next' &> /dev/null then diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 3d0024d5e9..7f28936e8c 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -19,6 +19,7 @@ Enhancements: Bug fixes: - NanoPi NEO3 | Resolved an issue where the Ethernet adapter was not available after reboots. Many thanks to @murraythegoz for reporting this issue: https://github.com/MichaIng/DietPi/issues/6987 - Orange Pi Zero 3 | Resolved an issue on the 1.5 GiB RAM variant, where the Ethernet adapter was not available anymore after soft/warm reboots. +- Orange Pi 5 Plus | Resolved an issue where the Ethernet interface names eth0/eth1 could swap on (re)boot. We add a udev rule which assures they are named persistently based on the PCI bus identifier. In case you created own udev rules to mitigate the issue, please check whether they conflict and decide whether to use ours or your solution. The DietPi update will also inform you about this change with a prompt. Many thanks to @dirkhh and many others for reporting this issue: https://github.com/MichaIng/DietPi/issues/6592 - DietPi-VPN | Resolved an issue where installing the IPVanish config failed, due to a changed URL, and startup failed on Bookworm systems since their configs contain a deprecated option. Many thanks to @DreamPhreak and @Michael-Robson for reporting this issue: https://github.com/MichaIng/DietPi/issues/7043 - DietPi-Imager | Resolved an issue where the imager could have failed on GPT partitioned images, if either the source image size did not leave space for the GPT backup partition table, or the first usable LBA/sector was above 34. The GPT backup partition table is now created only at the end of the image generation, not anymore additionally at the start, and the required size it takes is correctly obtained. Many thanks to @SelfhostedPro and @disablewong for reporting this issue: https://github.com/MichaIng/DietPi/issues/7024, https://dietpi.com/forum/t/18035 - DietPi-Config | Resolved a visual-only failure message on non-RPi systems, when enabling Bluetooth, and an actual failure doing so on Orange Pi Zero 3, Orange Pi 3B and Orange Pi Zero 2W, since the required kernel module "sprdbt_tty" was not loaded. Many thanks to @b9AcE for reporting this issue: https://dietpi.com/forum/t/19929/45 From ede03b1a04cc912b702ef8688fa4d955d715b074 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 12 May 2024 21:51:23 +0200 Subject: [PATCH 228/266] v9.4 - CHANGELOG | Update release date --- CHANGELOG.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 7f28936e8c..e6e8a1cdfc 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,5 +1,5 @@ v9.4 -(2024-05-11) +(2024-05-12) New images: - ROCK 4C Plus | Since our Radxa ROCK 4 image has become incompatible with the ROCK 4C Plus, we provide a new image for this particular variant. Many thanks to @lfiorini and @arpegius5555 for reporting this issue: https://github.com/MichaIng/DietPi/issues/6593, https://github.com/MichaIng/DietPi/issues/6935 From 92fc5e17a340fcd850b654250720dad1751feb10 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 12 May 2024 22:00:40 +0200 Subject: [PATCH 229/266] v9.4 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 47060c7dae..7a315c4a76 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9512,7 +9512,7 @@ _EOF_ esac url=$(curl -sSfL 'https://api.github.com/repos/Radarr/Radarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}") - local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.4.6.8723/Radarr.master.5.4.6.8723.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.5.3.8819/Radarr.master.5.5.3.8819.linux-core-$arch.tar.gz" fi Download_Install "$url" @@ -9955,7 +9955,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.16.2.4435/Prowlarr.master.1.16.2.4435.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.17.2.4511/Prowlarr.master.1.17.2.4511.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Prowlarr/Prowlarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC mv Prowlarr /opt/prowlarr fi From 522409fe7ad6cfd596042abb0c5e82e766730dd0 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 12 May 2024 22:43:56 +0200 Subject: [PATCH 230/266] v9.4 - DietPi-Imager | Strangely, touch -t '197001010000' on the FAT filesystem leads to a 1980 timestamp, while only 197001010001 on the ext4 197001010001 gave the intended 1970 timestamp, sadly just older, so all configs were copied, even when not edited. I wasn't able to replicate locally when running these commands on a FAT filesytem file, but let's try with a more recent year, and a positive second in both cases. --- .build/images/dietpi-imager | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.build/images/dietpi-imager b/.build/images/dietpi-imager index c830d408a5..f4a4aaff46 100755 --- a/.build/images/dietpi-imager +++ b/.build/images/dietpi-imager @@ -565,8 +565,8 @@ do [[ -f $root_mountpoint/boot/$f ]] || continue G_EXEC cp "$root_mountpoint/boot/$f" "$fat_mountpoint/" - TZ=UTC G_EXEC touch -t '197001010000' "$fat_mountpoint/${f#extlinux/}" - TZ=UTC G_EXEC touch -t '197001010001' "$root_mountpoint/boot/$f" + TZ=UTC G_EXEC touch -t '202101010001' "$fat_mountpoint/${f#extlinux/}" + TZ=UTC G_EXEC touch -t '202101010002' "$root_mountpoint/boot/$f" done cat << '_EOF_' > "$fat_mountpoint/README.txt" DietPi config partition From bfd271b25e7e82cec000b4263e6d0fa0a0f77b9d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 13 May 2024 14:24:40 +0200 Subject: [PATCH 231/266] v9.5 - DietPi-Build | Raise initial rootfs size for some SBCs --- .build/images/dietpi-build | 22 +++++++++++----------- dietpi/dietpi-software | 2 +- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index c13fbf7041..862621668e 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -95,26 +95,26 @@ case $HW_MODEL in 45) iname='PINEH64' HW_ARCH=3 partition_start=4 root_size=1020;; 46) iname='PinebookPro' HW_ARCH=3 partition_start=16 root_size=1008;; 47) iname='NanoPiR4S' HW_ARCH=3 partition_start=16 root_size=1008;; - 48) iname='NanoPiR1' HW_ARCH=2 partition_start=4 root_size=764;; + 48) iname='NanoPiR1' HW_ARCH=2 partition_start=4 root_size=800;; '49.1') iname='Quartz64A' HW_ARCH=3 partition_start=16 root_size=752;; '49.2') iname='Quartz64B' HW_ARCH=3 partition_start=16 root_size=752;; '49.3') iname='SOQuartz' HW_ARCH=3 partition_start=16 root_size=752;; 52) iname='ASUSTB' HW_ARCH=2 partition_start=4 root_size=764;; 54) iname='NanoPiK2' HW_ARCH=3 partition_start=4 root_size=1148;; 55) iname='NanoPiR2S' HW_ARCH=3 partition_start=16 root_size=1008;; - 56) iname='NanoPiNEO3' HW_ARCH=3 partition_start=16 root_size=1008;; - 57) iname='NanoPiNEOPlus2' HW_ARCH=3 partition_start=4 root_size=892;; + 56) iname='NanoPiNEO3' HW_ARCH=3 partition_start=16 root_size=1100;; + 57) iname='NanoPiNEOPlus2' HW_ARCH=3 partition_start=4 root_size=1000;; 58) iname='NanoPiM4V2' HW_ARCH=3 partition_start=16 root_size=1008;; - 59) iname='ZeroPi' HW_ARCH=2 partition_start=4 root_size=764;; - 60) iname='NanoPiNEO' HW_ARCH=2 partition_start=4 root_size=764;; + 59) iname='ZeroPi' HW_ARCH=2 partition_start=4 root_size=800;; + 60) iname='NanoPiNEO' HW_ARCH=2 partition_start=4 root_size=800;; 61) iname='NanoPiM2' HW_ARCH=2 partition_start=4 boot_size=64 root_size=700 boot_fstype='ext4';; - '62.1') iname='NanoPiM3' HW_ARCH=3 partition_start=4 root_size=700;; - '62.2') iname='NanoPiFire3' HW_ARCH=3 partition_start=4 root_size=700;; - 63) iname='NanoPiM1' HW_ARCH=2 partition_start=4 root_size=764;; - 64) iname='NanoPiNEOAir' HW_ARCH=2 partition_start=4 root_size=764;; + '62.1') iname='NanoPiM3' HW_ARCH=3 partition_start=4 root_size=800;; + '62.2') iname='NanoPiFire3' HW_ARCH=3 partition_start=4 root_size=800;; + 63) iname='NanoPiM1' HW_ARCH=2 partition_start=4 root_size=800;; + 64) iname='NanoPiNEOAir' HW_ARCH=2 partition_start=4 root_size=800;; '65.1') iname='NanoPiNEO2' HW_ARCH=3 partition_start=4 root_size=1020;; '65.2') iname='NanoPiNEO2Black' HW_ARCH=3 partition_start=4 root_size=1020;; - 66) iname='NanoPiM1Plus' HW_ARCH=2 partition_start=4 root_size=764;; + 66) iname='NanoPiM1Plus' HW_ARCH=2 partition_start=4 root_size=800;; 67) iname='NanoPiK1Plus' HW_ARCH=3 partition_start=4 root_size=1020;; '68.1') iname='NanoPiM4' HW_ARCH=3 partition_start=16 root_size=1008;; '68.2') iname='NanoPCT4' HW_ARCH=3 partition_start=16 root_size=1008;; @@ -142,7 +142,7 @@ case $HW_MODEL in 86) iname='ASUSTB2' HW_ARCH=3 partition_start=16 root_size=1008;; 87) iname='OrangePi3B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; 88) iname='OrangePiZero2W' HW_ARCH=3 partition_start=4 root_size=1148;; - 89) iname='OrangePi3LTS' HW_ARCH=3 partition_start=4 root_size=892;; + 89) iname='OrangePi3LTS' HW_ARCH=3 partition_start=4 root_size=1000;; 90) iname='RadxaZERO3' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;; *) G_DIETPI-NOTIFY 1 "Invalid hardware model \"$HW_MODEL\" passed, aborting..."; exit 1;; esac diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 7a315c4a76..616fe60c3b 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6209,7 +6209,7 @@ _EOF_ *) local arch='amd64';; esac - local fallback_url="https://github.com/navidrome/navidrome/releases/download/v0.52.0/navidrome_0.52.0_linux_$arch.tar.gz" + local fallback_url="https://github.com/navidrome/navidrome/releases/download/v0.52.5/navidrome_0.52.5_linux_$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/navidrome/navidrome/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/navidrome_[0-9.]*_linux_$arch\.tar\.gz\"$/{print \$4}")" /opt/navidrome # Data dir From 1eb7e2eff217a009b5c7420fe09973fa64c09b9e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 13 May 2024 15:52:02 +0200 Subject: [PATCH 232/266] v9.5 - CI | Armbian: Remove vendor-boogie-panthor branch, removed upstream, while the Panthor driver can be enabled via device tree overlay and loading a kernel module --- .github/workflows/armbian.yml | 2 +- dietpi/dietpi-software | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index ab86ec4f0c..318ac9ddec 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -11,7 +11,7 @@ on: branch: description: 'Branch' type: choice - options: [legacy, current, edge, vendor, vendor-boogie-panthor, collabora] + options: [legacy, current, edge, vendor, collabora] default: current required: true board: diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 616fe60c3b..8c91fcae98 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10030,7 +10030,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.25.2515/Readarr.develop.0.3.25.2515.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.3.27.2538/Readarr.develop.0.3.27.2538.linux-core-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Readarr/Readarr/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}" | head -1)" G_EXEC mv Readarr /opt/readarr fi From c806e94af0f0b18ce116137433066b76d27de62c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 13 May 2024 18:06:48 +0200 Subject: [PATCH 233/266] v9.4 - CI | Armbian: Fix U-Boot package name when checking current version suffix --- .github/workflows/armbian.yml | 2 +- dietpi/dietpi-software | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 318ac9ddec..40d6c81fc3 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -71,7 +71,7 @@ jobs: read -r version < VERSION case '${{ github.event.inputs.asset }}' in firmware) package='armbian-firmware';; - uboot) package='linux-uboot-${{ github.event.inputs.board }}-${{ github.event.inputs.board }}';; + uboot) package='linux-uboot-${{ github.event.inputs.board }}-${{ github.event.inputs.branch }}';; kernel) family=$(. 'config/boards/${{ github.event.inputs.board }}.'* &> /dev/null; echo "$BOARDFAMILY") echo "Board family is: $family" diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 8c91fcae98..3ed7abb5da 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9609,7 +9609,7 @@ _EOF_ esac url=$(curl -sSfL 'https://api.github.com/repos/Lidarr/Lidarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}") - local fallback_url="https://github.com/Lidarr/Lidarr/releases/download/v2.2.5.4141/Lidarr.master.2.2.5.4141.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Lidarr/Lidarr/releases/download/v2.3.3.4204/Lidarr.master.2.3.3.4204.linux-core-$arch.tar.gz" fi Download_Install "$url" From da7af8e0271792b2e2cf51b0e56fc0107c6ee3e0 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 13 May 2024 19:58:37 +0200 Subject: [PATCH 234/266] v9.5 - DietPi-Config | Resolved an issue where Advanced Options were not accessible on some SBCs. Many thanks to @thuehlinger for reporting this issue: https://github.com/MichaIng/DietPi/issues/6663#issuecomment-2108351878 --- CHANGELOG.txt | 10 ++++++++++ dietpi/dietpi-config | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index e6e8a1cdfc..fc5f8740c1 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,3 +1,13 @@ +v9.5 +(2024-06-08) + +Bug fixes: +- DietPi-Config | Resolved an issue where Advanced Options were not accessible on some SBCs. Many thanks to @thuehlinger for reporting this issue: https://github.com/MichaIng/DietPi/issues/6663#issuecomment-2108351878 + +As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME + +----------------------------------------------------------------------------------------------------------- + v9.4 (2024-05-12) diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index f97fc96d59..a050f0f399 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -1077,7 +1077,7 @@ Re-enabling HDMI requires a reboot. If you need emergency HDMI output, edit the { [[ -e '/dev/mtd0' ]] && grep -q '/dev/mtd0' /usr/lib/u-boot/platform_install.sh && spidev='/dev/mtd0'; } || { [[ -b '/dev/mtdblock0' ]] && grep -q 'rksd_loader.img' /usr/lib/u-boot/platform_install.sh; } } - } && G_WHIP_MENU_ARRAY+=("Update SPI bootloader' ': Flash current U-Boot to $spidev") + } && G_WHIP_MENU_ARRAY+=('Update SPI bootloader' ": Flash current U-Boot to $spidev") # VisionFive 2/Star64: https://doc-en.rvspace.org/VisionFive2/PDF/VisionFive2_QSG.pdf elif (( $G_HW_MODEL == 81 || $G_HW_MODEL == 84 )) From b13c6731a1d01bb3d9179f26da1cd02dea1a9b28 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 13 May 2024 20:27:01 +0200 Subject: [PATCH 235/266] Live patch 0 v9.4 (#7070) - Live patch 0 | Fix dietpi-config Advanced Options for some SBCs --- .update/version | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.update/version b/.update/version index 9e903dac26..d2d5b4feea 100644 --- a/.update/version +++ b/.update/version @@ -14,6 +14,7 @@ G_MIN_DEBIAN=6 # Alternative Git branch to automatically migrate to when Debian version is too low G_OLD_DEBIAN_BRANCH='8' # Live patches -G_LIVE_PATCH_DESC=() -G_LIVE_PATCH_COND=() -G_LIVE_PATCH=() +G_LIVE_PATCH_DESC=('Fix dietpi-config Advanced Options for some SBCs') +# shellcheck disable=SC2016 +G_LIVE_PATCH_COND=('[[ $G_HW_MODEL =~ ^(78|80|82|87)$ ]]') +G_LIVE_PATCH=("sed -i 's/\"Update SPI bootloader'\'' '\''/'\''Update SPI bootloader'\'' \"/' /boot/dietpi/dietpi-config") From 412b4d721b9e8e5c7dd4fe7a427864c29f624475 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 13 May 2024 20:28:31 +0200 Subject: [PATCH 236/266] v9.5 - META | Remove live patches merged from master --- .update/version | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.update/version b/.update/version index d2d5b4feea..9e903dac26 100644 --- a/.update/version +++ b/.update/version @@ -14,7 +14,6 @@ G_MIN_DEBIAN=6 # Alternative Git branch to automatically migrate to when Debian version is too low G_OLD_DEBIAN_BRANCH='8' # Live patches -G_LIVE_PATCH_DESC=('Fix dietpi-config Advanced Options for some SBCs') -# shellcheck disable=SC2016 -G_LIVE_PATCH_COND=('[[ $G_HW_MODEL =~ ^(78|80|82|87)$ ]]') -G_LIVE_PATCH=("sed -i 's/\"Update SPI bootloader'\'' '\''/'\''Update SPI bootloader'\'' \"/' /boot/dietpi/dietpi-config") +G_LIVE_PATCH_DESC=() +G_LIVE_PATCH_COND=() +G_LIVE_PATCH=() From 6a57c8a5efae8a8da99ae57875c623265c58293d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 14 May 2024 02:27:35 +0200 Subject: [PATCH 237/266] v9.5 - DietPi-Software | MPD: Update flag on Bookworm and above: https://github.com/MusicPlayerDaemon/MPD/commit/ce77b14 --- .update/patches | 6 ++++++ dietpi/dietpi-software | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index b3ddc055e3..8141d49e2f 100755 --- a/.update/patches +++ b/.update/patches @@ -1629,6 +1629,12 @@ _EOF_ fi } +Patch_9_5() +{ + # Update MPD flag on Bookworm and above: https://github.com/MusicPlayerDaemon/MPD/commit/ce77b14 + (( $G_DISTRO > 6 )) && [[ -f '/etc/systemd/system/mpd.service.d/dietpi.conf' ]] && G_EXEC sed -i 's/no-daemon/systemd/' /etc/systemd/system/mpd.service.d/dietpi.conf +} + # v6.35 => v7 migration if (( $G_DIETPI_VERSION_CORE == 6 && $G_DIETPI_VERSION_SUB > 34 )) then diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 3ed7abb5da..eab06b1e28 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -4027,8 +4027,9 @@ User=mpd RuntimeDirectory=mpd EnvironmentFile= ExecStart= -ExecStart=/usr/bin/mpd --no-daemon +ExecStart=/usr/bin/mpd --systemd _EOF_ + (( $G_DISTRO < 7 )) && G_EXEC sed -i 's/systemd/no-daemon/' /etc/systemd/system/mpd.service.d/dietpi.conf Remove_SysV mpd 1 # Config From 2b34d7795d2a95e20e9f203295532bbd5e571e2d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 14 May 2024 18:28:13 +0200 Subject: [PATCH 238/266] v9.5 - DietPi-Software | Snapcast Server: Resolved on issue where on RISC-V systems, the web interface was not available, since it is not included in the "snapserver" package from Debian. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index fc5f8740c1..d19d37cedf 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -3,6 +3,7 @@ v9.5 Bug fixes: - DietPi-Config | Resolved an issue where Advanced Options were not accessible on some SBCs. Many thanks to @thuehlinger for reporting this issue: https://github.com/MichaIng/DietPi/issues/6663#issuecomment-2108351878 +- DietPi-Software | Snapcast Server: Resolved on issue where on RISC-V systems, the web interface was not available, since it is not included in the "snapserver" package from Debian. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index eab06b1e28..9fae80dda8 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11510,8 +11510,10 @@ _EOF_ then G_AGI snapserver - # Enable web UI to align with upstream package - G_CONFIG_INJECT 'doc_root[[:blank:]=]' 'doc_root = /usr/share/snapserver/snapweb' /etc/snapserver.conf '\[http\]' + # Install and enable snapweb web UI, not included in Debian's snapserver package: https://github.com/MichaIng/DietPi/issues/7073 + local fallback_url='https://github.com/badaix/snapweb/releases/download/v0.7.0/snapweb_0.7.0-1_all.deb' + Download_Install "$(curl -sSfL 'https://api.github.com/repos/badaix/snapweb/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/snapweb_[^"\/]*_all.deb"/{print $4}')" + G_CONFIG_INJECT 'doc_root[[:blank:]=]' 'doc_root = /usr/share/snapweb' /etc/snapserver.conf '\[http\]' else local arch=$(dpkg --print-architecture) dist=${G_DISTRO_NAME/trixie/bookworm} local fallback_url="https://github.com/badaix/snapcast/releases/download/v0.28.0/snapcast_0.28.0_$arch-debian-$dist.zip" From 00912190e5cc673a3c1baa6435d86b36d15d0ce6 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 14 May 2024 19:13:34 +0200 Subject: [PATCH 239/266] v9.5 - DietPi-Software | Snapcast Server: Resolved an issue where on Bookworm systems, which installed the Snapcast Server before DietPi v9.4 and reinstalled it afterwards, the server failed to start due to a permissions issue, since the services of both packages use different users. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 11 +++++++++++ 2 files changed, 12 insertions(+) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index d19d37cedf..b045e5aba0 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -4,6 +4,7 @@ v9.5 Bug fixes: - DietPi-Config | Resolved an issue where Advanced Options were not accessible on some SBCs. Many thanks to @thuehlinger for reporting this issue: https://github.com/MichaIng/DietPi/issues/6663#issuecomment-2108351878 - DietPi-Software | Snapcast Server: Resolved on issue where on RISC-V systems, the web interface was not available, since it is not included in the "snapserver" package from Debian. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 +- DietPi-Software | Snapcast Server: Resolved an issue where on Bookworm systems, which installed the Snapcast Server before DietPi v9.4 and reinstalled it afterwards, the server failed to start due to a permissions issue, since the services of both packages use different users. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 9fae80dda8..38e34501ae 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11514,12 +11514,20 @@ _EOF_ local fallback_url='https://github.com/badaix/snapweb/releases/download/v0.7.0/snapweb_0.7.0-1_all.deb' Download_Install "$(curl -sSfL 'https://api.github.com/repos/badaix/snapweb/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/snapweb_[^"\/]*_all.deb"/{print $4}')" G_CONFIG_INJECT 'doc_root[[:blank:]=]' 'doc_root = /usr/share/snapweb' /etc/snapserver.conf '\[http\]' + + # Fix /var/lib/snapserver permissions, just in case badaix's package was previously used, which uses the "snapserver" user, instead of "_snapserver" + [[ -d '/var/lib/snapserver' ]] && G_EXEC chown -R '_snapserver:_snapserver' /var/lib/snapserver + getent passwd snapserver > /dev/null && G_EXEC userdel snapserver else local arch=$(dpkg --print-architecture) dist=${G_DISTRO_NAME/trixie/bookworm} local fallback_url="https://github.com/badaix/snapcast/releases/download/v0.28.0/snapcast_0.28.0_$arch-debian-$dist.zip" Download_Install "$(curl -sSfL 'https://api.github.com/repos/badaix/snapcast/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/snapcast_[^\"\/]*_$arch-debian-$dist.zip\"/{print \$4}")" G_AGI ./snapserver_*_"$arch.deb" G_EXEC rm snap*.deb + + # Fix /var/lib/snapserver permissions, just in case Debian's package was previously used, which uses the "_snapserver" user, instead of "snapserver" + [[ -d '/var/lib/snapserver' ]] && G_EXEC chown -R 'snapserver:snapserver' /var/lib/snapserver + getent passwd _snapserver > /dev/null && G_EXEC userdel _snapserver fi G_EXEC systemctl stop snapserver @@ -14089,6 +14097,9 @@ _EOF_ if To_Uninstall 191 # Snapcast Server then G_AGP snapserver + # Remove users from Debian's and badaix's packages, to cleanly cover upgrades from one to the other. + getent passwd snapserver > /dev/null && G_EXEC userdel snapserver + getent passwd _snapserver > /dev/null && G_EXEC userdel _snapserver fi if To_Uninstall 192 # Snapcast Client From 34e76c4f9e95bb65554acf17aeea7cb0178bdc12 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 14 May 2024 19:27:38 +0200 Subject: [PATCH 240/266] v9.5 - DietPi-Software | Radarr: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 38e34501ae..536241238b 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9513,7 +9513,7 @@ _EOF_ esac url=$(curl -sSfL 'https://api.github.com/repos/Radarr/Radarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-core-$arch\.tar\.gz\"$/{print \$4}") - local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.5.3.8819/Radarr.master.5.5.3.8819.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.6.0.8846/Radarr.master.5.6.0.8846.linux-core-$arch.tar.gz" fi Download_Install "$url" From 237fdda2a024381854b980dff84dd34b171a3086 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 14 May 2024 19:30:02 +0200 Subject: [PATCH 241/266] v9.5 - CI | Switch all workflows to Ubuntu Noble: https://github.com/actions/runner-images/issues/9848 --- .github/workflows/amiberry.yml | 4 ++-- .github/workflows/armbian.yml | 2 +- .github/workflows/dietpi-build.yml | 4 ++-- .github/workflows/dietpi-software-build.yml | 4 ++-- .github/workflows/dietpi-software.yml | 4 ++-- .github/workflows/quartz64.yml | 2 +- .github/workflows/raspberrypi-sys-mods.yml | 2 +- .github/workflows/shellcheck.yml | 2 +- 8 files changed, 12 insertions(+), 12 deletions(-) diff --git a/.github/workflows/amiberry.yml b/.github/workflows/amiberry.yml index f23af7750c..e4439bc863 100644 --- a/.github/workflows/amiberry.yml +++ b/.github/workflows/amiberry.yml @@ -25,7 +25,7 @@ jobs: plat: ${{ steps.plat.outputs.plat }} dist: ${{ steps.dist.outputs.dist }} # https://github.com/actions/runner-images - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - id: plat run: | @@ -54,7 +54,7 @@ jobs: - { plat: riscv64, dist: bookworm } fail-fast: false name: "${{ matrix.plat }} - ${{ matrix.dist }}" - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - name: Build run: sudo bash -c "G_GITOWNER=$GITHUB_REPOSITORY_OWNER G_GITBRANCH=$GITHUB_REF_NAME; $(curl -sSf "https://raw.githubusercontent.com/$GITHUB_REPOSITORY_OWNER/DietPi/$GITHUB_REF_NAME/.build/software/Amiberry/container_build.bash")" -- -p '${{ matrix.plat }}' -d '${{ matrix.dist }}' diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index 40d6c81fc3..f2cf580a17 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -32,7 +32,7 @@ permissions: {} jobs: build: name: "${{ github.event.inputs.asset }} - ${{ github.event.inputs.branch }} - ${{ github.event.inputs.board }}" - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - name: Clone Armbian repo run: | diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index 273bc1a334..a7db44fb96 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -14,7 +14,7 @@ jobs: outputs: buildargs: ${{ steps.buildargs.outputs.buildargs }} # https://github.com/actions/runner-images - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - id: buildargs run: | @@ -116,7 +116,7 @@ jobs: buildargs: ${{ fromJson(needs.prep.outputs.buildargs) }} fail-fast: false name: "Build: ${{ matrix.buildargs }}" - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - name: Generate upload script run: | diff --git a/.github/workflows/dietpi-software-build.yml b/.github/workflows/dietpi-software-build.yml index 0570711301..29c7468126 100644 --- a/.github/workflows/dietpi-software-build.yml +++ b/.github/workflows/dietpi-software-build.yml @@ -31,7 +31,7 @@ jobs: arch: ${{ steps.arch.outputs.arch }} dist: ${{ steps.dist.outputs.dist }} # https://github.com/actions/runner-images - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - id: name run: | @@ -72,7 +72,7 @@ jobs: - { arch: x86_64, name: gogs } fail-fast: false name: "${{ matrix.name }} - ${{ matrix.arch }} - ${{ matrix.dist }}" - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - name: Build run: sudo bash -c "G_GITOWNER=$GITHUB_REPOSITORY_OWNER G_GITBRANCH=$GITHUB_REF_NAME; $(curl -sSf "https://raw.githubusercontent.com/$GITHUB_REPOSITORY_OWNER/DietPi/$GITHUB_REF_NAME/.build/software/dietpi-software-build.bash")" -- -n '${{ matrix.name }}' -a '${{ matrix.arch }}' -d '${{ matrix.dist }}' diff --git a/.github/workflows/dietpi-software.yml b/.github/workflows/dietpi-software.yml index d1419f9ea4..708964fb51 100644 --- a/.github/workflows/dietpi-software.yml +++ b/.github/workflows/dietpi-software.yml @@ -36,7 +36,7 @@ permissions: {} jobs: prep: # https://github.com/actions/runner-images - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - id: arch run: | @@ -68,7 +68,7 @@ jobs: - { arch: riscv64, dist: bookworm } fail-fast: false name: "${{ matrix.arch }} - ${{ matrix.dist }} - ${{ github.event.inputs.soft }}" - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - name: Install run: | diff --git a/.github/workflows/quartz64.yml b/.github/workflows/quartz64.yml index a176196e67..6d79b59235 100644 --- a/.github/workflows/quartz64.yml +++ b/.github/workflows/quartz64.yml @@ -7,7 +7,7 @@ permissions: {} jobs: build: # https://github.com/actions/runner-images - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 env: uboot_version: '2023.10' CROSS_COMPILE: 'aarch64-linux-gnu-' diff --git a/.github/workflows/raspberrypi-sys-mods.yml b/.github/workflows/raspberrypi-sys-mods.yml index 675e3af75e..67bfcdc9c7 100644 --- a/.github/workflows/raspberrypi-sys-mods.yml +++ b/.github/workflows/raspberrypi-sys-mods.yml @@ -7,7 +7,7 @@ permissions: {} jobs: build: # https://github.com/actions/runner-images - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - name: Build run: sudo bash -c "$(curl -sSf "https://raw.githubusercontent.com/$GITHUB_REPOSITORY_OWNER/DietPi/$GITHUB_REF_NAME/.build/software/raspberrypi-sys-mods/build.bash")" diff --git a/.github/workflows/shellcheck.yml b/.github/workflows/shellcheck.yml index 6ac2dba1c6..aed94c650c 100644 --- a/.github/workflows/shellcheck.yml +++ b/.github/workflows/shellcheck.yml @@ -9,7 +9,7 @@ jobs: shellcheck: if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.owner.login != github.event.pull_request.base.repo.owner.login # https://github.com/actions/runner-images - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 - name: Setup DietPi-Globals From e4c2818ff6d46097b78008f53a2927e6910a1c21 Mon Sep 17 00:00:00 2001 From: StephanStS Date: Thu, 16 May 2024 19:54:59 +0200 Subject: [PATCH 242/266] Init v9.5 (#7075) --- .meta/dietpi-survey_report | 3 ++- .update/version | 4 ++-- dietpi/func/dietpi-globals | 4 ++-- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index cb2c6a5599..01d059b89b 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -717,10 +717,11 @@ shopt -s extglob aSOFTWARE_NAME9_2[i]=${aSOFTWARE_NAME9_1[i]} aSOFTWARE_NAME9_3[i]=${aSOFTWARE_NAME9_2[i]} aSOFTWARE_NAME9_4[i]=${aSOFTWARE_NAME9_3[i]} + aSOFTWARE_NAME9_5[i]=${aSOFTWARE_NAME9_4[i]} done # Pre-create software counter array so that we can see also software (available in newest version) with 0 installs - for i in "${aSOFTWARE_NAME9_4[@]}" + for i in "${aSOFTWARE_NAME9_5[@]}" do aSOFTWARE[$i]=0 done diff --git a/.update/version b/.update/version index 9e903dac26..35605ae2d5 100644 --- a/.update/version +++ b/.update/version @@ -2,8 +2,8 @@ # shellcheck disable=SC2034 # Available DietPi version G_REMOTE_VERSION_CORE=9 -G_REMOTE_VERSION_SUB=4 -G_REMOTE_VERSION_RC=2 +G_REMOTE_VERSION_SUB=5 +G_REMOTE_VERSION_RC=-1 # Minimum DietPi version to allow update G_MIN_VERSION_CORE=7 G_MIN_VERSION_SUB=0 diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index d3bda29db1..29530bd360 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -54,8 +54,8 @@ [[ -f '/boot/dietpi/.version' ]] && . /boot/dietpi/.version # - Assign defaults/code version as fallback [[ $G_DIETPI_VERSION_CORE ]] || G_DIETPI_VERSION_CORE=9 - [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=4 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=2 + [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=5 + [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=-1 [[ $G_GITBRANCH ]] || G_GITBRANCH='master' [[ $G_GITOWNER ]] || G_GITOWNER='MichaIng' # - Save current version and Git branch From 46831b78825152eecc84079abe4b273e7f10be5b Mon Sep 17 00:00:00 2001 From: pulpe <45254364+pulpe@users.noreply.github.com> Date: Sat, 18 May 2024 22:01:49 +0200 Subject: [PATCH 243/266] v9.5 (#7082) - DietPi-Software | Shairport Sync: Resolved a DietPi v9.4 regression, where the AirPlay 2 choice did not have an effect, but the AirPlay 1 package was always installed. Additionally, uninstalling Shairport Sync will now also purge the AirPlay 2 package. Many thanks to @pulpe for fixing this bug: https://github.com/MichaIng/DietPi/pull/7082 --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index b045e5aba0..9b6a64a441 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -5,6 +5,7 @@ Bug fixes: - DietPi-Config | Resolved an issue where Advanced Options were not accessible on some SBCs. Many thanks to @thuehlinger for reporting this issue: https://github.com/MichaIng/DietPi/issues/6663#issuecomment-2108351878 - DietPi-Software | Snapcast Server: Resolved on issue where on RISC-V systems, the web interface was not available, since it is not included in the "snapserver" package from Debian. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 - DietPi-Software | Snapcast Server: Resolved an issue where on Bookworm systems, which installed the Snapcast Server before DietPi v9.4 and reinstalled it afterwards, the server failed to start due to a permissions issue, since the services of both packages use different users. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 +- DietPi-Software | Shairport Sync: Resolved a DietPi v9.4 regression, where the AirPlay 2 choice did not have an effect, but the AirPlay 1 package was always installed. Additionally, uninstalling Shairport Sync will now also purge the AirPlay 2 package. Many thanks to @pulpe for fixing this bug: https://github.com/MichaIng/DietPi/pull/7082 As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 536241238b..9a0e00f2d2 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8038,7 +8038,7 @@ _EOF_ airplay2= fi - G_AGI shairport-sync + G_AGI "shairport-sync$airplay2" G_EXEC systemctl stop shairport-sync fi @@ -12824,7 +12824,7 @@ If no WireGuard (auto)start is included, but you require it, please do the follo if To_Uninstall 37 # Shairport Sync then - G_AGP shairport-sync + G_AGP shairport-sync shairport-sync-airplay2 fi if To_Uninstall 152 # Avahi-Daemon From a310c548e1941ef06f863518f80ddb593245f669 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 18 May 2024 22:02:27 +0200 Subject: [PATCH 244/266] v9.5 - DietPi-Software | NZBGet: Update fallback URL --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 9a0e00f2d2..dc5d9ec0fc 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9876,7 +9876,7 @@ _EOF_ local reinstall=0 [[ -f '/mnt/dietpi_userdata/nzbget/nzbget.conf' ]] && reinstall=1 - local fallback_url='https://github.com/nzbgetcom/nzbget/releases/download/v24.0/nzbget-24.0-bin-linux.run' + local fallback_url='https://github.com/nzbgetcom/nzbget/releases/download/v24.1/nzbget-24.1-bin-linux.run' Download_Install "$(curl -sSfL 'https://api.github.com/repos/nzbgetcom/nzbget/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/nzbget-[^"/]*-bin-linux.run"$/{print $4}')" nzbget.run G_EXEC mkdir -p /mnt/dietpi_userdata/nzbget G_EXEC_OUTPUT=1 G_EXEC dash nzbget.run --destdir /mnt/dietpi_userdata/nzbget From 591087d3beaef9a9915c31623cc1d074e20caf92 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 19 May 2024 14:51:38 +0200 Subject: [PATCH 245/266] v9.5 - CI | Amiberry: Do ARMv8 Bullseye builds on Ubuntu Focal, since the QEMU version shipped with Noble runs into a segmentation fault, when configuring the libc-bin package, or just running its triggers. --- .github/workflows/amiberry.yml | 2 +- dietpi/dietpi-software | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/amiberry.yml b/.github/workflows/amiberry.yml index e4439bc863..e340482da7 100644 --- a/.github/workflows/amiberry.yml +++ b/.github/workflows/amiberry.yml @@ -54,7 +54,7 @@ jobs: - { plat: riscv64, dist: bookworm } fail-fast: false name: "${{ matrix.plat }} - ${{ matrix.dist }}" - runs-on: ubuntu-24.04 + runs-on: ${{ matrix.dist == 'bullseye' && ( endsWith(matrix.plat, '-64-sdl2') || matrix.plat == 'AMLSM1' || matrix.plat == 'n2' || matrix.plat == 'a64' || matrix.plat == 'rk3588' ) && 'ubuntu-22.04' || 'ubuntu-24.04' }} steps: - name: Build run: sudo bash -c "G_GITOWNER=$GITHUB_REPOSITORY_OWNER G_GITBRANCH=$GITHUB_REF_NAME; $(curl -sSf "https://raw.githubusercontent.com/$GITHUB_REPOSITORY_OWNER/DietPi/$GITHUB_REF_NAME/.build/software/Amiberry/container_build.bash")" -- -p '${{ matrix.plat }}' -d '${{ matrix.dist }}' diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index dc5d9ec0fc..b23c64cdff 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11721,7 +11721,7 @@ _EOF_ *) local arch='amd64';; esac - local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.29.0/linux-$arch-filebrowser.tar.gz" + local fallback_url="https://github.com/filebrowser/filebrowser/releases/download/v2.30.0/linux-$arch-filebrowser.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/filebrowser/filebrowser/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/linux-$arch-filebrowser\.tar\.gz\"$/{print \$4}")" ./filebrowser/ # Reinstall From f0d79c5d85cc87412e801f8176eb7fc41a93e3b8 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 20 May 2024 21:46:14 +0200 Subject: [PATCH 246/266] v9.5 - CI | Amiberry: Prevent dist-upgrade from within build script for ARMv6/7 Trixie builds, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. --- .build/software/Amiberry/build.bash | 8 +++++++- .build/software/Amiberry/container_build.bash | 2 +- .github/workflows/dietpi-software.bash | 2 +- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.build/software/Amiberry/build.bash b/.build/software/Amiberry/build.bash index 61379b0115..a0ea914359 100755 --- a/.build/software/Amiberry/build.bash +++ b/.build/software/Amiberry/build.bash @@ -18,7 +18,13 @@ adeps=('libdrm2' 'libgl1-mesa-dri' 'libgbm1' 'libegl1' 'libudev1' 'libxml2' 'lib (( $G_HW_ARCH == 10 )) && opengl_flags=('--disable-video-opengles2' '--enable-video-opengl') adeps_build+=('libgl1-mesa-dev') adeps+=('libgl1') || opengl_flags=('--enable-video-opengles2' '--disable-video-opengl') adeps_build+=('libgles2-mesa-dev') adeps+=('libgles2') G_AGUP -G_AGDUG "${adeps_build[@]}" +# ARMv6/7 Trixie: Temporarily prevent dist-upgrade, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. +if (( $G_HW_ARCH < 3 && $G_DISTRO == 8 )) +then + G_AGI "${adeps_build[@]}" +else + G_AGDUG "${adeps_build[@]}" +fi for i in "${adeps[@]}" do # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 diff --git a/.build/software/Amiberry/container_build.bash b/.build/software/Amiberry/container_build.bash index ef5063d4a9..358fca624a 100755 --- a/.build/software/Amiberry/container_build.bash +++ b/.build/software/Amiberry/container_build.bash @@ -137,7 +137,7 @@ Pin-Priority: -1 _EOF_ fi -# ARMv6/7 Trixie: Temporarily prevent dist-upgrade on Trixie, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. +# ARMv6/7 Trixie: Temporarily prevent dist-upgrade, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. (( $arch < 3 )) && [[ $DISTRO == 'trixie' ]] && G_EXEC touch rootfs/boot/dietpi/.skip_distro_upgrade # Automated build diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index 397e94220d..50465c80e5 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -368,7 +368,7 @@ G_EXEC eval 'echo -e '\''[Service]\nAmbientCapabilities='\'' > rootfs/etc/system # Workaround for sysctl: permission denied on key "net.core.rmem_max" in containers G_EXEC sed --follow-symlinks -i '/# Start DietPi-Software/a\sed -i '\''/G_EXEC sysctl -w net\.core\.rmem_max/d'\'' /boot/dietpi/dietpi-software' rootfs/boot/dietpi/dietpi-login -# ARMv6/7 Trixie: Temporarily prevent dist-upgrade on Trixie, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. +# ARMv6/7 Trixie: Temporarily prevent dist-upgrade, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. (( $arch < 3 )) && [[ $DISTRO == 'trixie' ]] && G_EXEC touch rootfs/boot/dietpi/.skip_distro_upgrade # Check for service status, ports and commands From 3ed3b5358053a43e2264a5796a19d30ae5342e8e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 20 May 2024 22:15:43 +0200 Subject: [PATCH 247/266] v9.5 - CI | Amiberry: Instead of preening the dist-upgrade, purge kmod (libkmod2), to prevent time_t transition package ocnflicts. It is not needed in containers anyway. Hopefully no build tries to call lsmod of similar. --- .build/software/Amiberry/build.bash | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/.build/software/Amiberry/build.bash b/.build/software/Amiberry/build.bash index a0ea914359..8d57c5729c 100755 --- a/.build/software/Amiberry/build.bash +++ b/.build/software/Amiberry/build.bash @@ -18,13 +18,9 @@ adeps=('libdrm2' 'libgl1-mesa-dri' 'libgbm1' 'libegl1' 'libudev1' 'libxml2' 'lib (( $G_HW_ARCH == 10 )) && opengl_flags=('--disable-video-opengles2' '--enable-video-opengl') adeps_build+=('libgl1-mesa-dev') adeps+=('libgl1') || opengl_flags=('--enable-video-opengles2' '--disable-video-opengl') adeps_build+=('libgles2-mesa-dev') adeps+=('libgles2') G_AGUP -# ARMv6/7 Trixie: Temporarily prevent dist-upgrade, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. -if (( $G_HW_ARCH < 3 && $G_DISTRO == 8 )) -then - G_AGI "${adeps_build[@]}" -else - G_AGDUG "${adeps_build[@]}" -fi +# ARMv6/7 Trixie: Temporarily purge kmod, since libkmod2 causes a dependency conflict due to 64-bit time_t transition. +(( $G_HW_ARCH < 3 && $G_DISTRO == 8 )) && G_AGP kmod +G_AGDUG "${adeps_build[@]}" for i in "${adeps[@]}" do # Temporarily allow lib*t64 packages, while the 64-bit time_t transition is ongoing on Sid: https://bugs.debian.org/1065394 From c6c30fc86bd52cedfdf6453f9306a2eb268e298e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 21 May 2024 00:35:05 +0200 Subject: [PATCH 248/266] v9.5 - CI | Amiberry: kmod is (reasonably) not installed on our contianer images. Not sure what keeps libkmod2 around, let's find it out. --- .build/software/Amiberry/build.bash | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.build/software/Amiberry/build.bash b/.build/software/Amiberry/build.bash index 8d57c5729c..9b4c39802a 100755 --- a/.build/software/Amiberry/build.bash +++ b/.build/software/Amiberry/build.bash @@ -18,8 +18,8 @@ adeps=('libdrm2' 'libgl1-mesa-dri' 'libgbm1' 'libegl1' 'libudev1' 'libxml2' 'lib (( $G_HW_ARCH == 10 )) && opengl_flags=('--disable-video-opengles2' '--enable-video-opengl') adeps_build+=('libgl1-mesa-dev') adeps+=('libgl1') || opengl_flags=('--enable-video-opengles2' '--disable-video-opengl') adeps_build+=('libgles2-mesa-dev') adeps+=('libgles2') G_AGUP -# ARMv6/7 Trixie: Temporarily purge kmod, since libkmod2 causes a dependency conflict due to 64-bit time_t transition. -(( $G_HW_ARCH < 3 && $G_DISTRO == 8 )) && G_AGP kmod +# ARMv6/7 Trixie: Temporarily purge libkmod2, since it causes a dependency conflict due to 64-bit time_t transition. +(( $G_HW_ARCH < 3 && $G_DISTRO == 8 )) && G_AGP libkmod2 G_AGDUG "${adeps_build[@]}" for i in "${adeps[@]}" do From ff1ae27fcad24c503c5ff7834d1208cc8686cab1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 21 May 2024 01:06:44 +0200 Subject: [PATCH 249/266] v9.5 - CI | Remove ARMv6/7 Trixie time_t migration relateted workaround. We ship kmod+libkmod2 from Sid now from our repo, which depends on libssl3t64, solving this one major conflict which breaks nearly every system upgrade and most package installs --- .build/software/Amiberry/build.bash | 2 -- .build/software/Amiberry/container_build.bash | 3 --- .github/workflows/dietpi-software.bash | 3 --- 3 files changed, 8 deletions(-) diff --git a/.build/software/Amiberry/build.bash b/.build/software/Amiberry/build.bash index 9b4c39802a..61379b0115 100755 --- a/.build/software/Amiberry/build.bash +++ b/.build/software/Amiberry/build.bash @@ -18,8 +18,6 @@ adeps=('libdrm2' 'libgl1-mesa-dri' 'libgbm1' 'libegl1' 'libudev1' 'libxml2' 'lib (( $G_HW_ARCH == 10 )) && opengl_flags=('--disable-video-opengles2' '--enable-video-opengl') adeps_build+=('libgl1-mesa-dev') adeps+=('libgl1') || opengl_flags=('--enable-video-opengles2' '--disable-video-opengl') adeps_build+=('libgles2-mesa-dev') adeps+=('libgles2') G_AGUP -# ARMv6/7 Trixie: Temporarily purge libkmod2, since it causes a dependency conflict due to 64-bit time_t transition. -(( $G_HW_ARCH < 3 && $G_DISTRO == 8 )) && G_AGP libkmod2 G_AGDUG "${adeps_build[@]}" for i in "${adeps[@]}" do diff --git a/.build/software/Amiberry/container_build.bash b/.build/software/Amiberry/container_build.bash index 358fca624a..7b88ee0014 100755 --- a/.build/software/Amiberry/container_build.bash +++ b/.build/software/Amiberry/container_build.bash @@ -137,9 +137,6 @@ Pin-Priority: -1 _EOF_ fi -# ARMv6/7 Trixie: Temporarily prevent dist-upgrade, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. -(( $arch < 3 )) && [[ $DISTRO == 'trixie' ]] && G_EXEC touch rootfs/boot/dietpi/.skip_distro_upgrade - # Automated build cat << _EOF_ >> rootfs/boot/Automation_Custom_Script.sh || Error_Exit 'Failed to generate Automation_Custom_Script.sh' echo '[ INFO ] Running Amiberry build script ...' diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index 50465c80e5..d735537fa5 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -368,9 +368,6 @@ G_EXEC eval 'echo -e '\''[Service]\nAmbientCapabilities='\'' > rootfs/etc/system # Workaround for sysctl: permission denied on key "net.core.rmem_max" in containers G_EXEC sed --follow-symlinks -i '/# Start DietPi-Software/a\sed -i '\''/G_EXEC sysctl -w net\.core\.rmem_max/d'\'' /boot/dietpi/dietpi-software' rootfs/boot/dietpi/dietpi-login -# ARMv6/7 Trixie: Temporarily prevent dist-upgrade, as it fails due to 64-bit time_t transition causing dependency conflicts across the repo. -(( $arch < 3 )) && [[ $DISTRO == 'trixie' ]] && G_EXEC touch rootfs/boot/dietpi/.skip_distro_upgrade - # Check for service status, ports and commands # shellcheck disable=SC2016 # - Start all services From d27048cda0ae9ed5f15d50bd0f3e460c52ce722f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 21 May 2024 15:30:40 +0200 Subject: [PATCH 250/266] v9.5 - DietPi-Software | Remove some obsolete Buster case switches and update link for .NET core dependencies --- dietpi/dietpi-software | 23 +++++++---------------- 1 file changed, 7 insertions(+), 16 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index b23c64cdff..9c233654df 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -180,7 +180,6 @@ Available commands: # PHP version case $G_DISTRO in - 5) PHP_VERSION='7.3';; 6) PHP_VERSION='7.4';; *) PHP_VERSION='8.2';; esac @@ -4910,7 +4909,6 @@ The install script will now exit. After applying one of the the above, rerun die (( $G_RASPBIAN )) && distro='Raspbian_' case $G_DISTRO in - 5) distro+='10';; 6) distro+='11';; 7) distro+='12';; *) distro+='Testing';; @@ -6293,9 +6291,8 @@ _EOF_ if To_Install 212 kavita # Kavita then - # .NET dependency: https://github.com/dotnet/core/blob/main/Documentation/linux-prereqs.md + # .NET dependency: https://github.com/dotnet/docs/blob/main/docs/core/install/linux-debian.md#dependencies case $G_DISTRO in - 5) aDEPS=('libicu63');; 6) aDEPS=('libicu67');; *) aDEPS=('libicu72');; esac @@ -9482,11 +9479,10 @@ _EOF_ then # APT dependencies aDEPS=('mediainfo') - # - .NET: https://github.com/dotnet/core/blob/main/Documentation/linux-prereqs.md + # - .NET: https://github.com/dotnet/docs/blob/main/docs/core/install/linux-debian.md#dependencies if (( $G_HW_ARCH != 1 )) then case $G_DISTRO in - 5) aDEPS+=('libicu63');; 6) aDEPS+=('libicu67');; *) aDEPS+=('libicu72');; esac @@ -9576,11 +9572,10 @@ _EOF_ then # APT dependencies aDEPS=('mediainfo') - # - .NET: https://github.com/dotnet/core/blob/main/Documentation/linux-prereqs.md + # - .NET: https://github.com/dotnet/docs/blob/main/docs/core/install/linux-debian.md#dependencies if (( $G_HW_ARCH != 1 )) then case $G_DISTRO in - 5) aDEPS+=('libicu63');; 6) aDEPS+=('libicu67');; *) aDEPS+=('libicu72');; esac @@ -9798,11 +9793,10 @@ _EOF_ if To_Install 147 jackett # Jackett then # ARMv6 requires Mono: https://github.com/Jackett/Jackett#installation-on-linux-armv6-or-below - # .NET dependency: https://github.com/dotnet/core/blob/main/Documentation/linux-prereqs.md + # .NET dependency: https://github.com/dotnet/docs/blob/main/docs/core/install/linux-debian.md#dependencies if (( $G_HW_ARCH != 1 )) then case $G_DISTRO in - 5) aDEPS=('libicu63');; 6) aDEPS=('libicu67');; *) aDEPS=('libicu72');; esac @@ -9933,9 +9927,8 @@ _EOF_ if To_Install 151 prowlarr # Prowlarr then - # .NET dependency: https://github.com/dotnet/core/blob/main/Documentation/linux-prereqs.md + # .NET dependency: https://github.com/dotnet/docs/blob/main/docs/core/install/linux-debian.md#dependencies case $G_DISTRO in - 5) aDEPS=('libicu63');; 6) aDEPS=('libicu67');; *) aDEPS=('libicu72');; esac @@ -10008,9 +10001,8 @@ _EOF_ if To_Install 203 readarr # Readarr then - # .NET dependency: https://github.com/dotnet/core/blob/main/Documentation/linux-prereqs.md + # .NET dependency: https://github.com/dotnet/docs/blob/main/docs/core/install/linux-debian.md#dependencies case $G_DISTRO in - 5) aDEPS=('libicu63');; 6) aDEPS=('libicu67');; *) aDEPS=('libicu72');; esac @@ -10227,9 +10219,8 @@ _EOF_ if To_Install 154 roonserver # Roon Server then # https://help.roonlabs.com/portal/en/kb/articles/linux-install#Manual_Install - # .NET dependency: https://github.com/dotnet/core/blob/main/Documentation/linux-prereqs.md + # .NET dependency: https://github.com/dotnet/docs/blob/main/docs/core/install/linux-debian.md#dependencies case $G_DISTRO in - 5) aDEPS=('libicu63');; 6) aDEPS=('libicu67');; *) aDEPS=('libicu72');; esac From dba521dfbb0c399e97dc8f046e56909ce920b234 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 22 May 2024 15:54:01 +0200 Subject: [PATCH 251/266] v9.5 - DietPi-Software | Box64: Resolved an issue where an invalid build target was used on Raspberry Pi 5 with 16k page size kernel. This target was removed with latest Box64, as page size handling is now done at runtime. - DietPi-Software | Box86/64: Do not build with symbols, as we strip them anyway and likely override it with "-g0". - DietPi-Software | Update fallback URLs --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 36 +++++++++++++++++------------------- 2 files changed, 18 insertions(+), 19 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 9b6a64a441..42a0ee79d8 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,6 +6,7 @@ Bug fixes: - DietPi-Software | Snapcast Server: Resolved on issue where on RISC-V systems, the web interface was not available, since it is not included in the "snapserver" package from Debian. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 - DietPi-Software | Snapcast Server: Resolved an issue where on Bookworm systems, which installed the Snapcast Server before DietPi v9.4 and reinstalled it afterwards, the server failed to start due to a permissions issue, since the services of both packages use different users. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 - DietPi-Software | Shairport Sync: Resolved a DietPi v9.4 regression, where the AirPlay 2 choice did not have an effect, but the AirPlay 1 package was always installed. Additionally, uninstalling Shairport Sync will now also purge the AirPlay 2 package. Many thanks to @pulpe for fixing this bug: https://github.com/MichaIng/DietPi/pull/7082 +- DietPi-Software | Box64: Resolved an issue where an invalid build target was used on Raspberry Pi 5 with 16k page size kernel. This target was removed with latest Box64, as page size handling is now done at runtime. As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 9c233654df..517b232fe6 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3334,7 +3334,7 @@ _EOF_ esac # Download binary - local fallback_url="https://github.com/prometheus/node_exporter/releases/download/v1.8.0/node_exporter-1.8.0.linux-$arch.tar.gz" + local fallback_url="https://github.com/prometheus/node_exporter/releases/download/v1.8.1/node_exporter-1.8.1.linux-$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/prometheus/node_exporter/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/node_exporter-.*\.linux-$arch\.tar\.gz\"$/{print \$4}")" G_EXEC mkdir -p /opt/node_exporter G_EXEC cp --preserve=mode node_exporter*/node_exporter /opt/node_exporter/ @@ -10967,7 +10967,7 @@ _EOF_ # Download local version=$(curl -sSfL 'https://api.github.com/repos/ptitSeb/box86/releases/latest' | mawk -F\" '/^ *"tag_name": "[^"]*",$/{print $4}') - [[ $version ]] || { version='v0.3.4'; G_DIETPI-NOTIFY 1 "Automatic latest ${aSOFTWARE_NAME[$software_id]} version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } + [[ $version ]] || { version='v0.3.6'; G_DIETPI-NOTIFY 1 "Automatic latest ${aSOFTWARE_NAME[$software_id]} version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } Download_Install "https://github.com/ptitSeb/box86/archive/$version.tar.gz" # Build for targets: https://github.com/ptitSeb/box86/blob/master/CMakeLists.txt @@ -10976,26 +10976,26 @@ _EOF_ # - RPi 2 if (( $G_HW_MODEL == 2 )) then - G_EXEC cmake .. -DRPI2=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRPI2=1 # - RPi 3 elif (( $G_HW_MODEL == 3 )) then - G_EXEC cmake .. -DRPI3=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRPI3=1 # - RPi 4 elif (( $G_HW_MODEL == 4 )) then - G_EXEC cmake .. -DRPI4=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRPI4=1 # - Odroids elif (( $G_HW_MODEL < 20 )) then - G_EXEC cmake .. -DODROID=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DODROID=1 # - ASUS Tinker Board elif (( $G_HW_MODEL == 52 )) then - G_EXEC cmake .. -DRK3288=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRK3288=1 # - Others else - G_EXEC cmake .. -DARM_DYNAREC=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DARM_DYNAREC=1 fi G_EXEC_OUTPUT=1 G_EXEC make CFLAGS='-g0 -O3' "-j$(nproc)" G_EXEC strip --remove-section=.comment --remove-section=.note box86 @@ -11012,7 +11012,7 @@ _EOF_ # Download local version=$(curl -sSfL 'https://api.github.com/repos/ptitSeb/box64/releases/latest' | mawk -F\" '/^ *"tag_name": "[^"]*",$/{print $4}') - [[ $version ]] || { version='v0.2.6'; G_DIETPI-NOTIFY 1 "Automatic latest ${aSOFTWARE_NAME[$software_id]} version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } + [[ $version ]] || { version='v0.2.8'; G_DIETPI-NOTIFY 1 "Automatic latest ${aSOFTWARE_NAME[$software_id]} version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } Download_Install "https://github.com/ptitSeb/box64/archive/$version.tar.gz" # Build for targets: https://github.com/ptitSeb/box64/blob/main/CMakeLists.txt @@ -11021,36 +11021,34 @@ _EOF_ # - RISC-V if (( $G_HW_ARCH == 11 )) then - G_EXEC cmake .. -DRV64=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRV64=1 # - RPi 3 elif (( $G_HW_MODEL == 3 )) then - G_EXEC cmake .. -DRPI3ARM64=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRPI3ARM64=1 # - RPi 4 elif (( $G_HW_MODEL == 4 )) then - G_EXEC cmake .. -DRPI4ARM64=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRPI4ARM64=1 # - RPi 5 elif (( $G_HW_MODEL == 5 )) then - local ps16k='' - dpkg-query -s 'linux-image-rpi-2712' &> /dev/null && ps16k='PS16K' - G_EXEC cmake .. "-DRPI5ARM64$ps16k=1" -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRPI5ARM64=1 # - Odroid N2 elif (( $G_HW_MODEL == 15 )) then - G_EXEC cmake .. -DODROIDN2=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DODROIDN2=1 # - RK3399 elif (( $G_HW_CPUID == 3 )) then - G_EXEC cmake .. -DRK3399=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRK3399=1 # - RK3588 elif (( $G_HW_CPUID == 11 )) then - G_EXEC cmake .. -DRK3588=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRK3588=1 # - Generic ARMv8 else - G_EXEC cmake .. -DARM64=1 -DNOGIT=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DARM64=1 fi G_EXEC_OUTPUT=1 G_EXEC make CFLAGS='-g0 -O3' "-j$(nproc)" G_EXEC strip --remove-section=.comment --remove-section=.note box64 From 896166d9118204985191870247e91ab148299482 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 22 May 2024 16:01:17 +0200 Subject: [PATCH 252/266] v9.5 - CI | DietPi-Software test: Run ARMv8 Bullseye tests on Ubuntu Focal, since QEMU throws segmentation faults on Noble --- .github/workflows/armbian.yml | 1 + .github/workflows/dietpi-software.yml | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/armbian.yml b/.github/workflows/armbian.yml index f2cf580a17..e654a48838 100644 --- a/.github/workflows/armbian.yml +++ b/.github/workflows/armbian.yml @@ -32,6 +32,7 @@ permissions: {} jobs: build: name: "${{ github.event.inputs.asset }} - ${{ github.event.inputs.branch }} - ${{ github.event.inputs.board }}" + # https://github.com/actions/runner-images runs-on: ubuntu-24.04 steps: - name: Clone Armbian repo diff --git a/.github/workflows/dietpi-software.yml b/.github/workflows/dietpi-software.yml index 708964fb51..f641bbf85e 100644 --- a/.github/workflows/dietpi-software.yml +++ b/.github/workflows/dietpi-software.yml @@ -68,7 +68,7 @@ jobs: - { arch: riscv64, dist: bookworm } fail-fast: false name: "${{ matrix.arch }} - ${{ matrix.dist }} - ${{ github.event.inputs.soft }}" - runs-on: ubuntu-24.04 + runs-on: ${{ matrix.dist == 'bullseye' && matrix.arch == 'aarch64' && 'ubuntu-22.04' || 'ubuntu-24.04' }} steps: - name: Install run: | From 5e01b397c2c28ba9a548e97fe7b1355f657d2499 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 22 May 2024 20:41:31 +0200 Subject: [PATCH 253/266] v9.5 - DietPi-Software | Jellyfin: Since a while FFmpeg 6 is available for Jellyfin, but on old installs with the old FFmpeg 5 package, it is not upgraded automatically by APT. This DietPi update applies the FFmpeg upgrade to all affected systems. Many thanks to @gioxx and @WolfganP for reporting this issue: https://github.com/MichaIng/DietPi/issues/7080 - DietPi-Software | Jellyfin: Resolved an issue where the intended HTTP port change could not be applied, since the network config file is not created anymore at service start. We do now pre-create a minimal one, which is complemented with defaults automatically. There was a related issue: https://github.com/MichaIng/DietPi/pull/5559. However, now, indeed network.xml is never created, intentionally, which is fine, since Jellyfin internally applies defaults for all non-defined settings, and stores them back to the config file when completing the web UI setup or saving network settings in web UI. So we can perfectly pre-create a minimal config with just the settings we need to have changed from defaults. Also XML syntax can be minimal, no XML meta data or schemes needed. No need to wait for config files to be created while setting the service start up. --- .update/patches | 7 +++++++ CHANGELOG.txt | 4 ++++ dietpi/dietpi-software | 19 +++++++++---------- 3 files changed, 20 insertions(+), 10 deletions(-) diff --git a/.update/patches b/.update/patches index 8141d49e2f..4e8b14827b 100755 --- a/.update/patches +++ b/.update/patches @@ -1633,6 +1633,13 @@ Patch_9_5() { # Update MPD flag on Bookworm and above: https://github.com/MusicPlayerDaemon/MPD/commit/ce77b14 (( $G_DISTRO > 6 )) && [[ -f '/etc/systemd/system/mpd.service.d/dietpi.conf' ]] && G_EXEC sed -i 's/no-daemon/systemd/' /etc/systemd/system/mpd.service.d/dietpi.conf + + # Migrate jellyfin-ffmpeg5 => jellyfin-ffmpeg6 + if dpkg-query -s jellyfin &> /dev/null && dpkg-query -s jellyfin-ffmpeg5 + then + G_DIETPI-NOTIFY 2 'Migrating to Jellyfin FFmpeg 6' + G_AGI jellyfin + fi } # v6.35 => v7 migration diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 42a0ee79d8..7e4f3d7660 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,12 +1,16 @@ v9.5 (2024-06-08) +Enhancements: +- DietPi-Software | Jellyfin: Since a while FFmpeg 6 is available for Jellyfin, but on old installs with the old FFmpeg 5 package, it is not upgraded automatically by APT. This DietPi update applies the FFmpeg upgrade to all affected systems. Many thanks to @gioxx and @WolfganP for reporting this issue: https://github.com/MichaIng/DietPi/issues/7080 + Bug fixes: - DietPi-Config | Resolved an issue where Advanced Options were not accessible on some SBCs. Many thanks to @thuehlinger for reporting this issue: https://github.com/MichaIng/DietPi/issues/6663#issuecomment-2108351878 - DietPi-Software | Snapcast Server: Resolved on issue where on RISC-V systems, the web interface was not available, since it is not included in the "snapserver" package from Debian. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 - DietPi-Software | Snapcast Server: Resolved an issue where on Bookworm systems, which installed the Snapcast Server before DietPi v9.4 and reinstalled it afterwards, the server failed to start due to a permissions issue, since the services of both packages use different users. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 - DietPi-Software | Shairport Sync: Resolved a DietPi v9.4 regression, where the AirPlay 2 choice did not have an effect, but the AirPlay 1 package was always installed. Additionally, uninstalling Shairport Sync will now also purge the AirPlay 2 package. Many thanks to @pulpe for fixing this bug: https://github.com/MichaIng/DietPi/pull/7082 - DietPi-Software | Box64: Resolved an issue where an invalid build target was used on Raspberry Pi 5 with 16k page size kernel. This target was removed with latest Box64, as page size handling is now done at runtime. +- DietPi-Software | Jellyfin: Resolved an issue where the intended HTTP port change could not be applied, since the network config file is not created anymore at service start. We do now pre-create a minimal one, which is complemented with defaults automatically. As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 517b232fe6..e2521553ba 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10923,12 +10923,7 @@ _EOF_ # APT meta package: Server, web component and FFmpeg implementation G_AGI jellyfin - if [[ -d '/mnt/dietpi_userdata/jellyfin' || -f '/etc/jellyfin/network.xml' ]] - then - G_EXEC systemctl stop jellyfin - else - CREATE_CONFIG_CONTENT='AddPeopleQueryIndex' Create_Config '/etc/jellyfin/migrations.xml' jellyfin 60 - fi + G_EXEC systemctl stop jellyfin # Grant dietpi group permissions and assure video access Create_User -G dietpi,video,render -d /mnt/dietpi_userdata/jellyfin jellyfin @@ -10936,8 +10931,6 @@ _EOF_ # Config: Only apply on fresh install, assumed when /mnt/dietpi_userdata/jellyfin does not yet exist if [[ ! -d '/mnt/dietpi_userdata/jellyfin' ]] then - # Start service until /etc/jellyfin/network.xml exists - Create_Config '/etc/jellyfin/network.xml' jellyfin # Data dir # shellcheck disable=SC2015 [[ -d '/var/lib/jellyfin' ]] && G_EXEC mv /var/lib/jellyfin /mnt/dietpi_userdata/jellyfin || G_EXEC mkdir /mnt/dietpi_userdata/jellyfin @@ -10950,8 +10943,14 @@ _EOF_ [[ -d '/var/cache/jellyfin' ]] && G_EXEC mv /var/cache/jellyfin /mnt/dietpi_userdata/jellyfin/cache || G_EXEC mkdir /mnt/dietpi_userdata/jellyfin/cache G_CONFIG_INJECT 'JELLYFIN_CACHE_DIR=' 'JELLYFIN_CACHE_DIR=/mnt/dietpi_userdata/jellyfin/cache' /etc/default/jellyfin # Change default port due to conflict with Emby - G_CONFIG_INJECT '' '8097' /etc/jellyfin/network.xml - G_CONFIG_INJECT '' ' 8097' /etc/jellyfin/network.xml + # - This config file is not generated at service start, but only when saving network settings via web UI. This also complements any existing config with defaults, hence we pre-create one with only the changes we need. + cat << '_EOF_' > /etc/jellyfin/network.xml + + 8097 + 8097 + +_EOF_ + G_EXEC chown jellyfin: /etc/jellyfin/network.xml fi # Permissions From 236746034f5a8a80f523c75fda7070c9c4b2ca58 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 22 May 2024 20:56:18 +0200 Subject: [PATCH 254/266] v9.5 - DietPi-Patches | Purge left config files when migrating from jellyfin-ffmpeg5 to jellyfin-ffmpeg6 --- .update/patches | 1 + 1 file changed, 1 insertion(+) diff --git a/.update/patches b/.update/patches index 4e8b14827b..b98ad328ee 100755 --- a/.update/patches +++ b/.update/patches @@ -1639,6 +1639,7 @@ Patch_9_5() then G_DIETPI-NOTIFY 2 'Migrating to Jellyfin FFmpeg 6' G_AGI jellyfin + G_AGP jellyfin-ffmpeg5 # conffiles fi } From bef95c9e648833e06d252839d6dc8b6d989057e5 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 22 May 2024 21:02:38 +0200 Subject: [PATCH 255/266] v9.5 - DietPi-Patches | Hide output when checking for installed jellyfin-ffmpeg5 package --- .update/patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index b98ad328ee..78c8cedce3 100755 --- a/.update/patches +++ b/.update/patches @@ -1635,7 +1635,7 @@ Patch_9_5() (( $G_DISTRO > 6 )) && [[ -f '/etc/systemd/system/mpd.service.d/dietpi.conf' ]] && G_EXEC sed -i 's/no-daemon/systemd/' /etc/systemd/system/mpd.service.d/dietpi.conf # Migrate jellyfin-ffmpeg5 => jellyfin-ffmpeg6 - if dpkg-query -s jellyfin &> /dev/null && dpkg-query -s jellyfin-ffmpeg5 + if dpkg-query -s jellyfin &> /dev/null && dpkg-query -s jellyfin-ffmpeg5 &> /dev/null then G_DIETPI-NOTIFY 2 'Migrating to Jellyfin FFmpeg 6' G_AGI jellyfin From 457ae2368bc3a354cd5df635db342fa7a62737b0 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 23 May 2024 15:29:08 +0200 Subject: [PATCH 256/266] v9.5 - DietPi-Software | FreshRSS: Update fallback version --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index e2521553ba..a4d9d5757f 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -7041,7 +7041,7 @@ _EOF_ aDEPS=() else local version=$(curl -sSfL 'https://api.github.com/repos/FreshRSS/FreshRSS/releases/latest' | mawk -F\" '/^ *"tag_name": "[^"]*",$/{print $4}') - [[ $version ]] || { version='1.23.1'; G_DIETPI-NOTIFY 1 "Automatic latest FreshRSS version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } + [[ $version ]] || { version='1.24.0'; G_DIETPI-NOTIFY 1 "Automatic latest FreshRSS version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } Download_Install "https://github.com/FreshRSS/FreshRSS/archive/$version.tar.gz" G_EXEC mv "FreshRSS-$version" /opt/FreshRSS fi From 1f32880a02187141ad8bd36e3071f2655991ff81 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 25 May 2024 23:11:44 +0200 Subject: [PATCH 257/266] v9.5 - DietPi-Config | Detect as well UART devices with indices above 9. The Raspberry Pi 5 has a ttyAMA10 --- dietpi/dietpi-config | 2 +- dietpi/func/dietpi-set_hardware | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index a050f0f399..4353832da9 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -944,7 +944,7 @@ Re-enabling HDMI requires a reboot. If you need emergency HDMI output, edit the G_WHIP_MENU_ARRAY=() (( $G_HW_MODEL < 10 )) && G_WHIP_MENU_ARRAY+=('' '●─ Toggle console ') - for i in /dev/{tty{S,AMA,SAC,AML,SC,GS,FIQ,MV},hvc}[0-9] + for i in /dev/{tty{S,AMA,SAC,AML,SC,GS,FIQ,MV},hvc}[0-9]* do [[ -e $i ]] || continue i=${i#/dev/} diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index af4a19e95d..5c086944d9 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -1503,7 +1503,7 @@ Do you want to continue and disable the serial login console?' || return 1 # Enable boot messages depending on device # - Skip on USB getget serial device, which requires loading a kernel module first and hence cannot be used for boot outputs - if [[ $INPUT_ADDITIONAL == 'ttyGS'[0-9] ]] + if [[ $INPUT_ADDITIONAL == 'ttyGS'[0-9]* ]] then : @@ -1567,7 +1567,7 @@ _EOF_ # Enable for all detected Serial/UART devices else - for i in /dev/{tty{S,AMA,SAC,AML,SC,GS,FIQ,MV},hvc}[0-9] + for i in /dev/{tty{S,AMA,SAC,AML,SC,GS,FIQ,MV},hvc}[0-9]* do [[ -e $i ]] || continue INPUT_ADDITIONAL=${i/\/dev\/} Serial_Main @@ -1629,7 +1629,7 @@ _EOF_ # Disable for all detected Serial/UART devices else - for i in /dev/{tty{S,AMA,SAC,AML,SC,GS,FIQ,MV},hvc}[0-9] + for i in /dev/{tty{S,AMA,SAC,AML,SC,GS,FIQ,MV},hvc}[0-9]* do [[ -e $i ]] || continue INPUT_ADDITIONAL=${i/\/dev\/} Serial_Main From 4b9edba6c1f450b39ce013b8af2de30124384c0d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 26 May 2024 14:06:25 +0200 Subject: [PATCH 258/266] v9.5 - DietPi-Software | rutorrent: Update fallback version --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index a4d9d5757f..750019858f 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8524,7 +8524,7 @@ _EOF_ # Install ruTorrent: Web UI for rTorrent # - Grab current version local version=$(curl -sSfL 'https://api.github.com/repos/Novik/ruTorrent/releases/latest' | mawk -F\" '/^ *"tag_name": "[^"]*",$/{print $4}') - [[ $version ]] || { version='v4.3.0'; G_DIETPI-NOTIFY 1 "Automatic latest ruTorrent version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } + [[ $version ]] || { version='v4.3.2'; G_DIETPI-NOTIFY 1 "Automatic latest ruTorrent version detection failed. Version \"$version\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } Download_Install "https://github.com/Novik/ruTorrent/archive/$version.tar.gz" # - Reinstall freshly with preserved configs and 3rd party plugins From 81c04eebcb13ce768c0a21130df2b2349f4e763f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 26 May 2024 14:33:47 +0200 Subject: [PATCH 259/266] v9.5 - APT | Add URL components for 64-bit Amlogic SoC SBCs --- .update/patches | 8 ++++++++ dietpi/func/dietpi-set_software | 5 +++++ 2 files changed, 13 insertions(+) diff --git a/.update/patches b/.update/patches index 78c8cedce3..437ad34f01 100755 --- a/.update/patches +++ b/.update/patches @@ -1631,6 +1631,14 @@ _EOF_ Patch_9_5() { + # Update DietPi APT list for several SBCs we added components to our repo for + if [[ $PATCH_9_3_RAN == 0 && $G_HW_MODEL =~ ^(12|15|16|54|74)$ ]] + then + /boot/dietpi/func/dietpi-set_software apt-mirror dietpi + G_AGUP + G_AGUG + fi + # Update MPD flag on Bookworm and above: https://github.com/MusicPlayerDaemon/MPD/commit/ce77b14 (( $G_DISTRO > 6 )) && [[ -f '/etc/systemd/system/mpd.service.d/dietpi.conf' ]] && G_EXEC sed -i 's/no-daemon/systemd/' /etc/systemd/system/mpd.service.d/dietpi.conf diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 0b6631f002..5479c79b77 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -124,6 +124,9 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R [0-9]) all_components='rpi';; 10) all_components='odroidc1';; 11) all_components='odroidxu4';; + 12) all_components='odroidc2';; + 15) all_components='odroidn2';; + 16) all_components='odroidc4';; 40) all_components='pinea64';; 44) all_components='pinebook';; 45) all_components='pineh64';; @@ -146,6 +149,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R ;; esac ;; + 54) all_components='nanopik2';; 56) all_components='nanopineo3';; 57) all_components='nanopineoplus2';; 59) all_components='zeropi';; @@ -190,6 +194,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R 66) all_components='nanopim1plus';; 67) all_components='nanopik1plus';; 70) all_components='sparkysbc';; + 74) all_components='radxazero';; 76) # Detect variant either based on $HW_VARIANT environment variable, existing "all" components or installed U-Boot package # shellcheck disable=SC2154 From 29761eceef1ba69dba0d4f51ab98def7284db0a7 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 26 May 2024 14:45:56 +0200 Subject: [PATCH 260/266] v9.5 - CHANGELOG | Odroid C1/C2: Resolved an issue on both SBCs where reboots could hang and a power cycle was required to get the device back up. Many thanks to @yandritos, @gociii and others for reporting this issue: https://github.com/MichaIng/DietPi/issues/5414, https://github.com/MichaIng/DietPi/issues/6332 --- CHANGELOG.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 7e4f3d7660..11b32c5080 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -5,6 +5,7 @@ Enhancements: - DietPi-Software | Jellyfin: Since a while FFmpeg 6 is available for Jellyfin, but on old installs with the old FFmpeg 5 package, it is not upgraded automatically by APT. This DietPi update applies the FFmpeg upgrade to all affected systems. Many thanks to @gioxx and @WolfganP for reporting this issue: https://github.com/MichaIng/DietPi/issues/7080 Bug fixes: +- Odroid C1/C2 | Resolved an issue on both SBCs where reboots could hang and a power cycle was required to get the device back up. Many thanks to @yandritos, @gociii and others for reporting this issue: https://github.com/MichaIng/DietPi/issues/5414, https://github.com/MichaIng/DietPi/issues/6332 - DietPi-Config | Resolved an issue where Advanced Options were not accessible on some SBCs. Many thanks to @thuehlinger for reporting this issue: https://github.com/MichaIng/DietPi/issues/6663#issuecomment-2108351878 - DietPi-Software | Snapcast Server: Resolved on issue where on RISC-V systems, the web interface was not available, since it is not included in the "snapserver" package from Debian. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 - DietPi-Software | Snapcast Server: Resolved an issue where on Bookworm systems, which installed the Snapcast Server before DietPi v9.4 and reinstalled it afterwards, the server failed to start due to a permissions issue, since the services of both packages use different users. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 From dace3885978bd88dc38a5a76cc1ce6d9df139922 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 26 May 2024 14:48:43 +0200 Subject: [PATCH 261/266] v9.5 - CHANGELOG | Give credits to @gitmeister specifically for providing the Odroid C2 reboot fix --- CHANGELOG.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 11b32c5080..d1679b80f1 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -5,7 +5,7 @@ Enhancements: - DietPi-Software | Jellyfin: Since a while FFmpeg 6 is available for Jellyfin, but on old installs with the old FFmpeg 5 package, it is not upgraded automatically by APT. This DietPi update applies the FFmpeg upgrade to all affected systems. Many thanks to @gioxx and @WolfganP for reporting this issue: https://github.com/MichaIng/DietPi/issues/7080 Bug fixes: -- Odroid C1/C2 | Resolved an issue on both SBCs where reboots could hang and a power cycle was required to get the device back up. Many thanks to @yandritos, @gociii and others for reporting this issue: https://github.com/MichaIng/DietPi/issues/5414, https://github.com/MichaIng/DietPi/issues/6332 +- Odroid C1/C2 | Resolved an issue on both SBCs where reboots could hang and a power cycle was required to get the device back up. Many thanks to @yandritos, @gociii and others for reporting this issue, and @gitmeister for providing the fix for Odroid C2: https://github.com/MichaIng/DietPi/issues/5414, https://github.com/MichaIng/DietPi/issues/6332 - DietPi-Config | Resolved an issue where Advanced Options were not accessible on some SBCs. Many thanks to @thuehlinger for reporting this issue: https://github.com/MichaIng/DietPi/issues/6663#issuecomment-2108351878 - DietPi-Software | Snapcast Server: Resolved on issue where on RISC-V systems, the web interface was not available, since it is not included in the "snapserver" package from Debian. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 - DietPi-Software | Snapcast Server: Resolved an issue where on Bookworm systems, which installed the Snapcast Server before DietPi v9.4 and reinstalled it afterwards, the server failed to start due to a permissions issue, since the services of both packages use different users. Many thanks to @hllhll for reporting this issue: https://github.com/MichaIng/DietPi/issues/7073 From 68ed703e2c76dabfd982e7a5927501c87c36f272 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 26 May 2024 15:05:06 +0200 Subject: [PATCH 262/266] v9.5 - Odroid C1 | Flash new U-Boot, probably even the required part to fix reboot issues --- .update/patches | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.update/patches b/.update/patches index 437ad34f01..67ec60037a 100755 --- a/.update/patches +++ b/.update/patches @@ -1639,6 +1639,9 @@ Patch_9_5() G_AGUG fi + # Flash new U-Boot on Odroid C1 + (( $G_HW_MODEL == 10 )) && /boot/dietpi/func/dietpi-set_hardware flash-u-boot-mmc + # Update MPD flag on Bookworm and above: https://github.com/MusicPlayerDaemon/MPD/commit/ce77b14 (( $G_DISTRO > 6 )) && [[ -f '/etc/systemd/system/mpd.service.d/dietpi.conf' ]] && G_EXEC sed -i 's/no-daemon/systemd/' /etc/systemd/system/mpd.service.d/dietpi.conf From 412f65672c9a116b149565435d19fb40ff669399 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 29 May 2024 21:08:29 +0200 Subject: [PATCH 263/266] v9.5 - DietPi-Set_hardware | Add alias "flash-uboot-mmc" for "flash-u-boot-mmc" command - DietPi-Software | Gitea: Update fallback URL --- dietpi/dietpi-software | 2 +- dietpi/func/dietpi-set_hardware | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 750019858f..17cf14926f 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10591,7 +10591,7 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.21.11/gitea-1.21.11-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.22.0/gitea-1.22.0-linux-$arch.xz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/go-gitea/gitea/releases/latest' | mawk -F\" "/\"browser_download_url\": \".*\/gitea-[^\"\/]*-linux-$arch\.xz\"/{print \$4}")" /mnt/dietpi_userdata/gitea/gitea # User diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 5c086944d9..28f77b0d91 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -2397,7 +2397,7 @@ _EOF_ 'rpi3_usb_boot') RPi_USB_Boot_Main;; 'rpi-eeprom') RPi_EEPROM;; 'vf2-spi-update') VF2_SPI_Update;; - 'flash-u-boot-mmc') Flash_U-Boot_MMC || EXIT_CODE=1;; + 'flash-u-boot-mmc'|'flash-uboot-mmc') Flash_U-Boot_MMC || EXIT_CODE=1;; 'headless') Headless_Main;; 'gpudriver') GPUDriver_Main;; 'qemu-guest-agent'|'qga') QEMU_Guest_Agent_Main;; From 1eea6eb424fdce62eb5b9b21f1ee438d2269f46e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 31 May 2024 16:11:12 +0200 Subject: [PATCH 264/266] v9.5 - DietPi-Build/Image | Better detect Debian version on non-DietPi and Ubuntu systems --- .build/images/dietpi-build | 11 ++++++++--- .build/images/dietpi-imager | 16 +++++++++++----- dietpi/dietpi-software | 2 +- 3 files changed, 20 insertions(+), 9 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 862621668e..a596d51f78 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -11,10 +11,15 @@ else curl -sSf "https://raw.githubusercontent.com/${G_GITOWNER:=MichaIng}/DietPi/${G_GITBRANCH:=master}/dietpi/func/dietpi-globals" -o /tmp/dietpi-globals || exit 1 # shellcheck disable=SC1091 . /tmp/dietpi-globals - G_EXEC_NOHALT=1 G_EXEC rm /tmp/dietpi-globals + G_EXEC rm /tmp/dietpi-globals export G_GITOWNER G_GITBRANCH G_HW_ARCH_NAME=$(uname -m) - # shellcheck disable=SC2015 - [[ $( /dev/null) != '5'* ]] + # - Bullseye/Focal: We need Clonezilla 5.x for loop device support + if dpkg --compare-versions "$(dpkg-query -Wf '${Version}' clonezilla 2> /dev/null)" lt 5 then - G_EXEC curl -sSf 'https://deb.debian.org/debian/pool/main/c/clonezilla/clonezilla_5.2.7-1_all.deb' -o clonezilla.deb + G_EXEC curl -sSf 'https://deb.debian.org/debian/pool/main/c/clonezilla/clonezilla_5.3.17-2_all.deb' -o clonezilla.deb G_EXEC dpkg -i ./clonezilla.deb G_EXEC rm clonezilla.deb fi diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 17cf14926f..342095dd32 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6511,7 +6511,7 @@ _EOF_ esac # Download - local fallback_url="https://github.com/fatedier/frp/releases/download/v0.58.0/frp_0.58.0_linux_$arch.tar.gz" + local fallback_url="https://github.com/fatedier/frp/releases/download/v0.58.1/frp_0.58.1_linux_$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/fatedier/frp/releases/latest' | mawk -F\" "/\"browser_download_url\": .*\/frp_[0-9.]*_linux_$arch\.tar\.gz\"/{print \$4}")" G_EXEC cd frp_* From 8307ba23228904efc4a02134cf97386c485c2c0b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 31 May 2024 19:47:34 +0200 Subject: [PATCH 265/266] v9.5 - DietPi-Config | If no Ethernet adapter hsa been detected but the Ethernet interface is enabled, offer to disable it --- .build/images/dietpi-installer | 14 +++++++------- dietpi/dietpi-config | 20 +++++++++++++++----- 2 files changed, 22 insertions(+), 12 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 440f046afd..1ef04f13ff 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1574,26 +1574,26 @@ _EOF_ [[ -d '/etc/chromium.d' ]] && G_EXEC rm -R /etc/chromium.d [[ -d '/etc/lightdm' ]] && G_EXEC rm -R /etc/lightdm - # - www + # www [[ -d '/var/www' ]] && G_EXEC rm -Rf /var/www/{,.??,.[^.]}* - # - Source code and Linux headers + # Source code and Linux headers [[ -d '/usr/src' ]] && G_EXEC rm -Rf /usr/src/{,.??,.[^.]}* - # - Documentation dirs: https://github.com/MichaIng/DietPi/issues/3259 + # Documentation dirs: https://github.com/MichaIng/DietPi/issues/3259 #[[ -d '/usr/share/man' ]] && G_EXEC rm -R /usr/share/man #[[ -d '/usr/share/doc' ]] && G_EXEC rm -R /usr/share/doc #[[ -d '/usr/share/doc-base' ]] && G_EXEC rm -R /usr/share/doc-base [[ -d '/usr/share/calendar' ]] && G_EXEC rm -R /usr/share/calendar - # - Unused DEB package config files + # Unused DEB package config files find / \( -name '*?.dpkg-dist' -o -name '*?.dpkg-old' -o -name '*?.dpkg-new' -o -name '*?.dpkg-bak' -o -name '*?.dpkg-del' -o -name '*?.ucf-dist' -o -name '*?.ucf-old' -o -name '*?.ucf-new' \) -exec rm -v {} + - # - Fonts + # Fonts [[ -d '/usr/share/fonts' ]] && G_EXEC rm -R /usr/share/fonts [[ -d '/usr/share/icons' ]] && G_EXEC rm -R /usr/share/icons - # - Stop, disable and remove not required 3rd party services + # Stop, disable and remove not required 3rd party services local aservices=( # RPi @@ -1639,7 +1639,7 @@ _EOF_ done done - # - Remove obsolete SysV service entries + # Remove obsolete SysV service entries aservices=( 'fake-hwclock' diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index 4353832da9..0fd4369391 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -2478,12 +2478,22 @@ NB: All Ethernet connections will be temporarily dropped!' && Network_ApplyChang 'Ethernet') - # No adapter detected + # No adapter detected: Offer to disable if enabled if (( ! $ETH_HARDWARE )) then + if (( ! $ETH_DISABLED )) + then + if G_WHIP_YESNO 'No Ethernet adapter was detected on your device. +\nWould you like to disable Ethernet?\n - NB: Connections may drop!' + then + ETH_DISABLED=1 + Network_ApplyChanges + fi + return 0 + fi G_WHIP_MSG 'No Ethernet adapter was detected on your device.' - # Disabled: Offer chance to enable + # Disabled: Offer to enable elif (( $ETH_DISABLED )) then if G_WHIP_YESNO 'Ethernet must be enabled before settings can be changed. @@ -2500,7 +2510,7 @@ NB: All Ethernet connections will be temporarily dropped!' && Network_ApplyChang 'WiFi') - # Disabled: Offer chance to enable (also enables WiFi modules) + # Disabled: Offer to enable, including WiFi modules for adapter to be detected if (( $WIFI_DISABLED )) then if G_WHIP_YESNO 'WiFi must be enabled before settings can be changed. @@ -2508,11 +2518,11 @@ NB: All Ethernet connections will be temporarily dropped!' && Network_ApplyChang then WIFI_DISABLED=0 Network_ApplyChanges - # Enter submenu if a WiFi adapters has been detected, else only preselect the menu entry + # Enter submenu if WiFi adapter has been detected, else only preselect the menu entry (( $WIFI_HARDWARE )) && TARGETMENUID=10 || G_WHIP_DEFAULT_ITEM='WiFi' # WiFi adapter menu fi - # No adapter detected + # No adapter detected: Offer to disable elif (( ! $WIFI_HARDWARE )) then if G_WHIP_YESNO 'No WiFi adapter was detected on your device. From ba4c7e34b2662084459a4c1794a6fa2afe337279 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 31 May 2024 21:18:15 +0200 Subject: [PATCH 266/266] v9.5 - DietPi-Installer | Add little note about raised boot time when printing kernel logs to console and install only "gpg" instead of "gnupg", which is sufficient now that "apt-key add" is not used anymore. Since dirmngr is then missing, gpg cannot interact with keyserver by itself anymore, and since gpg-agent is missing, the passphrase to decrypt keys cannot be entered anymore from the console, breaking e.g. "git commit". However, gpg is very clearly telling what is missing, so for users playing with gpg signing/encryption/validation, it should not be a big problem. We can revert in case of negative feedback, or add dirmngr/gpg-agent in particular, instead of the whole gnupg suite. --- .build/images/dietpi-installer | 4 ++-- CHANGELOG.txt | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 1ef04f13ff..1baa3f7eee 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -876,7 +876,7 @@ setenv rootuuid "true"' /boot/boot.cmd 'cron' # Background job scheduler 'curl' # Web address testing, downloading, uploading etc. 'fdisk' # Partitioning tool used by DietPi-FS_partition_resize and DietPi-Imager - 'gnupg' # apt-key add / gpg + 'gpg' # apt-key list / gpg 'htop' # System monitor 'iputils-ping' # "ping" command 'locales' # Support locales, used by dietpi-config > Language/Regional Options > Locale @@ -2283,7 +2283,7 @@ _EOF_ fi # Update config - G_CONFIG_INJECT 'GRUB_CMDLINE_LINUX_DEFAULT=' 'GRUB_CMDLINE_LINUX_DEFAULT="consoleblank=0"' /etc/default/grub + G_CONFIG_INJECT 'GRUB_CMDLINE_LINUX_DEFAULT=' 'GRUB_CMDLINE_LINUX_DEFAULT="consoleblank=0"' /etc/default/grub # NB: Removing "quiet" adds ~0.5s to boot time on my 6.5s - 7.5s boot time laptop. G_CONFIG_INJECT 'GRUB_CMDLINE_LINUX=' 'GRUB_CMDLINE_LINUX="net.ifnames=0"' /etc/default/grub G_CONFIG_INJECT 'GRUB_TIMEOUT=' 'GRUB_TIMEOUT=0' /etc/default/grub G_EXEC_DESC='Regenerating GRUB config' G_EXEC_OUTPUT=1 G_EXEC grub-mkconfig -o /boot/grub/grub.cfg diff --git a/CHANGELOG.txt b/CHANGELOG.txt index d1679b80f1..10f42cd88d 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,6 +2,7 @@ v9.5 (2024-06-08) Enhancements: +- Images | New DietPi images won't contain the "gnupg" package anymore, but "gpg" only, since other features of the suite are not required for our scripts anymore. E.g. "dirmngr" for interacting with keyservers, and "gpg-agent" for key passphrase inputs are hence missing. "gpg" however prints very clear error messages about what is missing. Let us know whether you find one of those GnuPG features too essential to not be pre-installed. - DietPi-Software | Jellyfin: Since a while FFmpeg 6 is available for Jellyfin, but on old installs with the old FFmpeg 5 package, it is not upgraded automatically by APT. This DietPi update applies the FFmpeg upgrade to all affected systems. Many thanks to @gioxx and @WolfganP for reporting this issue: https://github.com/MichaIng/DietPi/issues/7080 Bug fixes: