From dec0ebbad89b611c3f750503c82f2f819f099bb7 Mon Sep 17 00:00:00 2001 From: StephanStS Date: Tue, 29 Oct 2024 13:27:41 +0100 Subject: [PATCH 01/66] Init v9.9 (#7259) --- .meta/dietpi-survey_report | 4 +++- .update/version | 4 ++-- CHANGELOG.txt | 13 +++++++++++++ dietpi/func/dietpi-globals | 4 ++-- 4 files changed, 20 insertions(+), 5 deletions(-) diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index 139bbd161a..8d0d36a6d2 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -732,14 +732,16 @@ shopt -s extglob aSOFTWARE_NAME9_7=() aSOFTWARE_NAME9_8=() + aSOFTWARE_NAME9_9=() for i in "${!aSOFTWARE_NAME9_6[@]}" do aSOFTWARE_NAME9_7[i]=${aSOFTWARE_NAME9_6[i]} aSOFTWARE_NAME9_8[i]=${aSOFTWARE_NAME9_7[i]} + aSOFTWARE_NAME9_9[i]=${aSOFTWARE_NAME9_8[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_8[@]}" + for i in "${aSOFTWARE_NAME9_9[@]}" do aSOFTWARE[$i]=0 done diff --git a/.update/version b/.update/version index 2cb5377cf2..c3a736ce59 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=8 -G_REMOTE_VERSION_RC=0 +G_REMOTE_VERSION_SUB=9 +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 b36930ce8b..1db4e28b98 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,3 +1,16 @@ +v9.9 +(2024-11-16) + +New software: + +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.8 (2024-10-17) diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 8a6d02944d..36a6efd12c 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=8 - [[ $G_DIETPI_VERSION_RC ]] || G_DIETPI_VERSION_RC=0 + [[ $G_DIETPI_VERSION_SUB ]] || G_DIETPI_VERSION_SUB=9 + [[ $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 150235a4eb67ede810e4976ae961218acc45b80b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 29 Oct 2024 17:43:47 +0100 Subject: [PATCH 02/66] v9.8 - CI | DietPi-Build: Add Orange Pi 5 Max and NanoPi M6 to default builds --- .github/workflows/dietpi-build.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index 8ed3cab4cf..9d812b632c 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -93,7 +93,9 @@ jobs: '"-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" + '"-m 90 -d 6", "-m 90 -d 7", "-m 90 -d 8", '\ + '"-m 91 -d 6", "-m 91 -d 7", "-m 91 -d 8", '\ + '"-m 92 -d 6", "-m 92 -d 7", "-m 92 -d 8"]' >> "$GITHUB_OUTPUT" elif [ "${{ github.event.inputs.buildargs }}" = 'quartz64' ] then echo buildargs=[\ From 847403223c7a3296bf595e0ed0838007413ef707 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 29 Oct 2024 22:33:36 +0100 Subject: [PATCH 03/66] v9.9 - CHANGELOG | Add missing changelog entry, actually one for v9.8 but applied via APT anyway --- CHANGELOG.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 1db4e28b98..b095a80132 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,6 +6,7 @@ New software: Enhancements: Bug fixes: +- NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 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 418004d81b02330950c73833adc2b0edfb7747b9 Mon Sep 17 00:00:00 2001 From: NatureHog <55314658+NatureHog@users.noreply.github.com> Date: Thu, 31 Oct 2024 16:45:37 +0100 Subject: [PATCH 04/66] v9.9 (#7262) - DietPi-DDNS | Resolved an issue where the YDNS update test failed due to a changed response from the server API. Many thanks to @NatureHog for reporting and solving the issue: https://github.com/MichaIng/DietPi/pull/7262 --- CHANGELOG.txt | 1 + dietpi/dietpi-ddns | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index b095a80132..fade43399b 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -7,6 +7,7 @@ Enhancements: Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 +- DietPi-DDNS | Resolved an issue where the YDNS update test failed due to a changed response from the server API. Many thanks to @NatureHog for reporting and solving the issue: https://github.com/MichaIng/DietPi/pull/7262 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-ddns b/dietpi/dietpi-ddns index 2b33e6bfd7..b19b4ce35d 100755 --- a/dietpi/dietpi-ddns +++ b/dietpi/dietpi-ddns @@ -223,15 +223,15 @@ Apply() # shellcheck disable=SC2086 if ! result=$(curl $ipfamily -sSfL ${http_auth:+ -u "$USERNAME:$PASSWORD"} "$url" 2>&1) || [[ $PROVIDER == 'DuckDNS' && $result == 'KO' ]] || - [[ $PROVIDER == 'YDNS' && $result != 'ok' ]] || + [[ $PROVIDER == 'YDNS' && $result != 'good'* && $result != 'nochg'* ]] || [[ $PROVIDER == 'Dynu' && $result != 'good'* && $result != 'nochg'* ]] then - G_DIETPI-NOTIFY 1 "DDNS update test failed, please check your input${result:+:\n$result}" STATUS="DDNS update test failed, please check your input${result:+:\n$result}" + G_DIETPI-NOTIFY 1 "$STATUS" return 1 else - G_DIETPI-NOTIFY 2 "DDNS update test succeeded${result:+:\n$result}" STATUS="DDNS update test succeeded${result:+:\n$result}" + G_DIETPI-NOTIFY 2 "$STATUS" fi # Check and in case remove obsolete No-IP client From 9943d6586622761a9a5747b2c0fb37b9fa80fbef Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 31 Oct 2024 21:26:43 +0100 Subject: [PATCH 05/66] v9.9 - DietPi-Software | Update fallback URL, Ampache v7 requires PHP 8.2 --- dietpi/dietpi-software | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index abc50bc214..dce05c82e9 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -7565,8 +7565,15 @@ _EOF_ local json=() [[ $PHP_VERSION == 8* ]] || aDEPS+=("php$PHP_VERSION-json") json=('json') - local fallback_url="https://github.com/ampache/ampache/releases/download/6.6.3/ampache-6.6.3_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 + # Download: Ampache v7 requires PHP 8.2 + if (( $G_DISTRO > 6 )) + then + local fallback_url="https://github.com/ampache/ampache/releases/download/7.0.1/ampache-7.0.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 + else + local fallback_url="https://github.com/ampache/ampache/releases/download/6.6.4/ampache-6.6.4_all_php$PHP_VERSION.zip" + Download_Install "$(curl -sSfL 'https://api.github.com/repos/ampache/ampache/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*\/ampache-[0-9\.]*_all_php$PHP_VERSION.zip\"$/{print \$4}")" ampache + fi # Reinstall: Preserve configs from old and new paths [[ -f '/var/www/ampache/config/ampache.cfg.php' ]] && G_EXEC mv /var/www/ampache/config/ampache.cfg.php ampache/config/ @@ -9364,7 +9371,7 @@ _EOF_ if (( ${PHP_VERSION::1} > 7 )) then aDEPS+=("php$PHP_VERSION-curl") - local fallback_url='https://github.com/koel/koel/releases/download/v7.1.0/koel-v7.1.0.tar.gz' aphp_deps=('curl' 'dom') + local fallback_url='https://github.com/koel/koel/releases/download/v7.2.0/koel-v7.2.0.tar.gz' aphp_deps=('curl' 'dom') Download_Install "$(curl -sSfL 'https://api.github.com/repos/koel/koel/releases/latest' | mawk -F\" '/^ *"browser_download_url": ".*\/koel-[^"\/]*\.tar\.gz"$/{print $4}')" else aDEPS+=("php$PHP_VERSION-json") @@ -9548,7 +9555,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.12.2.9335/Radarr.master.5.12.2.9335.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.14.0.9383/Radarr.master.5.14.0.9383.linux-core-$arch.tar.gz" fi Download_Install "$url" @@ -9646,7 +9653,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.6.4.4402/Lidarr.master.2.6.4.4402.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Lidarr/Lidarr/releases/download/v2.7.1.4417/Lidarr.master.2.7.1.4417.linux-core-$arch.tar.gz" fi Download_Install "$url" @@ -9994,7 +10001,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.24.3.4754/Prowlarr.master.1.24.3.4754.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.25.4.4818/Prowlarr.master.1.25.4.4818.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 @@ -10070,7 +10077,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.0.2634/Readarr.develop.0.4.0.2634.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.2.2653/Readarr.develop.0.4.2.2653.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 @@ -11695,7 +11702,7 @@ _EOF_ *) local arch='arm';; esac - local fallback_url="https://github.com/restic/restic/releases/download/v0.17.1/restic_0.17.1_linux_$arch.bz2" + local fallback_url="https://github.com/restic/restic/releases/download/v0.17.2/restic_0.17.2_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 f9ff5087fde8b2a0fb62bfe89cf957a9e6e86b4d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 3 Nov 2024 17:08:26 +0100 Subject: [PATCH 06/66] v9.9 - DietPi-Build | Adjust thread limit for xz, like we did for DietPi-Imager: Opposed to 7zip, xz limits threads automatically based on available memory, more strictly than we did manually. Hence make us of that, and set max allowed memory usage to 75% phyical RAM. --- .build/images/dietpi-build | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 53ace2c6d5..d2cd5d5994 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -713,10 +713,6 @@ fi ########################################## # Virtual machines ########################################## -# NB: LZMA2 ultra compression requires much memory per thread. 1 GiB is not sufficient for >2 threads, hence use "-mmt2" to limit used CPU threads to "2" on 1 GiB devices with more than two cores. -limit_threads=() -(( $(free -m | mawk '/Mem:/{print $2}') < 1750 && $(nproc) > 2 )) && limit_threads=('-T2') - # Since qemu-img does not support VMDK and VHDX resizing, we need to resize the raw .img. It is usually done as sparse file, hence the actual disk usage does not change. G_EXEC qemu-img resize "$OUTPUT_IMG_NAME.img" 8G @@ -771,7 +767,7 @@ ethernet0.present = "TRUE" extendedConfigFile = "$image_name.vmxf" floppy0.present = "FALSE" _EOF_ - G_EXEC_DESC='Creating VMware tar.xz archive' XZ_OPT="-9e ${limit_threads[*]}" G_EXEC tar -cJf "$image_name.tar.xz" "$image_name.vmdk" "$image_name.vmx" + G_EXEC_DESC='Creating VMware tar.xz archive' XZ_OPT='-9e -T0 -M75%' G_EXEC tar -cJf "$image_name.tar.xz" "$image_name.vmdk" "$image_name.vmx" G_EXEC rm "$image_name.vmdk" "$image_name.vmx" G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$image_name.tar.xz' > '$image_name.tar.xz.sha256'" signature=() @@ -900,7 +896,7 @@ _EOF_ [[ $VMTYPE == 'all' ]] || G_EXEC rm "$image_name.vmdk" G_EXEC rm "$image_name."{ovf,mf} - G_EXEC_DESC='Creating ESXi xz archive' G_EXEC xz -9e "${limit_threads[@]}" "$image_name.ova" + G_EXEC_DESC='Creating ESXi xz archive' G_EXEC xz -9e -T0 -M75% "$image_name.ova" G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$image_name.ova.xz' > '$image_name.ova.xz.sha256'" signature=() [[ $SIGN_PASS ]] && { G_DIETPI-NOTIFY 2 'Signing archive ...'; gpg --batch --pinentry-mode loopback --passphrase "$SIGN_PASS" -b --armor "$image_name.ova.xz" || exit 1; signature=("$image_name.ova.xz.asc"); } @@ -1051,7 +1047,7 @@ _EOF_ G_EXEC tar -cf "$image_name.ova" "$image_name."{ovf,vmdk,mf} G_EXEC rm "$image_name."{ovf,vmdk,mf} - G_EXEC_DESC='Creating VirtualBox xz archive' G_EXEC xz -9e "${limit_threads[@]}" "$image_name.ova" + G_EXEC_DESC='Creating VirtualBox xz archive' G_EXEC xz -9e -T0 -M75% "$image_name.ova" G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$image_name.ova.xz' > '$image_name.ova.xz.sha256'" signature=() [[ $SIGN_PASS ]] && { G_DIETPI-NOTIFY 2 'Signing archive ...'; gpg --batch --pinentry-mode loopback --passphrase "$SIGN_PASS" -b --armor "$image_name.ova.xz" || exit 1; signature=("$image_name.ova.xz.asc"); } @@ -1065,7 +1061,7 @@ then # Convert raw image to VHDX G_EXEC qemu-img convert -O vhdx "$OUTPUT_IMG_NAME.img" "$image_name.vhdx" - G_EXEC_DESC='Creating Hyper-V xz archive' G_EXEC xz -9e "${limit_threads[@]}" "$image_name.vhdx" + G_EXEC_DESC='Creating Hyper-V xz archive' G_EXEC xz -9e -T0 -M75% "$image_name.vhdx" G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$image_name.vhdx.xz' > '$image_name.vhdx.xz.sha256'" signature=() [[ $SIGN_PASS ]] && { G_DIETPI-NOTIFY 2 'Signing archive ...'; gpg --batch --pinentry-mode loopback --passphrase "$SIGN_PASS" -b --armor "$image_name.vhdx.xz" || exit 1; signature=("$image_name.vhdx.xz.asc"); } @@ -1230,7 +1226,7 @@ _EOF_ _EOF_ - G_EXEC_DESC='Creating UTM tar.xz archive' XZ_OPT="-9e ${limit_threads[*]}" G_EXEC tar -cJf "$image_name.tar.xz" "$image_name.utm" + G_EXEC_DESC='Creating UTM tar.xz archive' XZ_OPT='-9e -T0 -M75%' G_EXEC tar -cJf "$image_name.tar.xz" "$image_name.utm" G_EXEC rm -R "$image_name.utm" G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$image_name.tar.xz' > '$image_name.tar.xz.sha256'" signature=() @@ -1262,7 +1258,7 @@ then image_name=${OUTPUT_IMG_NAME/_VM-/_Proxmox-} G_EXEC qemu-img convert -c -O qcow2 "$OUTPUT_IMG_NAME.img" "$image_name.qcow2" - G_EXEC_DESC='Creating Proxmox xz archive' G_EXEC xz -9e "${limit_threads[@]}" "$image_name.qcow2" + G_EXEC_DESC='Creating Proxmox xz archive' G_EXEC xz -9e -T0 -M75% "$image_name.qcow2" G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$image_name.qcow2.xz' > '$image_name.qcow2.xz.sha256'" signature=() [[ $SIGN_PASS ]] && { G_DIETPI-NOTIFY 2 'Signing archive ...'; gpg --batch --pinentry-mode loopback --passphrase "$SIGN_PASS" -b --armor "$image_name.qcow2.xz" || exit 1; signature=("$image_name.qcow2.xz.asc"); } From 269eba36aa8bdc2fd3103892174da0daa85dcb40 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 3 Nov 2024 18:07:12 +0100 Subject: [PATCH 07/66] v9.9 - DietPi-Imager | Add option to upload uncompressed image, by providing two dedicated options "--skip-archive" and "--upload-script", to compress the image whether to upload the archive or uncompressed image separetely. In the same turn, the upload is not done implicitly based on existance of "upload.sh", but the script path needs to be explicitly passed with the option. - DietPi-Build | Expose and forward the two DietPi-Imager options for image compression and upload. - CI | DietPi-Build: Pass the upload script, as needed now. --- .build/images/dietpi-build | 10 ++++-- .build/images/dietpi-imager | 57 ++++++++++++++++++++---------- .github/workflows/dietpi-build.yml | 2 +- 3 files changed, 47 insertions(+), 22 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index d2cd5d5994..3b07e2c463 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -54,6 +54,8 @@ GITBRANCH='master' GITOWNER='MichaIng' EDITION= SUFFIX= +SKIP_ARCHIVE=0 +UPLOAD_SCRIPT= ADD_DOS_PART=1 SIGN_PASS= TEST_KERNEL=0 @@ -72,6 +74,8 @@ do '-o') shift; GITOWNER=$1;; '-e') shift; EDITION=$1;; '-s') shift; SUFFIX=$1;; + '--skip-archive') SKIP_ARCHIVE=1;; + '--upload-script') shift; UPLOAD_SCRIPT=$1;; '--no-dos-part') ADD_DOS_PART=0;; '--sign') shift; SIGN_PASS=$1;; '--test-kernel') TEST_KERNEL=1;; @@ -477,9 +481,11 @@ G_EXEC losetup -d "$FP_LOOP" # DietPi-Imager ########################################## # Do not pack and upload raw VM image if not explicitly requested -[[ $VMTYPE && ! $VMTYPE =~ ^(raw|all)$ ]] && SKIP_ARCHIVE=1 || SKIP_ARCHIVE=0 -export FP_ROOT_DEV CLONING_TOOL OUTPUT_IMG_NAME MOUNT_IT='Off' SKIP_ARCHIVE SKIP_FIRSTBOOT_RESIZE=1 +[[ $VMTYPE && ! $VMTYPE =~ ^(raw|all)$ ]] && SKIP_ARCHIVE=1 UPLOAD_SCRIPT='' +export FP_ROOT_DEV CLONING_TOOL OUTPUT_IMG_NAME MOUNT_IT='Off' SKIP_FIRSTBOOT_RESIZE=1 IMAGER_ARGS=("$OUTPUT_IMG_NAME.img") +(( $SKIP_ARCHIVE )) && IMAGER_ARGS+=('--skip-archive') +[[ $UPLOAD_SCRIPT ]] && IMAGER_ARGS+=('--upload-script' "$UPLOAD_SCRIPT") (( $ADD_DOS_PART )) && IMAGER_ARGS+=('--add-dos-part') [[ $HW_MODEL == [1245] ]] && IMAGER_ARGS+=('--configs-to-boot') [[ $SIGN_PASS ]] && IMAGER_ARGS+=('--sign' "$SIGN_PASS") diff --git a/.build/images/dietpi-imager b/.build/images/dietpi-imager index 28704f039a..8557a0fc97 100755 --- a/.build/images/dietpi-imager +++ b/.build/images/dietpi-imager @@ -70,12 +70,15 @@ [[ $SKIP_FIRSTBOOT_RESIZE == 1 ]] || SKIP_FIRSTBOOT_RESIZE=0 [[ $SHRINK_ONLY == 1 ]] || SHRINK_ONLY=0 [[ $SKIP_ARCHIVE == 1 ]] || SKIP_ARCHIVE=0 + UPLOAD_SCRIPT= 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 case $1 in + '--skip-archive') SKIP_ARCHIVE=1;; + '--upload-script') shift; UPLOAD_SCRIPT=$1;; '--add-dos-part') ADD_DOS_PART=1;; '--configs-to-boot') CONFIGS_TO_BOOT=1;; '--sign') shift; SIGN_PASS=$1;; @@ -336,6 +339,8 @@ unset -v main_menu_choice fi + FP_FINAL="$FP_ORIGIN/$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" + # Detect partition table type, failsafe detection of MBR to debug possibly other/unknown wording/partition table types PART_TABLE_TYPE=$(lsblk -no PTTYPE "$FP_ROOT_DEV") if [[ $PART_TABLE_TYPE == 'dos' ]] @@ -608,7 +613,7 @@ _EOF_ G_EXEC truncate -s "$IMAGE_SIZE" "$FP_SOURCE_IMG" # Rename if source image != output image yet - [[ $(readlink -f "$PWD/$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT") != "$(readlink -f "$FP_SOURCE_IMG")" ]] && G_EXEC mv "$FP_SOURCE_IMG" "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" + [[ $(readlink -f "$FP_FINAL") != "$(readlink -f "$FP_SOURCE_IMG")" ]] && G_EXEC mv "$FP_SOURCE_IMG" "$FP_FINAL" # Check for sufficient free disk space to store the xz archive with 100 MiB buffer (( $SKIP_ARCHIVE )) || G_CHECK_FREESPACE . $(( $IMAGE_SIZE * 15/100 / 1024**2 + 100 )) || exit 1 @@ -622,7 +627,7 @@ _EOF_ G_CHECK_FREESPACE . $(( $IMAGE_SIZE * $free_space_percent/100 / 1024**2 + 100 )) || exit 1 G_DIETPI-NOTIFY 2 "Creating final image with actually used size: $(( $IMAGE_SIZE / 1024**2 + 1 )) MiB" - G_EXEC_OUTPUT=1 G_EXEC dd if="$FP_SOURCE" of="$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" bs=1M status=progress count=$(( $IMAGE_SIZE / 1024**2 + 1 )) + G_EXEC_OUTPUT=1 G_EXEC dd if="$FP_SOURCE" of="$FP_FINAL" bs=1M status=progress count=$(( $IMAGE_SIZE / 1024**2 + 1 )) # Clonezilla target else @@ -741,40 +746,54 @@ _EOF_ (( $REMOVE_IMG )) && G_EXEC rm "$FP_SOURCE_IMG" # Generate ISO file with Clonezilla Live + DietPi image - G_EXEC_DESC="Generating $OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" G_EXEC_OUTPUT=1 G_EXEC xorriso \ + G_EXEC_DESC="Generating $FP_FINAL" G_EXEC_OUTPUT=1 G_EXEC xorriso \ -as mkisofs -R -r -J -joliet-long -l -iso-level 3 -isohybrid-mbr /usr/lib/ISOLINUX/isohdpfx.bin -partition_offset 16 \ -publisher 'DietPi - Lightweight justice for your SBC; https://dietpi.com/;' -volid 'DIETPI_INSTALLER' \ -A "clonezilla-live-$CLONEZILLA_VERSION-amd64" -b syslinux/isolinux.bin -c syslinux/boot.cat -no-emul-boot -boot-load-size 4 \ -boot-info-table -eltorito-alt-boot --efi-boot boot/grub/efi.img -isohybrid-gpt-basdat -isohybrid-apm-hfsplus \ - -o "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" tmpiso + -o "$FP_FINAL" tmpiso G_EXEC rm -R tmpiso fi # Move GPT backup partition table to end of drive if [[ $CLONING_TOOL != 'Clonezilla' && $PART_TABLE_TYPE == 'gpt' ]] then - G_EXEC_DESC='Re-creating GPT backup partition table and header at end of image' G_EXEC_OUTPUT=1 G_EXEC sgdisk -e "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT" + G_EXEC_DESC='Re-creating GPT backup partition table and header at end of image' G_EXEC_OUTPUT=1 G_EXEC sgdisk -e "$FP_FINAL" G_EXEC sync fi - # Exit now when archive shall be skipped - (( $SKIP_ARCHIVE )) && exit 0 + # Generate xz archive if requested + local archive_text='' + if (( ! $SKIP_ARCHIVE )) + then + [[ -f $FP_FINAL.xz ]] && G_EXEC rm "$FP_FINAL.xz" + G_EXEC_DESC='Creating final xz archive' G_EXEC xz -9e -T0 -M75% -k "$FP_FINAL" + FP_FINAL+='.xz' + archive_text="\nxz archive: $FP_FINAL" + fi - # Generate xz archive - [[ -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 -T0 -M75% -k "$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[*]}"; } + # Generate SHA256 hash + G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$FP_FINAL' > '$FP_FINAL.sha256'" - G_DIETPI-NOTIFY 0 "DietPi-Imager has successfully finished. -Image file: $PWD/$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT -xz archive: $PWD/$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz -SHA256 hash: $PWD/$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz.sha256$sig_text" + # Generate GPG signature if requested + local sig_text='' signature=() + if [[ $SIGN_PASS ]] + then + G_DIETPI-NOTIFY 2 "Signing $FP_FINAL ..." + gpg --batch --pinentry-mode loopback --passphrase "$SIGN_PASS" -b --armor "$FP_FINAL" || exit 1 + sig_text="\nSignature: $FP_FINAL.asc" signature=("$FP_FINAL.asc") + fi - # Upload archive automatically if there is an upload.sh in the same directory - [[ -x 'upload.sh' ]] && G_EXEC_OUTPUT=1 G_EXEC ./upload.sh "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz"{,.sha256} "${signature[@]}" && G_EXEC rm -R "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz"{,.sha256} "${signature[@]}" + G_DIETPI-NOTIFY 0 "DietPi-Imager has successfully finished. +Image file: ${FP_FINAL%.xz}$archive_text +SHA256 hash: $FP_FINAL.sha256$sig_text" + # Upload if requested + if [[ $UPLOAD_SCRIPT ]] + then + [[ -x "$UPLOAD_SCRIPT" ]] || { G_DIETPI-NOTIFY 1 "Upload script $UPLOAD_SCRIPT does not exist or is not executable. Aborting ..."; exit 1; } + G_EXEC_OUTPUT=1 G_EXEC ./upload.sh "$FP_FINAL"{,.sha256} "${signature[@]}" && (( ! $SKIP_ARCHIVE )) && G_EXEC rm -R "$FP_FINAL"{,.sha256} "${signature[@]}" + fi } #///////////////////////////////////////////////////////////////////////////////////// diff --git a/.github/workflows/dietpi-build.yml b/.github/workflows/dietpi-build.yml index 9d812b632c..f982745cfb 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -138,4 +138,4 @@ jobs: ${{ secrets.GPG_KEY }} _EOF_ - name: Run DietPi-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/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 }}' --upload-script 'upload.sh' From c2eebda88b843ca729ea1f36e8c3e36ec625d6d5 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Nov 2024 21:26:57 +0100 Subject: [PATCH 08/66] v9.9 - DietPi-Software | InfluxDB: Resolved an issue where the service did not start up after the recent package upgrade. The package upgrade removes the symlink /var/lib/influxdb => /mnt/dietpi_userdata/influxdb, which is recreated with this DietPi update. Many thanks to @uwjhn for reporting this issue: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 --- .update/patches | 13 +++++++++++++ CHANGELOG.txt | 1 + dietpi/dietpi-software | 4 ++-- 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/.update/patches b/.update/patches index d33f4e80ac..f7afb974f8 100755 --- a/.update/patches +++ b/.update/patches @@ -2030,6 +2030,19 @@ _EOF_ fi } +Patch_9_9() +{ + # Software updates, migrations and patches + if [[ -f '/boot/dietpi/.installed' ]] + then + # InfluxDB: Recreate symlink deleted with package update: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[74\]=2' /boot/dietpi/.installed && [[ ! -e '/var/lib/influxdb' ]] + then + G_EXEC ln -sf /mnt/dietpi_userdata/influxdb /var/lib/influxdb + fi + fi +} + # 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 fade43399b..fb89e619fb 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -8,6 +8,7 @@ Enhancements: Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 - DietPi-DDNS | Resolved an issue where the YDNS update test failed due to a changed response from the server API. Many thanks to @NatureHog for reporting and solving the issue: https://github.com/MichaIng/DietPi/pull/7262 +- DietPi-Software | InfluxDB: Resolved an issue where the service did not start up after the recent package upgrade. The package upgrade removes the symlink /var/lib/influxdb => /mnt/dietpi_userdata/influxdb, which is recreated with this DietPi update. Many thanks to @uwjhn for reporting this issue: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 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 dce05c82e9..9981da9a91 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8227,7 +8227,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.5/baikal-0.9.5.zip' + local fallback_url='https://github.com/sabre-io/Baikal/releases/download/0.10.0/baikal-0.10.0.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/ @@ -10077,7 +10077,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.2.2653/Readarr.develop.0.4.2.2653.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.3.2665/Readarr.develop.0.4.3.2665.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 18069018099f6f6d543b56c876a27e173d826fd3 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Nov 2024 22:38:45 +0100 Subject: [PATCH 09/66] v9.9 - DietPi-Software | NFS Server: The "fsid=0" option has been removed from the /mnt/dietpi_userdata default export. As it is uncommon and not respected in "showmount -e" export lists, it caused confusion and issues. --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index fb89e619fb..8a0ceb88b8 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -4,6 +4,7 @@ v9.9 New software: Enhancements: +- DietPi-Software | NFS Server: The "fsid=0" option has been removed from the /mnt/dietpi_userdata default export. As it is uncommon and not respected in "showmount -e" export lists, it caused confusion and issues. Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 9981da9a91..9808c6815f 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3472,7 +3472,7 @@ _EOF_ G_EXEC systemctl stop nfs-server G_EXEC mkdir -p /etc/exports.d - [[ -f '/etc/exports.d/dietpi.exports' ]] || G_EXEC eval 'echo '\''/mnt/dietpi_userdata *(rw,async,no_root_squash,fsid=0,crossmnt,no_subtree_check)'\'' > /etc/exports.d/dietpi.exports' + [[ -f '/etc/exports.d/dietpi.exports' ]] || G_EXEC eval 'echo '\''/mnt/dietpi_userdata *(rw,async,no_root_squash,crossmnt,no_subtree_check)'\'' > /etc/exports.d/dietpi.exports' fi if To_Install 83 apache2 # Apache From dce0579f7ae84264df9021931ef8afabbc6c80f5 Mon Sep 17 00:00:00 2001 From: Joulinar <47155374+Joulinar@users.noreply.github.com> Date: Thu, 7 Nov 2024 23:23:36 +0100 Subject: [PATCH 10/66] v9.9 (#7274) - DietPi-Software | YaCy: The latest YaCy version will now be installed, and the global software password will be set as default admin password on fresh installs. --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 15 +++++++++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 8a0ceb88b8..5423a5c426 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -5,6 +5,7 @@ New software: Enhancements: - DietPi-Software | NFS Server: The "fsid=0" option has been removed from the /mnt/dietpi_userdata default export. As it is uncommon and not respected in "showmount -e" export lists, it caused confusion and issues. +- DietPi-Software | YaCy: The latest YaCy version will now be installed, and the global software password will be set as default admin password on fresh installs. Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 9808c6815f..87eecb9969 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -4121,8 +4121,13 @@ _EOF_ if To_Install 133 yacy # YaCy then # Get latest download - local file=$(curl -sSfL 'https://download.yacy.net/?C=N;O=D' | grep -wo 'yacy_v[0-9._]*\.tar\.gz' | head -1) - [[ $file ]] || { file='yacy_v1.924_20210209_10069.tar.gz'; G_DIETPI-NOTIFY 1 "Automatic latest ${aSOFTWARE_NAME[$software_id]} version detection failed. \"$file\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } + if (( $G_HW_ARCH == 1 )) + then + local file='yacy_v1.926_202308282208_376bcfd54_last_java_8.tar.gz' + else + local file=$(curl -sSfL 'https://download.yacy.net/?C=N;O=D' | grep -wo 'yacy_v[0-9._a-f]*\.tar\.gz' | head -1) + [[ $file ]] || { file='yacy_v1.940_202405270005_70454654f.tar.gz'; G_DIETPI-NOTIFY 1 "Automatic latest ${aSOFTWARE_NAME[$software_id]} version detection failed. \"$file\" will be installed as fallback, but a newer version might be available. Please report this at: https://github.com/MichaIng/DietPi/issues"; } + fi Download_Install "https://download.yacy.net/$file" /etc @@ -4142,6 +4147,12 @@ ExecStop=/etc/yacy/stopYACY.sh [Install] WantedBy=multi-user.target _EOF_ + # Set admin interface passwd: + if [[ ! -f '/etc/yacy/DATA/SETTINGS/yacy.conf' ]] + then + Create_Config /etc/yacy/DATA/SETTINGS/yacy.conf yacy + /etc/yacy/bin/passwd.sh "$GLOBAL_PW" + fi fi if To_Install 186 ipfs # IPFS Node From 2187d652bbdc43fd9aec532ab481e219d28c1a3c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 7 Nov 2024 23:34:27 +0100 Subject: [PATCH 11/66] v9.9 - DietPi-Software | Node-RED: Resolved an issue where the service failed on ARMv6 systems, since a dependency module of Node-RED v4 does not support this architecture. Node-RED v3 will now be installed on those old RPi models. Many thanks to @mvanbrab for reporting this issue: https://github.com/MichaIng/DietPi/issues/7252 --- .github/workflows/dietpi-software.bash | 2 +- CHANGELOG.txt | 1 + dietpi/dietpi-software | 5 ++++- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index 1005e15c2a..8dd83980c0 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -171,7 +171,7 @@ Process_Software() 128) aSERVICES[i]='mpd' aTCP[i]='6600';; 131) (( $arch == 2 || $arch == 11 )) || aSERVICES[i]='blynkserver' aTCP[i]='9443'; (( $arch == 10 || $arch == 2 || $arch == 11 )) || aDELAY[i]=60;; 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;; + 133) (( $arch == 2 || $arch == 11 )) || aSERVICES[i]='yacy' aTCP[i]='8090'; (( $arch == 10 )) && aDELAY[i]=30; (( $arch == 10 || $arch == 2 || $arch == 11)) || aDELAY[i]=90;; 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 136) aSERVICES[i]='motioneye' aTCP[i]='8765';; diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 5423a5c426..fc0824d1be 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -11,6 +11,7 @@ Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 - DietPi-DDNS | Resolved an issue where the YDNS update test failed due to a changed response from the server API. Many thanks to @NatureHog for reporting and solving the issue: https://github.com/MichaIng/DietPi/pull/7262 - DietPi-Software | InfluxDB: Resolved an issue where the service did not start up after the recent package upgrade. The package upgrade removes the symlink /var/lib/influxdb => /mnt/dietpi_userdata/influxdb, which is recreated with this DietPi update. Many thanks to @uwjhn for reporting this issue: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 +- DietPi-Software | Node-RED: Resolved an issue where the service failed on ARMv6 systems, since a dependency module of Node-RED v4 does not support this architecture. Node-RED v3 will now be installed on those old RPi models. Many thanks to @mvanbrab for reporting this issue: https://github.com/MichaIng/DietPi/issues/7252 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 87eecb9969..4a02e2698e 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6687,7 +6687,10 @@ _EOF_ local cache=$(runuser -u nodered -- mktemp -d) # - Reinstall: Remove all locally installed modules, to work around update issues, but preserve installed plugins from package.json: https://github.com/MichaIng/DietPi/issues/7128 [[ -f 'package.json' ]] && G_EXEC rm -Rf node_modules .npm/_cacache - G_EXEC_OUTPUT=1 G_EXEC runuser -u nodered -- npm i --cache "$cache" --no-audit node-red@latest + # - Install v3 on ARMv6, since the @node-rs/bcrypt dependency does not support it: https://github.com/MichaIng/DietPi/issues/7252 + local version='latest' + (( $G_HW_ARCH == 1 )) && version=3 + G_EXEC_OUTPUT=1 G_EXEC runuser -u nodered -- npm i --cache "$cache" --no-audit "node-red@$version" G_EXEC rm -R "$cache" G_EXEC cd "$G_WORKING_DIR" From 497d95d2450a333d641d47a990785031da72c43f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 8 Nov 2024 18:09:29 +0100 Subject: [PATCH 12/66] v9.9 - DietPi-Software | Chromium: Resolved an issue where optional Chromium flags via "CHROMIUM_OPTS+=" line in /var/lib/dietpi/dietpi-software/installed/chromium-autostart.sh did not have any effect, as "+=" is bash-only syntax, while the script is executed with dash (bourne shell). Many thanks to @Nurgak for reporting this issue: https://github.com/MichaIng/DietPi/issues/7263#issuecomment-2463626660 --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index fc0824d1be..18e5e7aeb8 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -12,6 +12,7 @@ Bug fixes: - DietPi-DDNS | Resolved an issue where the YDNS update test failed due to a changed response from the server API. Many thanks to @NatureHog for reporting and solving the issue: https://github.com/MichaIng/DietPi/pull/7262 - DietPi-Software | InfluxDB: Resolved an issue where the service did not start up after the recent package upgrade. The package upgrade removes the symlink /var/lib/influxdb => /mnt/dietpi_userdata/influxdb, which is recreated with this DietPi update. Many thanks to @uwjhn for reporting this issue: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 - DietPi-Software | Node-RED: Resolved an issue where the service failed on ARMv6 systems, since a dependency module of Node-RED v4 does not support this architecture. Node-RED v3 will now be installed on those old RPi models. Many thanks to @mvanbrab for reporting this issue: https://github.com/MichaIng/DietPi/issues/7252 +- DietPi-Software | Chromium: Resolved an issue where optional Chromium flags via "CHROMIUM_OPTS+=" line in /var/lib/dietpi/dietpi-software/installed/chromium-autostart.sh did not have any effect, as "+=" is bash-only syntax, while the script is executed with dash (bourne shell). Many thanks to @Nurgak for reporting this issue: https://github.com/MichaIng/DietPi/issues/7263#issuecomment-2463626660 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 4a02e2698e..1b2954a593 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9070,7 +9070,7 @@ RES_Y=$(sed -n '/^[[:blank:]]*SOFTWARE_CHROMIUM_RES_Y=/{s/^[^=]*=//p;q}' /boot/d CHROMIUM_OPTS="--kiosk --window-size=${RES_X:-1280},${RES_Y:-720} --window-position=0,0" # If you want tablet mode, uncomment the next line. -#CHROMIUM_OPTS+=' --force-tablet-mode --tablet-ui' +#CHROMIUM_OPTS="$CHROMIUM_OPTS --force-tablet-mode --tablet-ui" # Home page URL=$(sed -n '/^[[:blank:]]*SOFTWARE_CHROMIUM_AUTOSTART_URL=/{s/^[^=]*=//p;q}' /boot/dietpi.txt) From 70181b027a67e90ea155700266827efeec61d5e5 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 8 Nov 2024 18:12:27 +0100 Subject: [PATCH 13/66] v9.9 - CHANGELOG | Remove trailing space --- CHANGELOG.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 18e5e7aeb8..a0a692feec 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -11,7 +11,7 @@ Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 - DietPi-DDNS | Resolved an issue where the YDNS update test failed due to a changed response from the server API. Many thanks to @NatureHog for reporting and solving the issue: https://github.com/MichaIng/DietPi/pull/7262 - DietPi-Software | InfluxDB: Resolved an issue where the service did not start up after the recent package upgrade. The package upgrade removes the symlink /var/lib/influxdb => /mnt/dietpi_userdata/influxdb, which is recreated with this DietPi update. Many thanks to @uwjhn for reporting this issue: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 -- DietPi-Software | Node-RED: Resolved an issue where the service failed on ARMv6 systems, since a dependency module of Node-RED v4 does not support this architecture. Node-RED v3 will now be installed on those old RPi models. Many thanks to @mvanbrab for reporting this issue: https://github.com/MichaIng/DietPi/issues/7252 +- DietPi-Software | Node-RED: Resolved an issue where the service failed on ARMv6 systems, since a dependency module of Node-RED v4 does not support this architecture. Node-RED v3 will now be installed on those old RPi models. Many thanks to @mvanbrab for reporting this issue: https://github.com/MichaIng/DietPi/issues/7252 - DietPi-Software | Chromium: Resolved an issue where optional Chromium flags via "CHROMIUM_OPTS+=" line in /var/lib/dietpi/dietpi-software/installed/chromium-autostart.sh did not have any effect, as "+=" is bash-only syntax, while the script is executed with dash (bourne shell). Many thanks to @Nurgak for reporting this issue: https://github.com/MichaIng/DietPi/issues/7263#issuecomment-2463626660 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 c9dc826f307c4f986e4625190b888c5b2eb25e8b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 9 Nov 2024 03:52:25 +0100 Subject: [PATCH 14/66] v9.9 (#7276) - DietPi-Software | MineOS: Fix install on Bookworm by using latest userid Node module version. The defined v1.0.0-beta.9 fails to build on all Bookworm systems, for unknown reasons, the latest stable v1.2.5 however builds fine. - DietPi-Software | Create again a dedicated mineos login user to manage the Minecraft servers. We switched to root, due to insufficient permissions, but I could not replicate any issues, after changing owner of /mnt/dietpi_userdata/mineos/serverdata accordingly. Apply SHA512 password algorithm for this user explicitly, as MineOS does not support the new default yescrypt: https://github.com/MichaIng/DietPi/issues/5759 - DietPi-Software | Node.js: Resolved an issue where node failed on ARMv7 Bullseye systems, since the latest version for this architecture requires a newer C++ standard library than provided on Bullseye. --- CHANGELOG.txt | 4 ++++ dietpi/dietpi-software | 26 +++++++++++++++++++------- 2 files changed, 23 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index a0a692feec..83aa4e61f2 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,6 +6,7 @@ New software: Enhancements: - DietPi-Software | NFS Server: The "fsid=0" option has been removed from the /mnt/dietpi_userdata default export. As it is uncommon and not respected in "showmount -e" export lists, it caused confusion and issues. - DietPi-Software | YaCy: The latest YaCy version will now be installed, and the global software password will be set as default admin password on fresh installs. +- DietPi-Software | MineOS: As a security enhancement and workaround for a web UI login issue, a dedicated "mineos" user is created again. For new MineOS installs or after reinstall, one can login with this user, and the global software password. It has permissions to install and manage Minecraft instances. Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 @@ -13,6 +14,9 @@ Bug fixes: - DietPi-Software | InfluxDB: Resolved an issue where the service did not start up after the recent package upgrade. The package upgrade removes the symlink /var/lib/influxdb => /mnt/dietpi_userdata/influxdb, which is recreated with this DietPi update. Many thanks to @uwjhn for reporting this issue: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 - DietPi-Software | Node-RED: Resolved an issue where the service failed on ARMv6 systems, since a dependency module of Node-RED v4 does not support this architecture. Node-RED v3 will now be installed on those old RPi models. Many thanks to @mvanbrab for reporting this issue: https://github.com/MichaIng/DietPi/issues/7252 - DietPi-Software | Chromium: Resolved an issue where optional Chromium flags via "CHROMIUM_OPTS+=" line in /var/lib/dietpi/dietpi-software/installed/chromium-autostart.sh did not have any effect, as "+=" is bash-only syntax, while the script is executed with dash (bourne shell). Many thanks to @Nurgak for reporting this issue: https://github.com/MichaIng/DietPi/issues/7263#issuecomment-2463626660 +- DietPi-Software | MineOS: Worked around an issue where the install failed on Bookworm systems, as one of the Node.js modules failed to compile for unknown reasons. Many thanks to @mikedebian for reporting this issue: https://github.com/MichaIng/DietPi/issues/7265 +- DietPi-Software | MineOS: Worked around an issue where login into the web interface failed since Bullseye, as MineOS does not support the new default yescrypt password hash algorithm for UNIX users. A new dedicated "mineos" user is now created, and its password set explicitly with SHA512 hash algorithm. Many thanks to @maybaxstv for reporting this issue: https://github.com/MichaIng/DietPi/issues/5759 +- DietPi-Software | Node.js: Resolved an issue where node failed on ARMv7 Bullseye systems, since the latest version for this architecture requires a newer C++ standard library than provided on Bullseye. 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 1b2954a593..9d78810c92 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3017,9 +3017,11 @@ unix_socket_directories = '/run/postgresql'" > "$i/00dietpi.conf" G_EXEC chmod +x node-install.sh # ARMv6/RISC-V: Use unofficial builds to get the latest version: https://github.com/MichaIng/nodejs-linux-installer/pull/2, https://github.com/MichaIng/nodejs-linux-installer/commit/cd952fe - local unofficial=() - (( $G_HW_ARCH == 1 || $G_HW_ARCH == 11 )) && unofficial=('-u') - G_EXEC_OUTPUT=1 G_EXEC ./node-install.sh "${unofficial[@]}" + local options=() + (( $G_HW_ARCH == 1 || $G_HW_ARCH == 11 )) && options=('-u') + # ARMv7 Bullseye: node: /usr/lib/arm-linux-gnueabihf/libstdc++.so.6: version `GLIBCXX_3.4.30'/'0/GLIBCXX_3.4.39' not found (required by node) + (( $G_HW_ARCH == 2 && $G_DISTRO < 7 )) && options=('-v' 'v22.11.0') + G_EXEC_OUTPUT=1 G_EXEC ./node-install.sh "${options[@]}" G_EXEC rm node-install.sh fi @@ -8433,6 +8435,9 @@ _EOF_ G_EXEC git config core.filemode false G_EXEC chmod +x mineos_console.js webui.js update_webui.sh reset_webui.sh generate-sslcert.sh + # Bookworm: Workaround for failing userid 1.0.0-beta.9 build on weirdly Bookworm only. Latest stable 1.2.5 seems to work well: https://github.com/MichaIng/DietPi/issues/7265 + G_CONFIG_INJECT '"userid"' ' "userid": "1.2.5",' package.json + # Workaround: Node.js posix needs to be installed alone first: https://github.com/MichaIng/DietPi/issues/5181 G_EXEC_OUTPUT=1 G_EXEC npm i --no-audit --no-package-lock posix@latest @@ -8453,7 +8458,7 @@ _EOF_ G_EXEC cd "$G_WORKING_DIR" # Service - cat << _EOF_ > /etc/systemd/system/mineos.service + cat << '_EOF_' > /etc/systemd/system/mineos.service [Unit] Description=MineOS (DietPi) Wants=network-online.target @@ -8463,12 +8468,19 @@ After=network-online.target SyslogIdentifier=MineOS WorkingDirectory=/mnt/dietpi_userdata/mineos/minecraft Environment="SHELL=/bin/bash" "HOME=/root" -ExecStart=$(command -v node) webui.js +ExecStart=/usr/local/bin/node webui.js KillMode=process [Install] WantedBy=multi-user.target _EOF_ + # User and permissions + local new_user=0 + getent passwd mineos &> /dev/null || new_user=1 + Create_User -d /mnt/dietpi_userdata/mineos/serverdata -p "$GLOBAL_PW" mineos + G_EXEC chown -R mineos /mnt/dietpi_userdata/mineos/serverdata + # - Assure SHA512 password hash algorithm, as MineOS does not support yescrypt, default since Bullseye: https://github.com/hexparrot/mineos-node/issues/441 + (( $new_user )) && G_EXEC eval "chpasswd --crypt-method SHA512 <<< 'mineos:$GLOBAL_PW'" fi if To_Install 46 qbittorrent # qBittorrent @@ -13598,10 +13610,10 @@ _EOF_ if To_Uninstall 53 # MineOS then - Remove_Service mineos 1 1 # User and group for pre-v6.34 + Remove_Service mineos 1 1 [[ -d '/mnt/dietpi_userdata/mineos' ]] && G_EXEC rm -R /mnt/dietpi_userdata/mineos [[ -f '/etc/mineos.conf' ]] && G_EXEC rm /etc/mineos.conf - G_EXEC rm -Rf /var/games/minecraft /usr/local/bin/mineos # Symlinks + G_EXEC rm -Rf /var/games/minecraft /usr/local/bin/mineos /etc/ssl/certs/mineos.* # Symlinks and SSL cert [[ -d '/home/mineos' ]] && G_EXEC rm -R /home/mineos # pre-v6.34 fi From adaa66e0669a93e37b30d58c8d1766f83c957ffe Mon Sep 17 00:00:00 2001 From: daniszewski <48284757+daniszewski@users.noreply.github.com> Date: Thu, 14 Nov 2024 16:24:51 +0100 Subject: [PATCH 15/66] v9.9 (#7280) - Quartz64 | Add binfmt_misc kernel module --- .build/images/Quartz64/quartz64_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/.build/images/Quartz64/quartz64_defconfig b/.build/images/Quartz64/quartz64_defconfig index c2190049f6..ff3fb6649d 100644 --- a/.build/images/Quartz64/quartz64_defconfig +++ b/.build/images/Quartz64/quartz64_defconfig @@ -36,6 +36,7 @@ CONFIG_BACKLIGHT_PWM=m CONFIG_BATTERY_SBS=m CONFIG_BCM54140_PHY=m CONFIG_BCM7XXX_PHY=m +CONFIG_BINFMT_MISC=m CONFIG_BLK_CGROUP=y CONFIG_BLK_DEV_DM=m CONFIG_BLK_DEV_LOOP=m From 5fb3b2f899aba4f9ad45ed124dd0851f71a6243f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 14 Nov 2024 21:15:59 +0100 Subject: [PATCH 16/66] v9.9 - DietPi-Drive_Manager | Resolved an issue where a mounted drive could be mistakenly detected as dietpi_userdata location. --- CHANGELOG.txt | 1 + dietpi/dietpi-drive_manager | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 83aa4e61f2..a9d663aee3 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -11,6 +11,7 @@ Enhancements: Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 - DietPi-DDNS | Resolved an issue where the YDNS update test failed due to a changed response from the server API. Many thanks to @NatureHog for reporting and solving the issue: https://github.com/MichaIng/DietPi/pull/7262 +- DietPi-Drive_Manager | Resolved an issue where a mounted drive could be mistakenly detected as dietpi_userdata location. - DietPi-Software | InfluxDB: Resolved an issue where the service did not start up after the recent package upgrade. The package upgrade removes the symlink /var/lib/influxdb => /mnt/dietpi_userdata/influxdb, which is recreated with this DietPi update. Many thanks to @uwjhn for reporting this issue: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 - DietPi-Software | Node-RED: Resolved an issue where the service failed on ARMv6 systems, since a dependency module of Node-RED v4 does not support this architecture. Node-RED v3 will now be installed on those old RPi models. Many thanks to @mvanbrab for reporting this issue: https://github.com/MichaIng/DietPi/issues/7252 - DietPi-Software | Chromium: Resolved an issue where optional Chromium flags via "CHROMIUM_OPTS+=" line in /var/lib/dietpi/dietpi-software/installed/chromium-autostart.sh did not have any effect, as "+=" is bash-only syntax, while the script is executed with dash (bourne shell). Many thanks to @Nurgak for reporting this issue: https://github.com/MichaIng/DietPi/issues/7263#issuecomment-2463626660 diff --git a/dietpi/dietpi-drive_manager b/dietpi/dietpi-drive_manager index aea801fba4..a2a6368f16 100755 --- a/dietpi/dietpi-drive_manager +++ b/dietpi/dietpi-drive_manager @@ -1039,7 +1039,7 @@ Do you wish to ignore this warning, and, mount the drive regardless?" || return G_WHIP_MENU_ARRAY+=('' '●─ Userdata & Swap options ') # User data - if [[ ( $FP_USERDATA_CURRENT == ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]}* && ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} != '/' ) || ( $FP_USERDATA_CURRENT == '/mnt/dietpi_userdata' && ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} == '/' ) ]] + if [[ ( ( $FP_USERDATA_CURRENT == ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} || $FP_USERDATA_CURRENT == ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]}/* ) && ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} != '/' ) || ( $FP_USERDATA_CURRENT == '/mnt/dietpi_userdata' && ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} == '/' ) ]] then partition_contains_userdata=1 G_WHIP_MENU_ARRAY+=('User data' ": [X] | DietPi user data is currently located on this drive") From 648ace49d29ac1e561b8a9eed11b47a99c1dd74d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 14 Nov 2024 21:29:14 +0100 Subject: [PATCH 17/66] v9.9 - DietPi-Drive_Manager | Satisfy shellcheck --- dietpi/dietpi-drive_manager | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-drive_manager b/dietpi/dietpi-drive_manager index a2a6368f16..251c1ef496 100755 --- a/dietpi/dietpi-drive_manager +++ b/dietpi/dietpi-drive_manager @@ -1039,7 +1039,7 @@ Do you wish to ignore this warning, and, mount the drive regardless?" || return G_WHIP_MENU_ARRAY+=('' '●─ Userdata & Swap options ') # User data - if [[ ( ( $FP_USERDATA_CURRENT == ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} || $FP_USERDATA_CURRENT == ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]}/* ) && ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} != '/' ) || ( $FP_USERDATA_CURRENT == '/mnt/dietpi_userdata' && ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} == '/' ) ]] + if [[ ( ( $FP_USERDATA_CURRENT == "${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]}" || $FP_USERDATA_CURRENT == "${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]}/"* ) && ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} != '/' ) || ( $FP_USERDATA_CURRENT == '/mnt/dietpi_userdata' && ${aDRIVE_MOUNT_TARGET[$MENU_DRIVE_INDEX]} == '/' ) ]] then partition_contains_userdata=1 G_WHIP_MENU_ARRAY+=('User data' ": [X] | DietPi user data is currently located on this drive") From 492b8f722a49494539038175d3479247949640b7 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 15 Nov 2024 14:48:35 +0100 Subject: [PATCH 18/66] v9.9 - DietPi-Imager | Do not compress ISO images, as flashing tools do not support it,without extraction, and the size reduction is minimal - DietPi-Build | Build VM ISO installer image as well, if all VM types are requested. --- .build/images/dietpi-build | 9 +++++++++ .build/images/dietpi-imager | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 3b07e2c463..50269ea97b 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -722,6 +722,15 @@ fi # Since qemu-img does not support VMDK and VHDX resizing, we need to resize the raw .img. It is usually done as sparse file, hence the actual disk usage does not change. G_EXEC qemu-img resize "$OUTPUT_IMG_NAME.img" 8G +####### ISO ############################## +if [[ $VMTYPE == all ]] +then + CLONING_TOOL='Clonezilla' OUTPUT_IMG_NAME="${OUTPUT_IMG_NAME}_Installer" + G_DIETPI-NOTIFY 2 "Running DietPi-Imager for $G_GITOWNER/$G_GITBRANCH" + bash -c "$(curl -sSf "https://raw.githubusercontent.com/$G_GITOWNER/DietPi/$G_GITBRANCH/.build/images/dietpi-imager")" 'DietPi-Imager' "${IMAGER_ARGS[@]}" || exit 1 + CLONING_TOOL='dd' OUTPUT_IMG_NAME=${OUTPUT_IMG_NAME%_Installer} +fi + ####### VMX/VMware/Parallels ############# if [[ $VMTYPE =~ ^(vmx|all)$ ]] then diff --git a/.build/images/dietpi-imager b/.build/images/dietpi-imager index 8557a0fc97..af0885f60c 100755 --- a/.build/images/dietpi-imager +++ b/.build/images/dietpi-imager @@ -322,7 +322,7 @@ G_DIETPI-NOTIFY 0 "Mounted the image ($FP_SOURCE_IMG) as loopback device: $FP_SOURCE" FP_ROOT_DEV="${FP_SOURCE}p${FP_ROOT_DEV: -1}" fi - [[ $CLONING_TOOL == 'dd' ]] && OUTPUT_IMG_EXT='img' || OUTPUT_IMG_EXT='iso' + [[ $CLONING_TOOL == 'dd' ]] && OUTPUT_IMG_EXT='img' || OUTPUT_IMG_EXT='iso' SKIP_ARCHIVE=1 # Flashing tools do not support xz-compressed ISOs G_DIETPI-NOTIFY 0 "\e[0mCreating minified image from: - $SOURCE_TYPE: ${FP_SOURCE_IMG:-$FP_SOURCE} - Root device: $FP_ROOT_DEV From 2cdc13c82588ceb24df482bbcd11fdaa7ea23ff1 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 19 Nov 2024 23:33:51 +0100 Subject: [PATCH 19/66] v9.9 - DietPi-FS_partition_resize | Do not reload systemd when disabling/enabling this service, as it is relevant for next boot only, and the reload is time intense --- rootfs/var/lib/dietpi/services/fs_partition_resize.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rootfs/var/lib/dietpi/services/fs_partition_resize.sh b/rootfs/var/lib/dietpi/services/fs_partition_resize.sh index f806c7f808..9b7586df92 100755 --- a/rootfs/var/lib/dietpi/services/fs_partition_resize.sh +++ b/rootfs/var/lib/dietpi/services/fs_partition_resize.sh @@ -7,7 +7,7 @@ Reboot_to_load_Partition_table() { > /dietpi_skip_partition_resize - systemctl enable dietpi-fs_partition_resize + systemctl --no-reload enable dietpi-fs_partition_resize echo '[ INFO ] Rebooting to load the new partition table' sync reboot @@ -15,7 +15,7 @@ } # Disable this service - ! systemctl is-enabled dietpi-fs_partition_resize > /dev/null || systemctl disable dietpi-fs_partition_resize + ! systemctl is-enabled dietpi-fs_partition_resize > /dev/null || systemctl --no-reload disable dietpi-fs_partition_resize # Detect root device ROOT_DEV=$(findmnt -Ufnro SOURCE -M /) From b2607b293a453b6310e2cf04fa08fb5850d319c5 Mon Sep 17 00:00:00 2001 From: Dis <397465+disconn3ct@users.noreply.github.com> Date: Tue, 19 Nov 2024 22:45:21 +0000 Subject: [PATCH 20/66] v9.9 (#7184) - Quartz64 | Enable further kernel features, needed for Calico networking --- .build/images/Quartz64/quartz64_defconfig | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.build/images/Quartz64/quartz64_defconfig b/.build/images/Quartz64/quartz64_defconfig index ff3fb6649d..a8a3aafb34 100644 --- a/.build/images/Quartz64/quartz64_defconfig +++ b/.build/images/Quartz64/quartz64_defconfig @@ -89,6 +89,7 @@ CONFIG_CGROUP_DEVICE=y CONFIG_CGROUP_FREEZER=y CONFIG_CGROUP_HUGETLB=y CONFIG_CGROUP_MISC=y +CONFIG_CGROUP_NET_PRIO=y CONFIG_CGROUP_PERF=y CONFIG_CGROUP_PIDS=y CONFIG_CHARGER_RK817=y @@ -138,6 +139,7 @@ CONFIG_CRYPTO_ECDH=y CONFIG_CRYPTO_ECHAINIV=y CONFIG_CRYPTO_GHASH_ARM64_CE=y CONFIG_CRYPTO_MD4=y +CONFIG_CRYPTO_SEQIV=m CONFIG_CRYPTO_SHA1_ARM64_CE=y CONFIG_CRYPTO_SHA2_ARM64_CE=y CONFIG_CRYPTO_SHA3_ARM64=m @@ -311,8 +313,10 @@ CONFIG_IP_MULTICAST=y CONFIG_IP_NF_FILTER=m CONFIG_IP_NF_IPTABLES=m CONFIG_IP_NF_MANGLE=m +CONFIG_IP_NF_MATCH_RPFILTER=m CONFIG_IP_NF_NAT=m CONFIG_IP_NF_TARGET_MASQUERADE=m +CONFIG_IP_NF_TARGET_REDIRECT=m CONFIG_IP_NF_TARGET_REJECT=m CONFIG_IP_NF_TARGET_SYNPROXY=m CONFIG_IP_PNP=y @@ -337,6 +341,10 @@ CONFIG_IP_SET_HASH_NETPORTNET=m CONFIG_IP_SET_LIST_SET=m CONFIG_IP_SET_MAX=256 CONFIG_IP_VS=m +CONFIG_IP_VS_PROTO_TCP=y +CONFIG_IP_VS_PROTO_UDP=y +CONFIG_IP_VS_RR=m +CONFIG_IP_VS_NFCT=y CONFIG_IRQ_TIME_ACCOUNTING=y CONFIG_ISCSI_TCP=m CONFIG_IXGB=y @@ -549,6 +557,7 @@ CONFIG_NET_ACT_MIRRED=m CONFIG_NET_CLS_ACT=y CONFIG_NET_CLS_BPF=m CONFIG_NET_CLS_BASIC=m +CONFIG_NET_CLS_CGROUP=m CONFIG_NET_CLS_FLOWER=m CONFIG_NET_DSA=m CONFIG_NET_SCHED=y @@ -1123,3 +1132,8 @@ CONFIG_ZSWAP=y CONFIG_ZSWAP_COMPRESSOR_DEFAULT_ZSTD=y CONFIG_ZSWAP_DEFAULT_ON=y CONFIG_ZSWAP_ZPOOL_DEFAULT_ZSMALLOC=y +CONFIG_INET_ESP=m +CONFIG_XFRM_USER=m +CONFIG_XFRM=y +CONFIG_XFRM_ALGO=m +CONFIG_XFRM_ESP=m From 845990d65bf809c3a1f832270e8038b9dafe6e2b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 20 Nov 2024 00:04:13 +0100 Subject: [PATCH 21/66] v9.9 - CI | Quartz64: Add libuuid headers, needed until U-Boot v2025.01 --- .github/workflows/quartz64.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/quartz64.yml b/.github/workflows/quartz64.yml index f9687c86dc..579ed570be 100644 --- a/.github/workflows/quartz64.yml +++ b/.github/workflows/quartz64.yml @@ -17,11 +17,12 @@ jobs: python-version: '3.x' check-latest: true - name: Build init + # uuid-dev needed only until U-Boot v2025.01: https://github.com/u-boot/u-boot/commit/322c813 run: | # Workaround for runner provider restart: https://github.com/actions/runner-images/pull/9956 sudo apt-get -qq autopurge needrestart { python3 -m pip install --no-cache-dir -U pip setuptools wheel; python3 -m pip install --no-cache-dir -U pyelftools; } & - { sudo apt-get -q update; sudo DEBIAN_FRONTEND=noninteractive apt-get --no-install-recommends -qq install make gcc libc6-dev flex bison gcc-aarch64-linux-gnu bc libssl-dev swig; } & + { sudo apt-get -q update; sudo DEBIAN_FRONTEND=noninteractive apt-get --no-install-recommends -qq install make gcc libc6-dev flex bison gcc-aarch64-linux-gnu bc libssl-dev swig uuid-dev; } & { curl -fO 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/snapshot/linux-rolling-stable.tar.gz'; tar xf linux-rolling-stable.tar.gz; rm linux-rolling-stable.tar.gz; } & uboot_version=$(curl -sSf 'https://api.github.com/repos/u-boot/u-boot/tags' | mawk -F\" '/^ *"name": "v[0-9.]*",$/{print $4;exit}') [ "$uboot_version" ] || { echo 'ERROR: Failed to obtain latest U-Boot version'; exit 1; } From 3c3051f04a587c617c2f68e302f1750a3053dade Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 20 Nov 2024 00:14:39 +0100 Subject: [PATCH 22/66] v9.9 - CI | Quartz64: Add newly needed GnuTLS headers, likely caused by this U-Boot commit, since v2024.10: https://github.com/u-boot/u-boot/commit/b7a625b --- .github/workflows/quartz64.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/quartz64.yml b/.github/workflows/quartz64.yml index 579ed570be..5c2c481011 100644 --- a/.github/workflows/quartz64.yml +++ b/.github/workflows/quartz64.yml @@ -22,7 +22,7 @@ jobs: # Workaround for runner provider restart: https://github.com/actions/runner-images/pull/9956 sudo apt-get -qq autopurge needrestart { python3 -m pip install --no-cache-dir -U pip setuptools wheel; python3 -m pip install --no-cache-dir -U pyelftools; } & - { sudo apt-get -q update; sudo DEBIAN_FRONTEND=noninteractive apt-get --no-install-recommends -qq install make gcc libc6-dev flex bison gcc-aarch64-linux-gnu bc libssl-dev swig uuid-dev; } & + { sudo apt-get -q update; sudo DEBIAN_FRONTEND=noninteractive apt-get --no-install-recommends -qq install make gcc libc6-dev flex bison gcc-aarch64-linux-gnu bc libssl-dev swig uuid-dev libgnutls28-dev; } & { curl -fO 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/snapshot/linux-rolling-stable.tar.gz'; tar xf linux-rolling-stable.tar.gz; rm linux-rolling-stable.tar.gz; } & uboot_version=$(curl -sSf 'https://api.github.com/repos/u-boot/u-boot/tags' | mawk -F\" '/^ *"name": "v[0-9.]*",$/{print $4;exit}') [ "$uboot_version" ] || { echo 'ERROR: Failed to obtain latest U-Boot version'; exit 1; } From 5d9290dbfdf99bfef9b12685e88e8ac47b0f6c03 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 20 Nov 2024 01:28:17 +0100 Subject: [PATCH 23/66] v9.9 - DietPi-Installer | Support test kernel isntalls for Quartz64 --- .build/images/dietpi-installer | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 5216874c02..ddc80d4a2d 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1171,7 +1171,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 or is not available + # Install testing kernel build if requested if (( $TEST_KERNEL )) then G_EXEC_OUTPUT=1 G_EXEC curl -fo package1.deb "https://dietpi.com/downloads/binaries/testing/linux-image-$branch-$kernel.deb" @@ -1180,7 +1180,7 @@ _EOF_ 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 + # Install testing U-Boot build if requested if (( $TEST_UBOOT )) then G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/testing/linux-u-boot-$model-$branch.deb" @@ -1304,7 +1304,15 @@ _EOF_ 3) variant='soquartz';; *) variant='quartz64a';; esac - G_AGI "firmware-$variant" + # Install testing kernel build if requested + if (( $TEST_KERNEL )) + then + G_EXEC_OUTPUT=1 G_EXEC curl -fo package.deb "https://dietpi.com/downloads/binaries/testing/firmware-$variant.deb" + G_EXEC_OUTPUT=1 G_EXEC dpkg -i package.deb + G_EXEC rm package.deb + else + G_AGI "firmware-$variant" + fi # 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 )) From fb955efaa3bac8bdc21294e7437728cb5af34144 Mon Sep 17 00:00:00 2001 From: chelobarik Date: Fri, 22 Nov 2024 00:18:01 +0500 Subject: [PATCH 24/66] v9.9 (#7282) - DietPi-Software | Samba Server: Removing deprecated parameters from smb.conf --- .conf/dps_96/conf | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.conf/dps_96/conf b/.conf/dps_96/conf index 88da88576f..4f287722f6 100644 --- a/.conf/dps_96/conf +++ b/.conf/dps_96/conf @@ -5,13 +5,11 @@ dns proxy = no log file = /var/log/samba/log.%m max log size = 1000 - syslog only = no - syslog = 0 + logging = syslog@1 panic action = /usr/share/samba/panic-action %d security = user - encrypt passwords = true passdb backend = tdbsam obey pam restrictions = yes unix password sync = yes From 6533fdb13c5a49632bf89b31e3972b193301f4b5 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 21 Nov 2024 21:09:16 +0100 Subject: [PATCH 25/66] v9.9 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 9d78810c92..1fbb10b82c 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8243,7 +8243,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.10.0/baikal-0.10.0.zip' + local fallback_url='https://github.com/sabre-io/Baikal/releases/download/0.10.1/baikal-0.10.1.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/ @@ -9581,7 +9581,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.14.0.9383/Radarr.master.5.14.0.9383.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.15.1.9463/Radarr.master.5.15.1.9463.linux-core-$arch.tar.gz" fi Download_Install "$url" @@ -9948,7 +9948,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.3/nzbget-24.3-bin-linux.run' + local fallback_url='https://github.com/nzbgetcom/nzbget/releases/download/v24.4/nzbget-24.4-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 @@ -10027,7 +10027,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.25.4.4818/Prowlarr.master.1.25.4.4818.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.26.1.4844/Prowlarr.master.1.26.1.4844.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 @@ -11257,7 +11257,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.1.3/tasmoadmin_v4.1.3.tar.gz' + local fallback_url='https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v4.2.0/tasmoadmin_v4.2.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' @@ -11714,7 +11714,7 @@ _EOF_ *) local arch='amd64';; esac - local fallback_url="https://github.com/rclone/rclone/releases/download/v1.68.1/rclone-v1.68.1-linux-$arch.deb" + local fallback_url="https://github.com/rclone/rclone/releases/download/v1.68.2/rclone-v1.68.2-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 @@ -11728,7 +11728,7 @@ _EOF_ *) local arch='arm';; esac - local fallback_url="https://github.com/restic/restic/releases/download/v0.17.2/restic_0.17.2_linux_$arch.bz2" + local fallback_url="https://github.com/restic/restic/releases/download/v0.17.3/restic_0.17.3_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 2135baa76bcc28cd73f5d2ee60519a45bcaa03d5 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 21 Nov 2024 21:49:14 +0100 Subject: [PATCH 26/66] v9.9 - Orange Pi 5 Pro | Support for this new variant of the Orange Pi 5 family has been added to DietPi. --- .build/images/dietpi-build | 1 + .build/images/dietpi-installer | 14 ++++++++------ .github/workflows/dietpi-build.yml | 3 ++- .meta/dietpi-survey_report | 1 + CHANGELOG.txt | 3 ++- dietpi/func/dietpi-obtain_hw_model | 8 +++++++- dietpi/func/dietpi-set_hardware | 2 +- 7 files changed, 22 insertions(+), 10 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 50269ea97b..a62ea0ab03 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -163,6 +163,7 @@ case $HW_MODEL in 90) iname='RadxaZERO3' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;; 91) iname='OrangePi5Max' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;; 92) iname='NanoPiM6' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;; + 93) iname='OrangePi5Pro' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;; *) 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 ddc80d4a2d..b5b714ce80 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -428,7 +428,8 @@ _EOF_ '85' ': ROCK 5A' '87' ': Orange Pi 3B' '89' ': Orange Pi 3 LTS' - '80' ': Orange Pi 5' + '80' ': Orange Pi 5/5B' + '93' ': Orange Pi 5 Pro' '82' ': Orange Pi 5 Plus' '91' ': Orange Pi 5 Max' '83' ': Orange Pi Zero 3' @@ -630,7 +631,7 @@ _EOF_ G_EXEC mv "$dir/.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|88|89|90|91|92)$ ]] + 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|91|92|93)$ ]] then armbian_packages=1 G_EXEC mv "$dir/.build/images/U-Boot/boot.cmd" /boot/boot.cmd @@ -671,7 +672,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|90|91|92)$ ]] + elif [[ $G_HW_MODEL =~ ^(42|43|46|47|55|56|58|68|72|73|76|77|78|79|80|82|85|86|87|90|91|92|93)$ ]] 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 @@ -704,14 +705,14 @@ setenv rootuuid "true"' /boot/boot.cmd # Overlay prefix case $G_HW_MODEL in 73) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=rk3308' /boot/dietpiEnv.txt;; - 78|79|80|82|85|91|92) 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|91|92|93) 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 # Console args 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|79|80|82|85|91|92) G_EXEC sed --follow-symlinks -i 's/ttyAML0,115200/ttyFIQ0,1500000/' /boot/dietpiEnv.txt;; # RK3588 + 78|79|80|82|85|91|92|93) 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 @@ -1144,6 +1145,7 @@ _EOF_ 90) model='radxa-zero3' kernel='rk35xx' branch='legacy';; 91) model='orangepi5-max' kernel='rk35xx' branch='vendor';; 92) model='nanopi-m6' kernel='rk35xx' branch='vendor';; + 93) model='orangepi5pro' kernel='rk35xx' branch='vendor';; *) :;; esac @@ -1974,7 +1976,7 @@ _EOF_' /boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyS1 # Rockchip vendor/legacy: 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|91|92)$ ]] + elif [[ $G_HW_MODEL =~ ^(78|79|80|82|85|90|91|92|93)$ ]] 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 f982745cfb..af3f1ee8ac 100644 --- a/.github/workflows/dietpi-build.yml +++ b/.github/workflows/dietpi-build.yml @@ -95,7 +95,8 @@ jobs: '"-m 89 -d 6", "-m 89 -d 7", "-m 89 -d 8", '\ '"-m 90 -d 6", "-m 90 -d 7", "-m 90 -d 8", '\ '"-m 91 -d 6", "-m 91 -d 7", "-m 91 -d 8", '\ - '"-m 92 -d 6", "-m 92 -d 7", "-m 92 -d 8"]' >> "$GITHUB_OUTPUT" + '"-m 92 -d 6", "-m 92 -d 7", "-m 92 -d 8", '\ + '"-m 93 -d 6", "-m 93 -d 7", "-m 93 -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 8d0d36a6d2..a12747d60f 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -97,6 +97,7 @@ shopt -s extglob [90]='Radxa ZERO 3' [91]='Orange Pi 5 Max' [92]='NanoPi M6' + [93]='Orange Pi 5 Pro' ) ## Benchmark data arrays: aBENCH_XX[$HW_MODEL,${aBENCH_XX_INDEX[$HW_MODEL]}] diff --git a/CHANGELOG.txt b/CHANGELOG.txt index a9d663aee3..cae63263bc 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,7 +1,8 @@ v9.9 (2024-11-16) -New software: +New images: +- Orange Pi 5 Pro | Support for this new variant of the Orange Pi 5 family has been added to DietPi. Enhancements: - DietPi-Software | NFS Server: The "fsid=0" option has been removed from the /mnt/dietpi_userdata default export. As it is uncommon and not respected in "showmount -e" export lists, it caused confusion and issues. diff --git a/dietpi/func/dietpi-obtain_hw_model b/dietpi/func/dietpi-obtain_hw_model index b7876fd05e..1074f57cd3 100755 --- a/dietpi/func/dietpi-obtain_hw_model +++ b/dietpi/func/dietpi-obtain_hw_model @@ -12,6 +12,7 @@ # - Generates /boot/dietpi/.hw_model # - Called from /boot/dietpi/preboot, called by /etc/systemd/system/dietpi-preboot.service # + # G_HW_MODEL 93 Orange Pi 5 Pro # G_HW_MODEL 92 NanoPi M6 # G_HW_MODEL 91 Orange Pi 5 Max # G_HW_MODEL 90 Radxa ZERO 3 @@ -368,7 +369,12 @@ G_HW_MODEL=$(mawk 'NR==1' "$FP_G_HW_MODEL_IDENTIFIER") - if (( $G_HW_MODEL == 92 )); then + if (( $G_HW_MODEL == 93 )); then + + G_HW_MODEL_NAME='Orange Pi 5 Pro' + G_HW_CPUID=11 + + elif (( $G_HW_MODEL == 92 )); then G_HW_MODEL_NAME='NanoPi M6' G_HW_CPUID=11 diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index 5f48bc73c5..fabf208a12 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -1524,7 +1524,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|78|79|80|82|85|87|90|91|92)$ && $INPUT_ADDITIONAL =~ ^('ttyS2'|'ttyFIQ0')$ ]] || [[ $G_HW_MODEL == 73 && $INPUT_ADDITIONAL == 'ttyS'[012] ]] + if [[ $G_HW_MODEL =~ ^(42|43|46|47|49|55|56|58|68|72|76|77|78|79|80|82|85|87|90|91|92|93)$ && $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" From 963614678e2e34b32f8c2ae0419b566018b64b83 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 21 Nov 2024 22:18:13 +0100 Subject: [PATCH 27/66] v9.9 - CHANGELOG | Complement new SBC support --- CHANGELOG.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index cae63263bc..a0b004dc67 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,7 +2,9 @@ v9.9 (2024-11-16) New images: +- Orange Pi 5 Max | Support for this new variant of the Orange Pi 5 family has been added to DietPi. - Orange Pi 5 Pro | Support for this new variant of the Orange Pi 5 family has been added to DietPi. +- NanoPi M6 | Support for this FriendlyELEC SBC with RK3588 SoC has been added to DietPi. Enhancements: - DietPi-Software | NFS Server: The "fsid=0" option has been removed from the /mnt/dietpi_userdata default export. As it is uncommon and not respected in "showmount -e" export lists, it caused confusion and issues. From 850ba05dc6e4b536449f23cabfdbc3623b97f2b8 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 21 Nov 2024 23:24:48 +0100 Subject: [PATCH 28/66] v9.9 - DietPi-Set_software | APT: Add support for Orange Pi 5 Pro --- dietpi/func/dietpi-set_software | 1 + 1 file changed, 1 insertion(+) diff --git a/dietpi/func/dietpi-set_software b/dietpi/func/dietpi-set_software index 0a812b7b8e..ac6c45dbc0 100755 --- a/dietpi/func/dietpi-set_software +++ b/dietpi/func/dietpi-set_software @@ -296,6 +296,7 @@ $FP_SCRIPT rpi_kernel_choice Supported on Debian Bookworm or newer on R 90) all_components='radxazero3';; 91) all_components='orangepi5max';; 92) all_components='nanopim6';; + 93) all_components='orangepi5pro';; *) :;; esac G_EXEC eval "echo 'deb https://dietpi.com/apt $G_DISTRO_NAME $components' > /etc/apt/sources.list.d/dietpi.list" From 6b83f467a0df271978bb5b7ba370dc164d5e08cb Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 22 Nov 2024 00:09:08 +0100 Subject: [PATCH 29/66] v9.9 - DietPi-Build | Raise size for Orange Pi 5 Pro image --- .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 a62ea0ab03..1c850759cd 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -163,7 +163,7 @@ case $HW_MODEL in 90) iname='RadxaZERO3' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;; 91) iname='OrangePi5Max' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;; 92) iname='NanoPiM6' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;; - 93) iname='OrangePi5Pro' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;; + 93) iname='OrangePi5Pro' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1200;; *) G_DIETPI-NOTIFY 1 "Invalid hardware model \"$HW_MODEL\" passed, aborting..."; exit 1;; esac From 684cc601424f08e09999c60cfa2ae50d13b422b2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 22 Nov 2024 16:28:10 +0100 Subject: [PATCH 30/66] v9.9 - Quartz64 | Add support for netlink routing tables --- .build/images/Quartz64/quartz64_defconfig | 129 +++------------------- 1 file changed, 13 insertions(+), 116 deletions(-) diff --git a/.build/images/Quartz64/quartz64_defconfig b/.build/images/Quartz64/quartz64_defconfig index a8a3aafb34..d99fec07e1 100644 --- a/.build/images/Quartz64/quartz64_defconfig +++ b/.build/images/Quartz64/quartz64_defconfig @@ -66,7 +66,6 @@ CONFIG_BT_BNEP_MC_FILTER=y CONFIG_BT_BNEP_PROTO_FILTER=y CONFIG_BT_HCIBTSDIO=m CONFIG_BT_HCIBTUSB=m -# CONFIG_BT_HCIBTUSB_BCM is not set CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_BCM=y CONFIG_BT_HCIUART_LL=y @@ -102,9 +101,7 @@ CONFIG_COMMON_CLK_RK808=y CONFIG_COMMON_CLK_SCMI=y CONFIG_COMMON_CLK_SCPI=y CONFIG_COMPAT_32BIT_TIME=y -# CONFIG_COMPAT_BRK is not set CONFIG_CONSOLE_LOGLEVEL_DEFAULT=15 -# CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS is not set CONFIG_CPUFREQ_DT=y CONFIG_CPUSETS=y CONFIG_CPU_FREQ=y @@ -193,7 +190,6 @@ CONFIG_DRM_SII902X=m CONFIG_DRM_SIMPLE_BRIDGE=m CONFIG_DRM_THINE_THC63LVD1024=m CONFIG_DRM_TI_SN65DSI86=m -# CONFIG_DVB_NET is not set CONFIG_DWMAC_DWC_QOS_ETH=y CONFIG_DW_DMAC=m CONFIG_DW_DMAC_PCI=m @@ -223,7 +219,6 @@ CONFIG_FANOTIFY_ACCESS_PERMISSIONS=y CONFIG_FB=y CONFIG_FB_SIMPLE=y CONFIG_FM10K=y -# CONFIG_FSL_ERRATUM_A008585 is not set CONFIG_FUNCTION_PROFILER=y CONFIG_FUNCTION_TRACER=y CONFIG_FUSE_FS=y @@ -241,26 +236,18 @@ CONFIG_GPIO_PL061=y CONFIG_GPIO_SYSCON=y CONFIG_GPIO_XGENE=y CONFIG_HIBERNATION=y -# CONFIG_HID_A4TECH is not set -# CONFIG_HID_APPLE is not set +CONFIG_HIDRAW=y CONFIG_HID_BATTERY_STRENGTH=y -# CONFIG_HID_BELKIN is not set -# CONFIG_HID_EZKEY is not set -# CONFIG_HID_ITE is not set -# CONFIG_HID_KENSINGTON is not set CONFIG_HID_LOGITECH_HIDPP=m CONFIG_HID_MICROSOFT=m CONFIG_HID_MONTEREY=m CONFIG_HID_MULTITOUCH=y CONFIG_HID_REDRAGON=m -CONFIG_HIDRAW=y CONFIG_HIGH_RES_TIMERS=y -# CONFIG_HISILICON_ERRATUM_161010101 is not set CONFIG_HOTPLUG_PCI=y CONFIG_HOTPLUG_PCI_ACPI=y CONFIG_HUGETLBFS=y CONFIG_HWSPINLOCK=y -# CONFIG_HW_RANDOM_CN10K is not set CONFIG_I2C_CHARDEV=y CONFIG_I2C_DESIGNWARE_PLATFORM=y CONFIG_I2C_GPIO=m @@ -285,6 +272,7 @@ CONFIG_IKCONFIG=y CONFIG_IKCONFIG_PROC=y CONFIG_INDIRECT_PIO=y CONFIG_INET=y +CONFIG_INET_ESP=m CONFIG_INPUT_EVDEV=y CONFIG_INPUT_FF_MEMLESS=y CONFIG_INPUT_MATRIXKMAP=y @@ -309,7 +297,9 @@ CONFIG_IPMI_HANDLER=m CONFIG_IPMI_SI=m CONFIG_IPV6=y CONFIG_IPV6_SIT=n +CONFIG_IP_ADVANCED_ROUTER=y CONFIG_IP_MULTICAST=y +CONFIG_IP_MULTIPLE_TABLES=y CONFIG_IP_NF_FILTER=m CONFIG_IP_NF_IPTABLES=m CONFIG_IP_NF_MANGLE=m @@ -341,10 +331,10 @@ CONFIG_IP_SET_HASH_NETPORTNET=m CONFIG_IP_SET_LIST_SET=m CONFIG_IP_SET_MAX=256 CONFIG_IP_VS=m +CONFIG_IP_VS_NFCT=y CONFIG_IP_VS_PROTO_TCP=y CONFIG_IP_VS_PROTO_UDP=y CONFIG_IP_VS_RR=m -CONFIG_IP_VS_NFCT=y CONFIG_IRQ_TIME_ACCOUNTING=y CONFIG_ISCSI_TCP=m CONFIG_IXGB=y @@ -421,7 +411,6 @@ CONFIG_MEMORY_FAILURE=y CONFIG_MEMTEST=y CONFIG_MFD_RK8XX_I2C=y CONFIG_MFD_RK8XX_SPI=y -# CONFIG_MFD_VEXPRESS_SYSREG is not set CONFIG_MHI_WWAN_MBIM=m CONFIG_MICREL_PHY=y CONFIG_MICROSEMI_PHY=y @@ -555,8 +544,8 @@ CONFIG_NET_ACT_GACT=m CONFIG_NET_ACT_GATE=m CONFIG_NET_ACT_MIRRED=m CONFIG_NET_CLS_ACT=y -CONFIG_NET_CLS_BPF=m CONFIG_NET_CLS_BASIC=m +CONFIG_NET_CLS_BPF=m CONFIG_NET_CLS_CGROUP=m CONFIG_NET_CLS_FLOWER=m CONFIG_NET_DSA=m @@ -566,76 +555,16 @@ CONFIG_NET_SCH_ETF=m CONFIG_NET_SCH_INGRESS=m CONFIG_NET_SCH_MQPRIO=m CONFIG_NET_SCH_TAPRIO=m -# CONFIG_NET_VENDOR_3COM is not set -# CONFIG_NET_VENDOR_ADAPTEC is not set -# CONFIG_NET_VENDOR_AGERE is not set -# CONFIG_NET_VENDOR_ALACRITECH is not set -# CONFIG_NET_VENDOR_ALTEON is not set -# CONFIG_NET_VENDOR_AMAZON is not set -# CONFIG_NET_VENDOR_AMD is not set -# CONFIG_NET_VENDOR_AQUANTIA is not set -# CONFIG_NET_VENDOR_ARC is not set -# CONFIG_NET_VENDOR_ASIX is not set -# CONFIG_NET_VENDOR_ATHEROS is not set -# CONFIG_NET_VENDOR_BROADCOM is not set -# CONFIG_NET_VENDOR_BROCADE is not set -# CONFIG_NET_VENDOR_CADENCE is not set -# CONFIG_NET_VENDOR_CAVIUM is not set -# CONFIG_NET_VENDOR_CHELSIO is not set -# CONFIG_NET_VENDOR_CISCO is not set -# CONFIG_NET_VENDOR_CORTINA is not set -# CONFIG_NET_VENDOR_DEC is not set -# CONFIG_NET_VENDOR_DLINK is not set -# CONFIG_NET_VENDOR_EMULEX is not set -# CONFIG_NET_VENDOR_ENGLEDER is not set -# CONFIG_NET_VENDOR_EZCHIP is not set -# CONFIG_NET_VENDOR_GOOGLE is not set -# CONFIG_NET_VENDOR_HISILICON is not set -# CONFIG_NET_VENDOR_HUAWEI is not set -# CONFIG_NET_VENDOR_LITEX is not set -# CONFIG_NET_VENDOR_MARVELL is not set -# CONFIG_NET_VENDOR_MELLANOX is not set -# CONFIG_NET_VENDOR_MICREL is not set -# CONFIG_NET_VENDOR_MICROCHIP is not set -# CONFIG_NET_VENDOR_MICROSEMI is not set -# CONFIG_NET_VENDOR_MICROSOFT is not set -# CONFIG_NET_VENDOR_MYRI is not set -# CONFIG_NET_VENDOR_NATSEMI is not set -# CONFIG_NET_VENDOR_NETERION is not set -# CONFIG_NET_VENDOR_NETRONOME is not set -# CONFIG_NET_VENDOR_NI is not set -# CONFIG_NET_VENDOR_NVIDIA is not set -# CONFIG_NET_VENDOR_OKI is not set -# CONFIG_NET_VENDOR_PENSANDO is not set -# CONFIG_NET_VENDOR_QLOGIC is not set -# CONFIG_NET_VENDOR_QUALCOMM is not set -# CONFIG_NET_VENDOR_RDC is not set -# CONFIG_NET_VENDOR_RENESAS is not set -# CONFIG_NET_VENDOR_ROCKER is not set -# CONFIG_NET_VENDOR_SAMSUNG is not set -# CONFIG_NET_VENDOR_SEEQ is not set -# CONFIG_NET_VENDOR_SILAN is not set -# CONFIG_NET_VENDOR_SIS is not set -# CONFIG_NET_VENDOR_SMSC is not set -# CONFIG_NET_VENDOR_SOCIONEXT is not set -# CONFIG_NET_VENDOR_SOLARFLARE is not set -# CONFIG_NET_VENDOR_SUN is not set -# CONFIG_NET_VENDOR_TEHUTI is not set -# CONFIG_NET_VENDOR_TI is not set -# CONFIG_NET_VENDOR_VERTEXCOM is not set -# CONFIG_NET_VENDOR_VIA is not set -# CONFIG_NET_VENDOR_WIZNET is not set -# CONFIG_NET_VENDOR_XILINX is not set CONFIG_NEW_LEDS=y CONFIG_NFC=m CONFIG_NFC_NCI=m CONFIG_NFC_S3FWRN5_I2C=m +CONFIG_NFSD=m +CONFIG_NFSD_V4=y CONFIG_NFS_FS=y CONFIG_NFS_V4=y CONFIG_NFS_V4_1=y CONFIG_NFS_V4_2=y -CONFIG_NFSD=m -CONFIG_NFSD_V4=y CONFIG_NFT_BRIDGE_META=m CONFIG_NFT_BRIDGE_REJECT=m CONFIG_NFT_COMPAT=m @@ -666,7 +595,6 @@ CONFIG_NFT_REJECT=m CONFIG_NFT_REJECT_INET=m CONFIG_NFT_REJECT_IPV4=m CONFIG_NFT_REJECT_IPV6=m -# CONFIG_NFT_REJECT_NETDEV is not set CONFIG_NFT_SOCKET=m CONFIG_NFT_SYNPROXY=m CONFIG_NFT_TPROXY=m @@ -743,6 +671,7 @@ CONFIG_NTFS3_LZX_XPRESS=y CONFIG_NUMA=y CONFIG_NUMA_BALANCING=y CONFIG_NVMEM_RMEM=m +CONFIG_NVMEM_ROCKCHIP_EFUSE=y CONFIG_NVME_HWMON=y CONFIG_OF_OVERLAY=y CONFIG_OPTEE=y @@ -813,7 +742,6 @@ CONFIG_REMOTEPROC_CDEV=y CONFIG_RFKILL=y CONFIG_ROCKCHIP_DW_HDMI=y CONFIG_ROCKCHIP_DW_MIPI_DSI=y -CONFIG_NVMEM_ROCKCHIP_EFUSE=y CONFIG_ROCKCHIP_INNO_HDMI=y CONFIG_ROCKCHIP_IODOMAIN=y CONFIG_ROCKCHIP_IOMMU=y @@ -858,13 +786,11 @@ CONFIG_SATA_MV=y CONFIG_SATA_SIL24=y CONFIG_SCHEDSTATS=y CONFIG_SCHED_AUTOGROUP=y -# CONFIG_SCHED_DEBUG is not set CONFIG_SCHED_MC=y CONFIG_SCHED_SMT=y CONFIG_SCSI_HISI_SAS=y CONFIG_SCSI_HISI_SAS_PCI=y CONFIG_SCSI_MPT3SAS=m -# CONFIG_SCSI_PROC_FS is not set CONFIG_SCSI_SAS_ATA=y CONFIG_SCSI_UFSHCD=y CONFIG_SCSI_UFSHCD_PLATFORM=y @@ -880,7 +806,6 @@ CONFIG_SERIAL_8250=y CONFIG_SERIAL_8250_CONSOLE=y CONFIG_SERIAL_8250_DW=y CONFIG_SERIAL_8250_EXTENDED=y -# CONFIG_SERIAL_8250_PERICOM is not set CONFIG_SERIAL_8250_SHARE_IRQ=y CONFIG_SERIAL_AMBA_PL011=y CONFIG_SERIAL_AMBA_PL011_CONSOLE=y @@ -893,8 +818,6 @@ CONFIG_SERIAL_OF_PLATFORM=y CONFIG_SERIAL_XILINX_PS_UART=y CONFIG_SERIAL_XILINX_PS_UART_CONSOLE=y CONFIG_SERIO_AMBAKMI=y -# CONFIG_SERIO_SERPORT is not set -# CONFIG_SLIMBUS is not set CONFIG_SMB_SERVER=m CONFIG_SMB_SERVER_KERBEROS5=y CONFIG_SND=y @@ -968,7 +891,6 @@ CONFIG_SRAM=y CONFIG_STAGING=y CONFIG_STAGING_MEDIA=y CONFIG_STMMAC_ETH=y -# CONFIG_SURFACE_PLATFORMS is not set CONFIG_SYSFB_SIMPLEFB=y CONFIG_SYSVIPC=y CONFIG_TASKSTATS=y @@ -1098,33 +1020,13 @@ CONFIG_WATCHDOG=y CONFIG_WATCHDOG_NOWAYOUT=y CONFIG_WATCHDOG_SYSFS=y CONFIG_WIREGUARD=m -# CONFIG_WIREGUARD_DEBUG is not set -# CONFIG_WLAN_VENDOR_ADMTEK is not set -# CONFIG_WLAN_VENDOR_ATH is not set -# CONFIG_WLAN_VENDOR_ATMEL is not set -# CONFIG_WLAN_VENDOR_CISCO is not set -# CONFIG_WLAN_VENDOR_INTEL is not set -# CONFIG_WLAN_VENDOR_INTERSIL is not set -# CONFIG_WLAN_VENDOR_MARVELL is not set -# CONFIG_WLAN_VENDOR_MEDIATEK is not set -# CONFIG_WLAN_VENDOR_MICROCHIP is not set -# CONFIG_WLAN_VENDOR_QUANTENNA is not set -# CONFIG_WLAN_VENDOR_RALINK is not set -# CONFIG_WLAN_VENDOR_RSI is not set -# CONFIG_WLAN_VENDOR_ST is not set -# CONFIG_WLAN_VENDOR_TI is not set -# CONFIG_WLAN_VENDOR_ZYDAS is not set CONFIG_WQ_POWER_EFFICIENT_DEFAULT=y CONFIG_WQ_WATCHDOG=y CONFIG_XEN=y -# CONFIG_XENFS is not set -# CONFIG_XEN_BACKEND is not set -# CONFIG_XEN_BALLOON is not set -# CONFIG_XEN_DEV_EVTCHN is not set -# CONFIG_XEN_FBDEV_FRONTEND is not set -# CONFIG_XEN_GNTDEV is not set -# CONFIG_XEN_GRANT_DEV_ALLOC is not set -# CONFIG_XEN_SYS_HYPERVISOR is not set +CONFIG_XFRM=y +CONFIG_XFRM_ALGO=m +CONFIG_XFRM_ESP=m +CONFIG_XFRM_USER=m CONFIG_ZRAM=m CONFIG_ZRAM_DEF_COMP_ZSTD=y CONFIG_ZRAM_MEMORY_TRACKING=y @@ -1132,8 +1034,3 @@ CONFIG_ZSWAP=y CONFIG_ZSWAP_COMPRESSOR_DEFAULT_ZSTD=y CONFIG_ZSWAP_DEFAULT_ON=y CONFIG_ZSWAP_ZPOOL_DEFAULT_ZSMALLOC=y -CONFIG_INET_ESP=m -CONFIG_XFRM_USER=m -CONFIG_XFRM=y -CONFIG_XFRM_ALGO=m -CONFIG_XFRM_ESP=m From 2200602e4d502a2afa1c91bdde56fd43623d28d0 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sat, 23 Nov 2024 18:54:18 +0100 Subject: [PATCH 31/66] v9.9 - DietPi-Software | Migrate InfluxDB and Mopidy lists to Bookworm suite - Orange Pi 5 Pro | Add dietpi-config option to flash SPI bootloader --- .update/patches | 19 ++++++++++++++++--- dietpi/dietpi-config | 4 ++-- dietpi/dietpi-software | 14 +++++++------- 3 files changed, 25 insertions(+), 12 deletions(-) diff --git a/.update/patches b/.update/patches index f7afb974f8..e7c3e05533 100755 --- a/.update/patches +++ b/.update/patches @@ -2035,10 +2035,23 @@ Patch_9_9() # Software updates, migrations and patches if [[ -f '/boot/dietpi/.installed' ]] then - # InfluxDB: Recreate symlink deleted with package update: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 - if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[74\]=2' /boot/dietpi/.installed && [[ ! -e '/var/lib/influxdb' ]] + # InfluxDB + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[74\]=2' /boot/dietpi/.installed then - G_EXEC ln -sf /mnt/dietpi_userdata/influxdb /var/lib/influxdb + # Recreate symlink deleted with package update: https://dietpi.com/forum/t/influxdb-not-working-after-update/21868 + [[ -e '/var/lib/influxdb' ]] || G_EXEC ln -sf /mnt/dietpi_userdata/influxdb /var/lib/influxdb + # Migrate to now existing Bookworm suite + if [[ -f '/etc/apt/sources.list.d/influxdb.list' ]] + then + (( $G_DISTRO < 7 )) || G_EXEC sed -i 's/bullseye/bookworm/g' /etc/apt/sources.list.d/influxdb.list + G_EXEC mv /etc/apt/sources.list.d/{,dietpi-}influxdb.list + fi + fi + # Mopidy: Migrate to now existing Bookworm suite + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[118\]=2' /boot/dietpi/.installed && [[ -f '/etc/apt/sources.list.d/mopidy.list' ]] + then + (( $G_DISTRO < 7 )) || G_EXEC sed -i 's/bullseye/bookworm/g' /etc/apt/sources.list.d/mopidy.list + G_EXEC mv /etc/apt/sources.list.d/{,dietpi-}mopidy.list fi fi } diff --git a/dietpi/dietpi-config b/dietpi/dietpi-config index 020460a39d..a482c2efcc 100755 --- a/dietpi/dietpi-config +++ b/dietpi/dietpi-config @@ -932,8 +932,8 @@ 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 - # Odroid N2, 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 =~ ^(15|72|78|80|82|87)$ && -f '/usr/lib/u-boot/platform_install.sh' ]] + # Odroid N2, ROCK 4, ROCK 5B, Orange Pi 5 (Plus/Pro) and Orange Pi 3B: https://dietpi.com/forum/t/orange-pi-5-boot-from-nvme/16457 + elif [[ $G_HW_MODEL =~ ^(15|72|78|80|82|87|93)$ && -f '/usr/lib/u-boot/platform_install.sh' ]] then # Odroid N2/ROCK 4: Device tree overlay required local spidev='/dev/mtdblock0' diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 1fbb10b82c..5a7c25fa80 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -5066,7 +5066,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/trixie/bookworm} main contrib non-free' > /etc/apt/sources.list.d/dietpi-mopidy.list" G_AGUP fi @@ -6324,7 +6324,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.8.3.2/kavita-linux-$arch.tar.gz" + local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.8.4/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 @@ -7345,7 +7345,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/trixie/bookworm} stable' > /etc/apt/sources.list.d/dietpi-influxdb.list" G_AGUP # APT package @@ -10103,7 +10103,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.3.2665/Readarr.develop.0.4.3.2665.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.4.2686/Readarr.develop.0.4.4.2686.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 @@ -10368,7 +10368,7 @@ _EOF_ # x86_64: Install Debian i386 package if [[ $G_HW_ARCH == 10 ]] then - # Add i386 arch: https://packages.debian.org/bullseye/steam + # Add i386 arch: https://packages.debian.org/steam [[ $(dpkg --print-foreign-architectures) == *'i386'* ]] || { G_EXEC dpkg --add-architecture i386; G_AGUP; } G_AGI steam @@ -13104,7 +13104,7 @@ _EOF_ then Remove_Service mopidy G_AGP 'mopidy*' - [[ -f '/etc/apt/sources.list.d/mopidy.list' ]] && G_EXEC rm /etc/apt/sources.list.d/mopidy.list + [[ -f '/etc/apt/sources.list.d/dietpi-mopidy.list' ]] && G_EXEC rm /etc/apt/sources.list.d/dietpi-mopidy.list [[ -f '/etc/apt/trusted.gpg.d/dietpi-mopidy.gpg' ]] && G_EXEC rm /etc/apt/trusted.gpg.d/dietpi-mopidy.gpg command -v pip3 > /dev/null && G_EXEC_OUTPUT=1 G_EXEC pip3 uninstall -y Mopidy-MusicBox-Webclient @@ -13958,7 +13958,7 @@ _EOF_ then Remove_Service influxdb 1 1 G_AGP influxdb - [[ -f '/etc/apt/sources.list.d/influxdb.list' ]] && G_EXEC rm /etc/apt/sources.list.d/influxdb.list + [[ -f '/etc/apt/sources.list.d/dietpi-influxdb.list' ]] && G_EXEC rm /etc/apt/sources.list.d/dietpi-influxdb.list [[ -f '/etc/apt/trusted.gpg.d/dietpi-influxdb.gpg' ]] && G_EXEC rm /etc/apt/trusted.gpg.d/dietpi-influxdb.gpg G_EXEC rm -Rf /{mnt/dietpi_userdata,var/{lib,log},etc}/influxdb fi From a877a5bb89400b663c95f5ac0e60bfee3a895140 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 24 Nov 2024 15:58:57 +0100 Subject: [PATCH 32/66] v9.9 - DietPi-Software | rutorrent: Update fallback URL --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 5a7c25fa80..595140165a 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8591,8 +8591,8 @@ _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='v5.0.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 == 'v5.'* ]] || version='v5.0.0' + [[ $version ]] || { version='v5.1.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 == 'v5.'* ]] || version='v5.1.0' Download_Install "https://github.com/Novik/ruTorrent/archive/$version.tar.gz" # - Reinstall freshly with preserved configs and 3rd party plugins From e89429f53cf0f2b369dc304f4050607cd56087a4 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 1 Dec 2024 15:55:15 +0100 Subject: [PATCH 33/66] v9.9 - DietPi-Set_hardware | Code format --- dietpi/func/dietpi-set_hardware | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/dietpi/func/dietpi-set_hardware b/dietpi/func/dietpi-set_hardware index fabf208a12..4dc0ad5ff3 100755 --- a/dietpi/func/dietpi-set_hardware +++ b/dietpi/func/dietpi-set_hardware @@ -1823,14 +1823,14 @@ _EOF_ # An input is required [[ $INPUT_DEVICE_VALUE ]] || Unknown_Input_Mode #----------------------------------------------------------------------------- - # Remove all known audio based packages - if [[ $INPUT_DEVICE_VALUE == 'none' ]] - then - G_AGP alsa-utils libasound2-plugin-equal firmware-intel-sound firmware-sof-signed - # Install base alsa package - else - G_AG_CHECK_INSTALL_PREREQ alsa-utils - fi + # Remove all known audio based packages + if [[ $INPUT_DEVICE_VALUE == 'none' ]] + then + G_AGP alsa-utils libasound2-plugin-equal firmware-intel-sound firmware-sof-signed + # Install base alsa package + else + G_AG_CHECK_INSTALL_PREREQ alsa-utils + fi # Always reset sound cards and revert back to defaults Soundcard_Reset_All # Print info @@ -1907,8 +1907,8 @@ _EOF_ fi ;; - # Intel SST DSP - 'intel-sst-dsp') G_AG_CHECK_INSTALL_PREREQ firmware-intel-sound firmware-sof-signed;; + # Intel SST DSP + 'intel-sst-dsp') G_AG_CHECK_INSTALL_PREREQ firmware-intel-sound firmware-sof-signed;; # --------------- Sparky SBC ------------ # Allo Piano DAC (firmware + module) @@ -2345,7 +2345,7 @@ _EOF_ { (( $G_HW_MODEL == 20 )) || { Unsupported_Input_Name; return 1; } # VM only - [[ $INPUT_DEVICE_VALUE == 'disable' ]] && { G_AGP qemu-guest-agent; return 0; } + [[ $INPUT_DEVICE_VALUE == 'disable' ]] && { G_AGP qemu-guest-agent; return 0; } [[ $INPUT_DEVICE_VALUE == 'enable' ]] || { Unknown_Input_Mode; return 1; } From 08b20f423ccc6ed2482c26dc979b6b344c192a3c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 1 Dec 2024 18:28:42 +0100 Subject: [PATCH 34/66] v9.9 - DietPi-Installer | Workaround for NetworkManager removal, which can leave back a revised /etc/resolv.conf symlink: In case re-create with DietPi default --- .build/images/dietpi-installer | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index b5b714ce80..cdb11d1ea7 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1508,6 +1508,13 @@ _EOF_ G_AGA gawk original-awk "${ae2fsprogs[@]}" unset -v ae2fsprogs + # Workaround for NetworkManager removal, which can leave back a revised /etc/resolv.conf symlink: In case re-create with DietPi default + if [[ ! -f '/etc/resolv.conf' ]] + then + G_EXEC rm -f /etc/resolv.conf + G_EXEC eval 'echo '\''nameserver 9.9.9.9'\'' > /etc/resolv.conf' # Apply generic functional DNS nameserver + fi + #------------------------------------------------------------------------------------------------ G_DIETPI-NOTIFY 3 "$G_PROGRAM_NAME" "[$SETUP_STEP] APT installations"; ((SETUP_STEP++)) #------------------------------------------------------------------------------------------------ @@ -1811,7 +1818,7 @@ _EOF_' G_EXEC systemctl disable --now systemd-networkd (( $G_DISTRO > 6 )) || G_EXEC systemctl disable --now systemd-resolved G_EXEC rm -f /etc/resolv.conf - echo 'nameserver 9.9.9.9' > /etc/resolv.conf # Apply generic functional DNS nameserver, updated on next service start + G_EXEC eval 'echo '\''nameserver 9.9.9.9'\'' > /etc/resolv.conf' # Apply generic functional DNS nameserver # ifupdown starts the daemon outside of systemd, the enabled systemd unit just throws an error on boot due to missing dbus and with dbus might interfere with ifupdown systemctl -q is-enabled wpa_supplicant 2> /dev/null && G_EXEC systemctl disable wpa_supplicant From 23a5345817d16891f02e613245c21f070e5fb654 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 1 Dec 2024 18:48:37 +0100 Subject: [PATCH 35/66] v9.9 - DietPi-Software | Servarr: Update installed Servarr software automatically on reinstall. The it is skipped, pointing to internal updater, causes more issues than that it helps: A reinstall is usually done/needed when the instance is broken, e.g. because the internal updater fucked up. And a reinstall does nothing different, but in a failsafe way. Recent example: https://github.com/MichaIng/DietPi/issues/7251 --- dietpi/dietpi-software | 170 ++++++++++++++++------------------------- 1 file changed, 65 insertions(+), 105 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 595140165a..e4c31b71f9 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -9560,33 +9560,25 @@ _EOF_ esac fi - # Reinstall: Skip download and install, advice to use internal updater from web UI - if [[ -d '/opt/radarr' ]] + # Download + # - ARMv6: Radarr v4 does not support Mono anymore + local url='https://github.com/Radarr/Radarr/releases/download/v3.2.2.5080/Radarr.master.3.2.2.5080.linux.tar.gz' + if (( $G_HW_ARCH != 1 )) then - G_DIETPI-NOTIFY 2 "${aSOFTWARE_NAME[$software_id]} install dir \"/opt/radarr\" already exists. Download and install steps will be skipped. - - If you want to update ${aSOFTWARE_NAME[$software_id]}, please use the internal updater from web UI. - - If you need to reinstall (e.g. broken instance), please manually remove the install dir and rerun \"dietpi-software reinstall $software_id\"." - - G_AGI "${aDEPS[@]}" - aDEPS=() - else - # ARMv6: Radarr v4 does not support Mono anymore - local url='https://github.com/Radarr/Radarr/releases/download/v3.2.2.5080/Radarr.master.3.2.2.5080.linux.tar.gz' - if (( $G_HW_ARCH != 1 )) - then - case $G_HW_ARCH in - 2) local arch='arm';; - 3) local arch='arm64';; - *) local arch='x64';; - 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.15.1.9463/Radarr.master.5.15.1.9463.linux-core-$arch.tar.gz" - fi + case $G_HW_ARCH in + 2) local arch='arm';; + 3) local arch='arm64';; + *) local arch='x64';; + esac - Download_Install "$url" - G_EXEC mv Radarr /opt/radarr + 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.15.1.9463/Radarr.master.5.15.1.9463.linux-core-$arch.tar.gz" fi + Download_Install "$url" + + # Install: Remove previous instance on reinstall + [[ -d '/opt/radarr' ]] && G_EXEC rm -R /opt/radarr + G_EXEC mv Radarr /opt/radarr # Radarr v2: Remove old PID file and database backups from DietPi-Arr_to_RAM [[ -f '/mnt/dietpi_userdata/radarr/nzbdrone.pid' ]] && G_EXEC rm /mnt/dietpi_userdata/radarr/nzbdrone.pid @@ -9658,33 +9650,25 @@ _EOF_ # Pre-v7.5 ARMv6: Migrate old install dir [[ -d '/opt/Lidarr' && ! -d '/opt/lidarr' ]] && G_EXEC mv /opt/{L,l}idarr - # Reinstall: Skip download and install, advice to use internal updater from web UI - if [[ -d '/opt/lidarr' ]] + # Download + # - ARMv6: Lidarr v1 does not support Mono anymore + local url='https://github.com/Lidarr/Lidarr/releases/download/v0.8.1.2135/Lidarr.master.0.8.1.2135.linux.tar.gz' + if (( $G_HW_ARCH != 1 )) then - G_DIETPI-NOTIFY 2 "${aSOFTWARE_NAME[$software_id]} install dir \"/opt/lidarr\" already exists. Download and install steps will be skipped. - - If you want to update ${aSOFTWARE_NAME[$software_id]}, please use the internal updater from web UI. - - If you need to reinstall (e.g. broken instance), please manually remove the install dir and rerun \"dietpi-software reinstall $software_id\"." - - G_AGI "${aDEPS[@]}" - aDEPS=() - else - # ARMv6: Lidarr v1 does not support Mono anymore - local url='https://github.com/Lidarr/Lidarr/releases/download/v0.8.1.2135/Lidarr.master.0.8.1.2135.linux.tar.gz' - if (( $G_HW_ARCH != 1 )) - then - case $G_HW_ARCH in - 2) local arch='arm';; - 3) local arch='arm64';; - *) local arch='x64';; - 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.7.1.4417/Lidarr.master.2.7.1.4417.linux-core-$arch.tar.gz" - fi + case $G_HW_ARCH in + 2) local arch='arm';; + 3) local arch='arm64';; + *) local arch='x64';; + esac - Download_Install "$url" - G_EXEC mv Lidarr /opt/lidarr + 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.7.1.4417/Lidarr.master.2.7.1.4417.linux-core-$arch.tar.gz" fi + Download_Install "$url" + + # Install: Remove previous instance on reinstall + [[ -d '/opt/lidarr' ]] && G_EXEC rm -R /opt/lidarr + G_EXEC mv Lidarr /opt/lidarr # Data dir G_EXEC mkdir -p /mnt/dietpi_userdata/lidarr @@ -9826,22 +9810,16 @@ _EOF_ if To_Install 146 tautulli # Tautulli then - # Reinstall: Skip download and install, advice to use internal updater from web UI - if [[ -d '/opt/tautulli' ]] - then - G_DIETPI-NOTIFY 2 "${aSOFTWARE_NAME[$software_id]} install dir \"/opt/tautulli\" already exists. Download and install steps will be skipped. - - If you want to update ${aSOFTWARE_NAME[$software_id]}, please use the internal updater from web UI. - - If you need to reinstall (e.g. broken instance), please manually remove the install dir and rerun \"dietpi-software reinstall $software_id\"." + # Download + local url='https://github.com/Tautulli/Tautulli.git' + G_CHECK_URL "$url" + G_THREAD_START git clone --depth 1 "$url" + G_AGI python3-pkg-resources + G_THREAD_WAIT - G_AGI python3-pkg-resources - else - local url='https://github.com/Tautulli/Tautulli.git' - G_CHECK_URL "$url" - G_THREAD_START git clone --depth 1 "$url" - G_AGI python3-pkg-resources - G_THREAD_WAIT - G_EXEC mv Tautulli /opt/tautulli - fi + # Install: Remove previous instance on reinstall + [[ -d '/opt/tautulli' ]] && G_EXEC rm -R /opt/tautulli + G_EXEC mv Tautulli /opt/tautulli # User Create_User -d /mnt/dietpi_userdata/tautulli tautulli @@ -9880,13 +9858,13 @@ _EOF_ esac fi + # Download case $G_HW_ARCH in 1) local arch='Mono';; 2) local arch='LinuxARM32';; 3) local arch='LinuxARM64';; *) local arch='LinuxAMDx64';; esac - local fallback_url="https://github.com/Jackett/Jackett/releases/download/v0.21.1138/Jackett.Binaries.$arch.tar.gz" Download_Install "$(curl -sSfL 'https://api.github.com/repos/Jackett/Jackett/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*\/Jackett\.Binaries\.$arch\.tar\.gz\"$/{print \$4}")" @@ -9894,10 +9872,8 @@ _EOF_ [[ -d '/opt/jackett/Jackett' ]] && G_EXEC mv /opt/jackett/Jackett Jackett/ [[ -d '/opt/jackett/.mono' ]] && G_EXEC mv /opt/jackett/.mono Jackett/ - # Remove existing install dir + # Install: Remove previous instance on reinstall [[ -d '/opt/jackett' ]] && G_EXEC rm -R /opt/jackett - - # Move unpacked install dir in place G_EXEC mv Jackett /opt/jackett # User @@ -10011,26 +9987,18 @@ _EOF_ *) aDEPS=('libicu72');; esac - # Reinstall: Skip download and install, advice to use internal updater from web UI - if [[ -d '/opt/prowlarr' ]] - then - G_DIETPI-NOTIFY 2 "${aSOFTWARE_NAME[$software_id]} install dir \"/opt/prowlarr\" already exists. Download and install steps will be skipped. - - If you want to update ${aSOFTWARE_NAME[$software_id]}, please use the internal updater from web UI. - - If you need to reinstall (e.g. broken instance), please manually remove the install dir and rerun \"dietpi-software reinstall $software_id\"." - - G_AGI "${aDEPS[@]}" - aDEPS=() - else - case $G_HW_ARCH in - 2) local arch='arm';; - 3) local arch='arm64';; - *) local arch='x64';; - esac + # Download + case $G_HW_ARCH in + 2) local arch='arm';; + 3) local arch='arm64';; + *) local arch='x64';; + esac + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.26.1.4844/Prowlarr.master.1.26.1.4844.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}")" - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.26.1.4844/Prowlarr.master.1.26.1.4844.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 + # Install: Remove previous instance on reinstall + [[ -d '/opt/prowlarr' ]] && G_EXEC rm -R /opt/prowlarr + G_EXEC mv Prowlarr /opt/prowlarr # Data dir G_EXEC mkdir -p /mnt/dietpi_userdata/prowlarr @@ -10087,26 +10055,18 @@ _EOF_ *) aDEPS=('libicu72');; esac - # Reinstall: Skip download and install, advice to use internal updater from web UI - if [[ -d '/opt/readarr' ]] - then - G_DIETPI-NOTIFY 2 "${aSOFTWARE_NAME[$software_id]} install dir \"/opt/readarr\" already exists. Download and install steps will be skipped. - - If you want to update ${aSOFTWARE_NAME[$software_id]}, please use the internal updater from web UI. - - If you need to reinstall (e.g. broken instance), please manually remove the install dir and rerun \"dietpi-software reinstall $software_id\"." - - G_AGI "${aDEPS[@]}" - aDEPS=() - else - case $G_HW_ARCH in - 2) local arch='arm';; - 3) local arch='arm64';; - *) local arch='x64';; - esac + # Download + case $G_HW_ARCH in + 2) local arch='arm';; + 3) local arch='arm64';; + *) local arch='x64';; + esac + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.4.2686/Readarr.develop.0.4.4.2686.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)" - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.4.2686/Readarr.develop.0.4.4.2686.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 + # Install: Remove previous instance on reinstall + [[ -d '/opt/readarr' ]] && G_EXEC rm -R /opt/readarr + G_EXEC mv Readarr /opt/readarr # Data dir G_EXEC mkdir -p /mnt/dietpi_userdata/readarr From ec89b2385b2ef16fcc89fbd49e90955a5c0918a4 Mon Sep 17 00:00:00 2001 From: Joulinar <47155374+Joulinar@users.noreply.github.com> Date: Sun, 1 Dec 2024 20:42:25 +0100 Subject: [PATCH 36/66] DietPi-Software | frp (#7292) - DietPi-Software | frp - switch from ini to toml configuration file - DietPi-Software | frp - add a separation for ARMv6 and ARMv7 - DietPi-Software | frp: Fix parsing client input, allow any characters for the token (as we do not know any limitations), and make use of the native G_WHIP_INPUTBOX input validation. Also expose the server bind address in our default config, which might be more commonly changed to limit access to particular networks. - DietPi-Software | frp: Inform about new toml config file and leave old ini as backup in place. Do not offer client inputs, if the config exists already (and is hence not generated anyway). Allow an empty token input, which is generally possible. Allow unattended installs, using both server and client as default, and applying default values to all inputs and menus. - DietPi-Globals | G_WHIP: Return default value for inputbox, checkbox and menu, if not interactive, but keep returning error code, so that it can be handled in parent script. Minor coding enhancements. - CI | DietPi-Software: Enable frp checks now that it can be installed unattended Co-authored-by: MichaIng --- .github/workflows/dietpi-software.bash | 2 +- CHANGELOG.txt | 3 + dietpi/dietpi-software | 145 ++++++++++++++----------- dietpi/func/dietpi-globals | 118 +++++++++----------- 4 files changed, 138 insertions(+), 130 deletions(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index 8dd83980c0..0c3383578a 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -204,7 +204,7 @@ Process_Software() 167) (( $arch < 3 )) || aSERVICES[i]='raspotify';; # 32-bit ARM fails with: "arm-binfmt-P: /usr/bin/librespot: Unable to find a guest_base to satisfy all guest address mapping requirements" #169) aSERVICES[i]='voice-recognizer';; "RuntimeError: This module can only be run on a Raspberry Pi!" 170) aCOMMANDS[i]='unrar -V';; - #171) aSERVICES[i]='frps frpc' aTCP[i]='7000 7400 7500';; Interactive install with service and ports depending on server/client/both choice + 171) aSERVICES[i]='frps frpc' aTCP[i]='7000 7400 7500';; 172) aSERVICES[i]='wg-quick@wg0' aUDP[i]='51820';; 174) aCOMMANDS[i]='gimp -v';; 176) aSERVICES[i]='mycroft';; diff --git a/CHANGELOG.txt b/CHANGELOG.txt index a0b004dc67..72a33a5196 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -10,6 +10,8 @@ Enhancements: - DietPi-Software | NFS Server: The "fsid=0" option has been removed from the /mnt/dietpi_userdata default export. As it is uncommon and not respected in "showmount -e" export lists, it caused confusion and issues. - DietPi-Software | YaCy: The latest YaCy version will now be installed, and the global software password will be set as default admin password on fresh installs. - DietPi-Software | MineOS: As a security enhancement and workaround for a web UI login issue, a dedicated "mineos" user is created again. For new MineOS installs or after reinstall, one can login with this user, and the global software password. It has permissions to install and manage Minecraft instances. +- DietPi-Software | frp: It is now possible to connect the client to a server which has no (an empty) authentication token configured. frp can now be installed non-interactively, where client + server daemons are both installed and configured to work with each other, with respective defaults for all inputs. +- DietPi-Software | frp: Since the ini format for config files has been deprecated, and support will be removed in a future frp release, new installs and reinstalls/updates will generated toml format config files from now on. As of the large amount of config keys, which all changed between those formats, an automated conversion is sadly not possible. When doing a reinstall with existing ini configs, you will be informed about it, the old config(s) will be kept as backup in place, for a manual migration. All config keys for the toml format can be found here: https://github.com/fatedier/frp/tree/dev/conf Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 @@ -21,6 +23,7 @@ Bug fixes: - DietPi-Software | MineOS: Worked around an issue where the install failed on Bookworm systems, as one of the Node.js modules failed to compile for unknown reasons. Many thanks to @mikedebian for reporting this issue: https://github.com/MichaIng/DietPi/issues/7265 - DietPi-Software | MineOS: Worked around an issue where login into the web interface failed since Bullseye, as MineOS does not support the new default yescrypt password hash algorithm for UNIX users. A new dedicated "mineos" user is now created, and its password set explicitly with SHA512 hash algorithm. Many thanks to @maybaxstv for reporting this issue: https://github.com/MichaIng/DietPi/issues/5759 - DietPi-Software | Node.js: Resolved an issue where node failed on ARMv7 Bullseye systems, since the latest version for this architecture requires a newer C++ standard library than provided on Bullseye. +- DietPi-Software | frp: Resolved an issue where server address and port inputs for the client config generation were parsed incorrectly. 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 e4c31b71f9..7b01d9235f 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -1509,7 +1509,6 @@ Available commands: aSOFTWARE_DESC[$software_id]='reverse proxy' aSOFTWARE_CATX[$software_id]=16 aSOFTWARE_DOCS[$software_id]='https://dietpi.com/docs/software/advanced_networking/#frp' - aSOFTWARE_INTERACTIVE[$software_id]=1 # Home Automation #-------------------------------------------------------------------------------- @@ -6525,10 +6524,11 @@ _EOF_ if To_Install 171 # frp then case $G_HW_ARCH in + 1) local arch='arm';; + 2) local arch='arm_hf';; 3) local arch='arm64';; 10) local arch='amd64';; - 11) local arch='riscv64';; - *) local arch='arm_hf';; + *) local arch='riscv64';; esac # Download @@ -6537,19 +6537,17 @@ _EOF_ G_EXEC cd frp_* - local choice_required= - while : - do - G_WHIP_MENU_ARRAY=( - 'Server' ': Use this machine as a server, with a public IP' - 'Client' ': Use this machine as a client, without a public IP' - 'Both' ': Run the reverse proxy only on this machine' - ) + # Mode choice + G_WHIP_MENU_ARRAY=( + 'Server' ': Use this machine as a server, with a public IP' + 'Client' ': Use this machine as a client, without a public IP' + 'Both' ': Run the reverse proxy only on this machine' + ) - G_WHIP_MENU "${choice_required}Please choose how you are going to run frp." && break - choice_required='[ERROR] A choice is required to finish the frp install.\n\n' - done - local mode=$G_WHIP_RETURNED_VALUE + G_WHIP_NOCANCEL=1 + G_WHIP_DEFAULT_ITEM='Both' + G_WHIP_MENU 'Please choose how you are going to run frp:' + local mode=${G_WHIP_RETURNED_VALUE:-Both} G_EXEC mkdir -p /etc/frp Create_User frp -d /etc/frp @@ -6569,28 +6567,41 @@ StartLimitBurst=3 [Service] User=frp AmbientCapabilities=CAP_NET_BIND_SERVICE -ExecStart=/usr/local/bin/frps -c /etc/frp/frps.ini +ExecStart=/usr/local/bin/frps -c /etc/frp/frps.toml Restart=on-failure RestartSec=5s [Install] WantedBy=multi-user.target _EOF_ + # Pre-v9.9: Inform about config file migration + if [[ -f '/etc/frp/frps.ini' ]] + then + G_WHIP_MSG '[WARNING] New toml config file will be generated +\nfrp deprecated the ini format for its config files, hence /etc/frp/frps.toml will be generated and used from now on. +\nAn automated conversion is not possible and hence need to be done manually, if you did changes. A backup of the ini config it kept in place: +- /etc/frp/frps.ini.bak +\nA full overview of all config keys can be found here: +- https://github.com/fatedier/frp/blob/dev/conf/frps_full_example.toml' + G_EXEC mv /etc/frp/frps.ini{,.bak} + fi + # Pre-create config file to turn on dashboard token=$(openssl rand -hex 15) - [[ -f '/etc/frp/frps.ini' ]] || cat << _EOF_ > /etc/frp/frps.ini -[common] -bind_port = 7000 + [[ -f '/etc/frp/frps.toml' ]] || cat << _EOF_ > /etc/frp/frps.toml +bindAddr = "0.0.0.0" +bindPort = 7000 -dashboard_port = 7500 -dashboard_user = admin -dashboard_pwd = $GLOBAL_PW +webServer.addr = "0.0.0.0" +webServer.port = 7500 +webServer.user = "admin" +webServer.password = "$GLOBAL_PW" -authentication_method = token -token = $token +auth.method = "token" +auth.token = "$token" _EOF_ - G_EXEC chmod 0640 /etc/frp/frps.ini - G_EXEC chown root:frp /etc/frp/frps.ini + G_EXEC chmod 0640 /etc/frp/frps.toml + G_EXEC chown root:frp /etc/frp/frps.toml aENABLE_SERVICES+=('frps') fi @@ -6607,58 +6618,62 @@ StartLimitBurst=3 [Service] User=frp -ExecStart=/usr/local/bin/frpc -c /etc/frp/frpc.ini -ExecReload=/usr/local/bin/frpc reload -c /etc/frp/frpc.ini +ExecStart=/usr/local/bin/frpc -c /etc/frp/frpc.toml +ExecReload=/usr/local/bin/frpc reload -c /etc/frp/frpc.toml Restart=on-failure RestartSec=5s [Install] WantedBy=multi-user.target _EOF_ - local server_addr=127.0.0.1 server_port=7000 - if [[ $G_WHIP_RETURNED_VALUE == 'Client' ]] + # Pre-v9.9: Inform about config file migration + if [[ -f '/etc/frp/frpc.ini' ]] then - local invalid_entry= - while : - do - if G_WHIP_INPUTBOX "${invalid_entry}Please enter the IP address of your frp server, including port (default 7000)" && [[ $G_WHIP_RETURNED_VALUE =~ ^[0-9.:]+$ ]] - then - server_addr=${G_WHIP_RETURNED_VALUE#*:} - [[ $G_WHIP_RETURNED_VALUE =~ : ]] && server_port=${G_WHIP_RETURNED_VALUE%:*} - invalid_entry= - break - else - invalid_entry='[FAILED] Please enter a valid IP address\n\n' - fi - done - - while : - do - if G_WHIP_INPUTBOX "${invalid_entry}Please enter the authentication token of your frp server" && [[ $G_WHIP_RETURNED_VALUE =~ ^[0-9.]+$ ]] - then - token=$G_WHIP_RETURNED_VALUE - break - else - invalid_entry='[FAILED] Please enter a token\n\n' - fi - done + G_WHIP_MSG '[WARNING] New toml config file will be generated +\nfrp deprecated the ini format for its config files, hence /etc/frp/frpc.toml will be generated and used from now on. +\nAn automated conversion is not possible and hence need to be done manually, if you did changes. A backup of the ini config it kept in place: +- /etc/frp/frpc.ini.bak +\nA full overview of all config keys can be found here: +- https://github.com/fatedier/frp/blob/dev/conf/frpc_full_example.toml' + G_EXEC mv /etc/frp/frpc.ini{,.bak} fi # Pre-create config file to turn on admin UI - [[ -f '/etc/frp/frpc.ini' ]] || cat << _EOF_ > /etc/frp/frpc.ini -[common] -server_addr = $server_addr -server_port = $server_port + if [[ ! -f '/etc/frp/frpc.toml' ]] + then + local server_addr='127.0.0.1' server_port=7000 + if [[ $G_WHIP_RETURNED_VALUE == 'Client' ]] + then + G_WHIP_NOCANCEL=1 + G_WHIP_DEFAULT_ITEM="$server_addr:$server_port" + G_WHIP_INPUTBOX_REGEX='^[0-9.:]+$' + G_WHIP_INPUTBOX_REGEX_TEXT='be a valid IP address, optionally with appended network port number, like "192.168.1.100:7000"' + G_WHIP_INPUTBOX 'Please enter the IP address of your frp server, optionally including port (default 7000):' + [[ $G_WHIP_RETURNED_VALUE ]] && server_addr=${G_WHIP_RETURNED_VALUE%:*} + [[ $G_WHIP_RETURNED_VALUE =~ : ]] && server_port=${G_WHIP_RETURNED_VALUE##*:} + + G_WHIP_NOCANCEL=1 + G_WHIP_INPUTBOX_REGEX='*' + G_WHIP_INPUTBOX 'Please enter the authentication token of your frp server:' + token=$G_WHIP_RETURNED_VALUE + fi -admin_addr = 0.0.0.0 -admin_port = 7400 -admin_user = admin -admin_pwd = $GLOBAL_PW + cat << _EOF_ > /etc/frp/frpc.toml +serverAddr = "$server_addr" +serverPort = $server_port -token = $token +webServer.addr = "0.0.0.0" +webServer.port = 7400 +webServer.user = "admin" +webServer.password = "$GLOBAL_PW" + +auth.method = "token" +auth.token = "$token" _EOF_ - G_EXEC chmod 0660 /etc/frp/frpc.ini - G_EXEC chown root:frp /etc/frp/frpc.ini + fi + + G_EXEC chmod 0660 /etc/frp/frpc.toml + G_EXEC chown root:frp /etc/frp/frpc.toml aENABLE_SERVICES+=('frpc') fi diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 36a6efd12c..4136e15a8e 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -483,8 +483,8 @@ $grey───────────────────────── local whip_chars_text=$(( $WHIP_SIZE_X - 4 )) # Due to internal margins, the available width is 4 characters smaller WHIP_SCROLLTEXT= # Add "--scrolltext" automatically if text height exceeds max available - Process_Line(){ - + Process_Line() + { local split line=$1 # Split line by "\n" newline escape sequences, the only one which is interpreted by whiptail, in a strict way: "\\n" still creates a newline, hence the sequence cannot be escaped! @@ -504,27 +504,25 @@ $grey───────────────────────── (( whip_lines_text += 1 + ( ${#line} - 1 ) / $whip_chars_text )) # Stop counting if required size exceeds screen already (( $whip_lines_text <= $WHIP_SIZE_Y )) || return 1 - } # - WHIP_MESSAGE - if [[ $WHIP_ERROR$WHIP_MESSAGE ]]; then - + if [[ $WHIP_ERROR$WHIP_MESSAGE ]] + then while read -r line; do Process_Line "$line" || break; done <<< "$WHIP_ERROR$WHIP_MESSAGE" # - WHIP_TEXTFILE - elif [[ $WHIP_TEXTFILE ]]; then - + elif [[ $WHIP_TEXTFILE ]] + then while read -r line; do Process_Line "$line" || break; done < "$WHIP_TEXTFILE" - fi unset -f Process_Line # Process menu and checklist # - G_WHIP_MENU - if [[ $input_mode == 2 ]]; then - + if [[ $input_mode == 2 ]] + then # Requires 1 additional line for text ((whip_lines_text++)) @@ -554,8 +552,8 @@ $grey───────────────────────── done # - G_WHIP_CHECKLIST - elif [[ $input_mode == 3 ]]; then - + elif [[ $input_mode == 3 ]] + then # Lines required for checklist: ( ${#array} + 2 ) to round up single+double array entries WHIP_SIZE_Z=$(( ( ${#G_WHIP_CHECKLIST_ARRAY[@]} + 2 ) / 3 )) @@ -580,44 +578,37 @@ $grey───────────────────────── G_WHIP_CHECKLIST_ARRAY[$i]+='●' done - fi # Adjust sizes to fit content # - G_WHIP_MENU/G_WHIP_CHECKLIST needs to hold text + selection field (WHIP_SIZE_Z) - if [[ $input_mode == [23] ]]; then - + if [[ $input_mode == [23] ]] + then # If required lines would exceed screen, reduce WHIP_SIZE_Z - if (( $whip_lines_text + $WHIP_SIZE_Z > $WHIP_SIZE_Y )); then - + if (( $whip_lines_text + $WHIP_SIZE_Z > $WHIP_SIZE_Y )) + then WHIP_SIZE_Z=$(( $WHIP_SIZE_Y - $whip_lines_text )) # Assure at least 2 lines to have the selection field scroll bar identifiable - if (( $WHIP_SIZE_Z < 2 )); then - + if (( $WHIP_SIZE_Z < 2 )) + then WHIP_SIZE_Z=2 # Since text is partly hidden now, add text scroll ability and info to backtitle WHIP_SCROLLTEXT='--scrolltext' WHIP_BACKTITLE+=' | Use up/down buttons to scroll text' - fi # else reduce WHIP_SIZE_Y to hold all content else - WHIP_SIZE_Y=$(( $whip_lines_text + $WHIP_SIZE_Z )) - fi # - Everything else needs to hold text only - elif (( $whip_lines_text > $WHIP_SIZE_Y )); then - + elif (( $whip_lines_text > $WHIP_SIZE_Y )) + then WHIP_SCROLLTEXT='--scrolltext' WHIP_BACKTITLE+=' | Use up/down buttons to scroll text' - else - WHIP_SIZE_Y=$whip_lines_text - fi } @@ -627,17 +618,14 @@ $grey───────────────────────── { local WHIP_MESSAGE=$* - if [[ $G_INTERACTIVE == 1 ]]; then - + if [[ $G_INTERACTIVE == 1 ]] + then local WHIP_ERROR WHIP_BACKTITLE WHIP_SCROLLTEXT WHIP_SIZE_X WHIP_SIZE_Y G_WHIP_INIT # shellcheck disable=SC2086 whiptail ${G_PROGRAM_NAME:+--title "$G_PROGRAM_NAME"} --backtitle "$WHIP_BACKTITLE" --msgbox "$WHIP_MESSAGE" --ok-button "$G_WHIP_BUTTON_OK_TEXT" $WHIP_SCROLLTEXT "$WHIP_SIZE_Y" "$WHIP_SIZE_X" - else - G_DIETPI-NOTIFY 2 "$WHIP_MESSAGE" - fi G_WHIP_DESTROY @@ -650,30 +638,26 @@ $grey───────────────────────── { local result=0 - if [[ $G_INTERACTIVE == 1 ]]; then - + if [[ $G_INTERACTIVE == 1 ]] + then local WHIP_ERROR WHIP_MESSAGE WHIP_BACKTITLE WHIP_SCROLLTEXT WHIP_SIZE_X WHIP_SIZE_Y WHIP_TEXTFILE=$1 header='File viewer' [[ $log == 1 ]] && header='Log viewer' - if [[ -f $WHIP_TEXTFILE ]]; then - + if [[ -f $WHIP_TEXTFILE ]] + then G_WHIP_INIT # shellcheck disable=SC2086 whiptail --title "${G_PROGRAM_NAME:+$G_PROGRAM_NAME | }$header" --backtitle "$WHIP_BACKTITLE" --textbox "$WHIP_TEXTFILE" --ok-button "$G_WHIP_BUTTON_OK_TEXT" $WHIP_SCROLLTEXT "$WHIP_SIZE_Y" "$WHIP_SIZE_X" - else - result=1 WHIP_ERROR="[FAILED] File does not exist: $WHIP_TEXTFILE" G_WHIP_INIT # shellcheck disable=SC2086 whiptail --title "${G_PROGRAM_NAME:+$G_PROGRAM_NAME | }$header" --backtitle "$WHIP_BACKTITLE" --msgbox "$WHIP_ERROR" --ok-button "$G_WHIP_BUTTON_OK_TEXT" $WHIP_SCROLLTEXT "$WHIP_SIZE_Y" "$WHIP_SIZE_X" - fi - fi G_WHIP_DESTROY - return "$result" + return "${result:-1}" } # G_WHIP_YESNO "message" @@ -684,18 +668,17 @@ $grey───────────────────────── local result=1 default_no='--defaultno' [[ ${G_WHIP_DEFAULT_ITEM,,} == 'yes' || ${G_WHIP_DEFAULT_ITEM,,} == 'ok' ]] && result=0 default_no= - if [[ $G_INTERACTIVE == 1 ]]; then - + if [[ $G_INTERACTIVE == 1 ]] + then local WHIP_ERROR WHIP_BACKTITLE WHIP_SCROLLTEXT WHIP_SIZE_X WHIP_SIZE_Y WHIP_MESSAGE=$* G_WHIP_INIT # shellcheck disable=SC2086 whiptail ${G_PROGRAM_NAME:+--title "$G_PROGRAM_NAME"} --backtitle "$WHIP_BACKTITLE" --yesno "$WHIP_MESSAGE" --yes-button "$G_WHIP_BUTTON_OK_TEXT" --no-button "$G_WHIP_BUTTON_CANCEL_TEXT" "$default_no" $WHIP_SCROLLTEXT "$WHIP_SIZE_Y" "$WHIP_SIZE_X" result=$? - fi G_WHIP_DESTROY - return "$result" + return "${result:-1}" } # G_WHIP_INPUTBOX "message" @@ -707,26 +690,27 @@ $grey───────────────────────── local result=1 unset -v G_WHIP_RETURNED_VALUE # in case left from last G_WHIP - if [[ $G_INTERACTIVE == 1 ]]; then - + if [[ $G_INTERACTIVE == 1 ]] + then local WHIP_ERROR WHIP_BACKTITLE WHIP_SCROLLTEXT WHIP_SIZE_X WHIP_SIZE_Y WHIP_MESSAGE=$* NOCANCEL=() + G_WHIP_INPUTBOX_REGEX=${G_WHIP_INPUTBOX_REGEX:-'.'} + G_WHIP_INPUTBOX_REGEX_TEXT=${G_WHIP_INPUTBOX_REGEX_TEXT:-'not be empty'} [[ $G_WHIP_NOCANCEL == 1 ]] && NOCANCEL=('--nocancel') while : do G_WHIP_INIT - G_WHIP_INPUTBOX_REGEX=${G_WHIP_INPUTBOX_REGEX:-'.'} - G_WHIP_INPUTBOX_REGEX_TEXT=${G_WHIP_INPUTBOX_REGEX_TEXT:-'not be empty'} # shellcheck disable=SC2086 G_WHIP_RETURNED_VALUE=$(whiptail ${G_PROGRAM_NAME:+--title "$G_PROGRAM_NAME"} --backtitle "$WHIP_BACKTITLE" --inputbox "$WHIP_ERROR$WHIP_MESSAGE" --ok-button "$G_WHIP_BUTTON_OK_TEXT" --cancel-button "$G_WHIP_BUTTON_CANCEL_TEXT" "${NOCANCEL[@]}" $WHIP_SCROLLTEXT "$WHIP_SIZE_Y" "$WHIP_SIZE_X" "$G_WHIP_DEFAULT_ITEM" 3>&1 1>&2 2>&3-; echo $? > /tmp/.G_WHIP_INPUTBOX_RESULT) read -r result < /tmp/.G_WHIP_INPUTBOX_RESULT; rm -f /tmp/.G_WHIP_INPUTBOX_RESULT [[ $result == 0 && ! $G_WHIP_RETURNED_VALUE =~ $G_WHIP_INPUTBOX_REGEX ]] && { WHIP_ERROR="[FAILED] Input must $G_WHIP_INPUTBOX_REGEX_TEXT, please try again ...\n\n"; continue; } break done - + else + G_WHIP_RETURNED_VALUE=$G_WHIP_DEFAULT_ITEM fi G_WHIP_DESTROY - return "$result" + return "${result:-1}" } # G_WHIP_PASSWORD "message" @@ -738,8 +722,8 @@ $grey───────────────────────── local return_value=1 unset -v result # in case left from last call - if [[ $G_INTERACTIVE == 1 ]]; then - + if [[ $G_INTERACTIVE == 1 ]] + then local WHIP_ERROR WHIP_BACKTITLE WHIP_SCROLLTEXT WHIP_SIZE_X WHIP_SIZE_Y WHIP_MESSAGE=$* while : do @@ -753,11 +737,10 @@ $grey───────────────────────── return_value=0 break done - fi G_WHIP_DESTROY - return "$return_value" + return "${return_value:-1}" } # G_WHIP_MENU "message" @@ -768,19 +751,24 @@ $grey───────────────────────── local result=1 unset -v G_WHIP_RETURNED_VALUE # in case left from last call - [[ $G_INTERACTIVE == 1 ]] && until [[ $G_WHIP_RETURNED_VALUE ]] # Stay in menu if empty option was selected (separator line) - do + if [[ $G_INTERACTIVE == 1 ]] + then local WHIP_ERROR WHIP_BACKTITLE WHIP_SCROLLTEXT WHIP_SIZE_X WHIP_SIZE_Y WHIP_SIZE_Z WHIP_MESSAGE=$* NOCANCEL=() [[ $G_WHIP_NOCANCEL == 1 ]] && NOCANCEL=('--nocancel') - G_WHIP_INIT 2 - # shellcheck disable=SC2086 - G_WHIP_RETURNED_VALUE=$(whiptail ${G_PROGRAM_NAME:+--title "$G_PROGRAM_NAME"} --backtitle "$WHIP_BACKTITLE" --menu "$WHIP_MESSAGE" --ok-button "$G_WHIP_BUTTON_OK_TEXT" --cancel-button "$G_WHIP_BUTTON_CANCEL_TEXT" "${NOCANCEL[@]}" --default-item "$G_WHIP_DEFAULT_ITEM" $WHIP_SCROLLTEXT "$WHIP_SIZE_Y" "$WHIP_SIZE_X" "$WHIP_SIZE_Z" -- "${G_WHIP_MENU_ARRAY[@]}" 3>&1 1>&2 2>&3-; echo $? > /tmp/.WHIP_MENU_RESULT) - read -r result < /tmp/.WHIP_MENU_RESULT; rm -f /tmp/.WHIP_MENU_RESULT - [[ ${result:=1} == 0 ]] || break # Exit loop in case of cancel button selection or error or if .WHIP_MENU_RESULT could not be created - done + until [[ $G_WHIP_RETURNED_VALUE ]] # Stay in menu if empty option was selected (separator line) + do + G_WHIP_INIT 2 + # shellcheck disable=SC2086 + G_WHIP_RETURNED_VALUE=$(whiptail ${G_PROGRAM_NAME:+--title "$G_PROGRAM_NAME"} --backtitle "$WHIP_BACKTITLE" --menu "$WHIP_MESSAGE" --ok-button "$G_WHIP_BUTTON_OK_TEXT" --cancel-button "$G_WHIP_BUTTON_CANCEL_TEXT" "${NOCANCEL[@]}" --default-item "$G_WHIP_DEFAULT_ITEM" $WHIP_SCROLLTEXT "$WHIP_SIZE_Y" "$WHIP_SIZE_X" "$WHIP_SIZE_Z" -- "${G_WHIP_MENU_ARRAY[@]}" 3>&1 1>&2 2>&3-; echo $? > /tmp/.WHIP_MENU_RESULT) + read -r result < /tmp/.WHIP_MENU_RESULT; rm -f /tmp/.WHIP_MENU_RESULT + [[ ${result:=1} == 0 ]] || break # Exit loop in case of cancel button selection or error or if .WHIP_MENU_RESULT could not be created + done + else + G_WHIP_RETURNED_VALUE=$G_WHIP_DEFAULT_ITEM + fi G_WHIP_DESTROY - return "$result" + return "${result:-1}" } # G_WHIP_CHECKLIST "message" @@ -800,6 +788,8 @@ $grey───────────────────────── G_WHIP_RETURNED_VALUE=$(whiptail ${G_PROGRAM_NAME:+--title "$G_PROGRAM_NAME"} --backtitle "$WHIP_BACKTITLE | Use spacebar to toggle selection" --checklist "$WHIP_MESSAGE" --separate-output --ok-button "$G_WHIP_BUTTON_OK_TEXT" --cancel-button "$G_WHIP_BUTTON_CANCEL_TEXT" "${NOCANCEL[@]}" --default-item "$G_WHIP_DEFAULT_ITEM" $WHIP_SCROLLTEXT "$WHIP_SIZE_Y" "$WHIP_SIZE_X" "$WHIP_SIZE_Z" -- "${G_WHIP_CHECKLIST_ARRAY[@]}" 3>&1 1>&2 2>&3-; echo $? > /tmp/.WHIP_CHECKLIST_RESULT) G_WHIP_RETURNED_VALUE=$(echo -e "$G_WHIP_RETURNED_VALUE" | tr '\n' ' ') read -r result < /tmp/.WHIP_CHECKLIST_RESULT; rm -f /tmp/.WHIP_CHECKLIST_RESULT + else + G_WHIP_RETURNED_VALUE=$G_WHIP_DEFAULT_ITEM fi G_WHIP_DESTROY From fd0061b82775a12303024aae532639c92aedfbe9 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 2 Dec 2024 12:55:12 +0100 Subject: [PATCH 37/66] v9.9 - DietPi-Software | Roon Server: Add service user to dietpi group OOTB. It has a backup feature which requires write access, hence this reduces permissions hassle for users: https://community.roonlabs.com/t/283821 --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 7b01d9235f..d3131993d2 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10303,7 +10303,7 @@ _EOF_ G_EXEC ln -s /var/log/roonserver /mnt/dietpi_userdata/roonserver/RAATServer/Logs # User: Grant sudo permissions to create a mount point and mount SMB shares - Create_User -G audio -d /mnt/dietpi_userdata/roonserver roonserver + Create_User -G dietpi,audio -d /mnt/dietpi_userdata/roonserver roonserver G_EXEC eval 'echo '\''roonserver ALL=NOPASSWD:SETENV: /bin/mkdir -p /mnt/RoonStorage_*, /sbin/mount.cifs'\'' > /etc/sudoers.d/roonserver' # Permissions From 868dde872af96f032e0790cdbd4901660a82f7ee Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 2 Dec 2024 14:23:28 +0100 Subject: [PATCH 38/66] v9.9 - DietPi-Software | Shairport Sync: Update default config file --- .build/software/shairport-sync/build.bash | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/.build/software/shairport-sync/build.bash b/.build/software/shairport-sync/build.bash index 5792ea41e4..93ee5a429e 100755 --- a/.build/software/shairport-sync/build.bash +++ b/.build/software/shairport-sync/build.bash @@ -124,6 +124,7 @@ general = // With the range of AirPlay volume being from -30 to 0, doubling the volume from -22.5 to -15 results in an increase of 10 dB. // Similarly, doubling the volume from -15 to 0 results in an increase of 10 dB. // For compatibility with mixers having a restricted attenuation range (e.g. 30 dB), "dasl_tapered" will switch to a flat profile at low AirPlay volumes. + // volume_control_combined_hardware_priority = "no"; // when extending the volume range by combining the built-in software attenuator with the hardware mixer attenuator, set this to "yes" to reduce volume by using the hardware mixer first, then the built-in software attenuator. // default_airplay_volume = -24.0; // this is the suggested volume after a reset or after the high_volume_threshold has been exceed and the high_volume_idle_timeout_in_minutes has passed @@ -178,7 +179,8 @@ sessioncontrol = // run_this_before_play_begins = "/full/path/to/application and args"; // make sure the application has executable permission. If it's a script, include the shebang (#!/bin/...) on the first line // run_this_after_play_ends = "/full/path/to/application and args"; // make sure the application has executable permission. If it's a script, include the shebang (#!/bin/...) on the first line -// run_this_if_an_unfixable_error_is_detected = "/full/path/to/application and args"; // if a problem occurs that can't be cleared by Shairport Sync itself, hook a program on here to deal with it. An error code-string is passed as the last argument. +// run_this_if_an_unfixable_error_is_detected = "/full/path/to/application and args"; // if a problem occurs that can't be cleared by Shairport Sync itself, hook a program on here to deal with it. +// An error code-string is passed as the last argument. // Many of these "unfixable" problems are caused by malfunctioning output devices, and sometimes it is necessary to restart the whole device to clear the problem. // You could hook on a program to do this automatically, but beware -- the device may then power off and restart without warning! // wait_for_completion = "no"; // set to "yes" to get Shairport Sync to wait until the "run_this..." applications have terminated before continuing @@ -187,6 +189,8 @@ sessioncontrol = // session_timeout = 120; // wait for this number of seconds after a source disappears before terminating the session and becoming available again. }; +// Back End Settings + // These are parameters for the "alsa" audio back end. alsa = { @@ -221,6 +225,7 @@ pipe = // There are no configuration file parameters for the "stdout" audio back end. No interpolation is done. // How to deal with metadata, including artwork +// "enabled" and "include_cover_art" are both "yes" by default metadata = { // enabled = "yes"; // set this to yes to get Shairport Sync to solicit metadata from the source and to pass it on via a pipe @@ -237,10 +242,12 @@ metadata = }; // How to enable the MQTT-metadata/remote-service + // Note that, for compatability with many MQTT brokers and applications, // every message that has no extra data is given a // payload consisting of the string "--". // You can change this or you can enable empty payloads -- see below. + mqtt = { // enabled = "no"; // set this to yes to enable the mqtt-metadata-service @@ -256,10 +263,12 @@ mqtt = // publish_raw = "no"; //whether to publish all available metadata under the codes given in the 'metadata' docs. // publish_parsed = "no"; //whether to publish a small (but useful) subset of metadata under human-understandable topics // empty_payload_substitute = "--"; // MQTT messages with empty payloads often are invisible or have special significance to MQTT brokers and readers. -// To avoid empty payload problems, the string here is used instead of any empty payload. Set it to the empty string -- "" -- to leave the payload empty. +// To avoid empty payload problems, the string here is used instead of any empty payload. Set it to the empty string -- "" -- to leave the payload empty. // Currently published topics:artist,album,title,genre,format,songalbum,volume,client_ip, // Additionally, messages at the topics play_start,play_end,play_flush,play_resume are published // publish_cover = "no"; //whether to publish the cover over mqtt in binary form. This may lead to a bit of load on the broker +// enable_autodiscovery = "no"; //whether to publish an autodiscovery message to automatically appear in Home Assistant +// autodiscovery_prefix = "homeassistant"; //string to prepend to autodiscovery topic // enable_remote = "no"; //whether to remote control via MQTT. RC is available under `topic`/remote. // Available commands are "command", "beginff", "beginrew", "mutetoggle", "nextitem", "previtem", "pause", "playpause", "play", "stop", "playresume", "shuffle_songs", "volumedown", "volumeup" }; From 8b15885b94a5009df9a57907a5e17da6b1a7860f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 2 Dec 2024 21:40:31 +0100 Subject: [PATCH 39/66] v9.9 - CI | Shairport Sync: Update AirPlay 2 dependencies for Trixie --- .build/software/shairport-sync/build.bash | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.build/software/shairport-sync/build.bash b/.build/software/shairport-sync/build.bash index 93ee5a429e..63361f1b27 100755 --- a/.build/software/shairport-sync/build.bash +++ b/.build/software/shairport-sync/build.bash @@ -13,11 +13,11 @@ G_AGUP G_AGDUG automake pkg-config make g++ libpopt-dev libconfig-dev libssl-dev libsoxr-dev libavahi-client-dev libasound2-dev libglib2.0-dev libmosquitto-dev avahi-daemon git libplist-dev libsodium-dev libgcrypt20-dev libavformat-dev xxd (( $G_DISTRO == 5 )) && G_EXEC systemctl unmask avahi-daemon adeps=('libc6' 'libasound2' 'libavahi-client3' 'libsoxr0' 'libconfig9' 'libpopt0' 'libglib2.0-0' 'libmosquitto1' 'avahi-daemon') -adeps2=('libplist3' 'libsodium23' 'libgcrypt20') +adeps2=('libsodium23' 'libgcrypt20') case $G_DISTRO in - 5|6) adeps+=('libssl1.1'); adeps2+=('libavcodec58');; - 7) adeps+=('libssl3'); adeps2+=('libavcodec59');; - 8) adeps+=('libssl3'); adeps2+=('libavcodec60');; + 5|6) adeps+=('libssl1.1'); adeps2+=('libavcodec58' 'libplist3');; + 7) adeps+=('libssl3'); adeps2+=('libavcodec59' 'libplist3');; + 8) adeps+=('libssl3'); adeps2+=('libavcodec60' 'libplist-2.0-4');; *) G_DIETPI-NOTIFY 1 "Unsupported distro version: $G_DISTRO_NAME (ID=$G_DISTRO)"; exit 1;; esac for i in "${adeps[@]}" "${adeps2[@]}" From 5e87edb3f406acb88cf639c5c4afedc5350c5a0f Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 2 Dec 2024 22:26:18 +0100 Subject: [PATCH 40/66] v9.9 - DietPi-Software | Shairport Sync: Another dependency update for Trixie --- .build/software/shairport-sync/build.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.build/software/shairport-sync/build.bash b/.build/software/shairport-sync/build.bash index 63361f1b27..d0511597e4 100755 --- a/.build/software/shairport-sync/build.bash +++ b/.build/software/shairport-sync/build.bash @@ -17,7 +17,7 @@ adeps2=('libsodium23' 'libgcrypt20') case $G_DISTRO in 5|6) adeps+=('libssl1.1'); adeps2+=('libavcodec58' 'libplist3');; 7) adeps+=('libssl3'); adeps2+=('libavcodec59' 'libplist3');; - 8) adeps+=('libssl3'); adeps2+=('libavcodec60' 'libplist-2.0-4');; + 8) adeps+=('libssl3'); adeps2+=('libavcodec61' 'libplist-2.0-4');; *) G_DIETPI-NOTIFY 1 "Unsupported distro version: $G_DISTRO_NAME (ID=$G_DISTRO)"; exit 1;; esac for i in "${adeps[@]}" "${adeps2[@]}" From de0af4b92b650c4af6850849c54e9529a849c443 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 5 Dec 2024 20:34:57 +0100 Subject: [PATCH 41/66] v9.9 - DietPi-Software | Home Assistant: Raise Python version to 3.13, as Python 3.12 support is deprecated by HA since 2024.12 and will be removed with 2025.02: https://github.com/MichaIng/DietPi/issues/7293 --- dietpi/dietpi-software | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index d3131993d2..09f44abf58 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11329,7 +11329,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.7' # https://github.com/pyenv/pyenv/tree/master/plugins/python-build/share/python-build + local ha_python_version='3.13.1' # 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 7462973bfaaaf43758a0286fc5c72baccc2b4b9e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 5 Dec 2024 20:44:06 +0100 Subject: [PATCH 42/66] v9.9 - 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 09f44abf58..f98c9e46c2 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8606,8 +8606,8 @@ _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='v5.1.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 == 'v5.'* ]] || version='v5.1.0' + [[ $version ]] || { version='v5.1.1'; 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 == 'v5.'* ]] || version='v5.1.1' Download_Install "https://github.com/Novik/ruTorrent/archive/$version.tar.gz" # - Reinstall freshly with preserved configs and 3rd party plugins @@ -8998,7 +8998,7 @@ _EOF_ *) local arch='arm';; esac - local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.28.0/syncthing-linux-$arch-v1.28.0.tar.gz" + local fallback_url="https://github.com/syncthing/syncthing/releases/download/v1.28.1/syncthing-linux-$arch-v1.28.1.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 @@ -9939,7 +9939,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.4/nzbget-24.4-bin-linux.run' + local fallback_url='https://github.com/nzbgetcom/nzbget/releases/download/v24.5/nzbget-24.5-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 452927520b33d195b7794ec22d0febb397f61dec Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 5 Dec 2024 22:31:11 +0100 Subject: [PATCH 43/66] v9.9 - DietPi-Software | Update fallback URL --- dietpi/dietpi-software | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index f98c9e46c2..3ab3ad881e 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6323,7 +6323,7 @@ _EOF_ *) local arch='x64';; esac - local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.8.4/kavita-linux-$arch.tar.gz" + local fallback_url="https://github.com/Kareadita/Kavita/releases/download/v0.8.4.2/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 @@ -10008,7 +10008,7 @@ _EOF_ 3) local arch='arm64';; *) local arch='x64';; esac - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.26.1.4844/Prowlarr.master.1.26.1.4844.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.27.0.4852/Prowlarr.master.1.27.0.4852.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}")" # Install: Remove previous instance on reinstall @@ -10648,7 +10648,7 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.22.3/gitea-1.22.3-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.22.4/gitea-1.22.4-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 8dcf6cc625faae4d7237150ccc14a1b3ec16769e Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 5 Dec 2024 23:50:51 +0100 Subject: [PATCH 44/66] v9.9 - DietPi-Globals | G_WHIP: Change default ok/yes button text of menus to "Select" and checkbox menus to "Confirm" - DietPi-Installer | Move NetworkManager workaround to the right place --- .build/images/dietpi-installer | 14 +++++++------- dietpi/func/dietpi-globals | 2 ++ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index cdb11d1ea7..2c376c2ad3 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1508,13 +1508,6 @@ _EOF_ G_AGA gawk original-awk "${ae2fsprogs[@]}" unset -v ae2fsprogs - # Workaround for NetworkManager removal, which can leave back a revised /etc/resolv.conf symlink: In case re-create with DietPi default - if [[ ! -f '/etc/resolv.conf' ]] - then - G_EXEC rm -f /etc/resolv.conf - G_EXEC eval 'echo '\''nameserver 9.9.9.9'\'' > /etc/resolv.conf' # Apply generic functional DNS nameserver - fi - #------------------------------------------------------------------------------------------------ G_DIETPI-NOTIFY 3 "$G_PROGRAM_NAME" "[$SETUP_STEP] APT installations"; ((SETUP_STEP++)) #------------------------------------------------------------------------------------------------ @@ -1537,6 +1530,13 @@ _EOF_ [[ -f '/etc/apt/preferences.d/dietpi-armbian-tmp' ]] && G_EXEC rm /etc/apt/preferences.d/dietpi-armbian-tmp [[ -f '/etc/apt/apt.conf.d/dietpi-armbian' ]] && G_EXEC rm /etc/apt/apt.conf.d/dietpi-armbian + # Workaround for NetworkManager removal, which can leave back a revised /etc/resolv.conf symlink: In case re-create with DietPi default + if [[ ! -f '/etc/resolv.conf' ]] + then + G_EXEC rm -f /etc/resolv.conf + G_EXEC eval 'echo '\''nameserver 9.9.9.9'\'' > /etc/resolv.conf' # Apply generic functional DNS nameserver + fi + #------------------------------------------------------------------------------------------------ G_DIETPI-NOTIFY 3 "$G_PROGRAM_NAME" "[$SETUP_STEP] Applying DietPi tweaks and cleanup"; ((SETUP_STEP++)) #------------------------------------------------------------------------------------------------ diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 4136e15a8e..44ed22332f 100644 --- a/dietpi/func/dietpi-globals +++ b/dietpi/func/dietpi-globals @@ -755,6 +755,7 @@ $grey───────────────────────── then local WHIP_ERROR WHIP_BACKTITLE WHIP_SCROLLTEXT WHIP_SIZE_X WHIP_SIZE_Y WHIP_SIZE_Z WHIP_MESSAGE=$* NOCANCEL=() [[ $G_WHIP_NOCANCEL == 1 ]] && NOCANCEL=('--nocancel') + G_WHIP_BUTTON_OK_TEXT=${G_WHIP_BUTTON_OK_TEXT:-Select} until [[ $G_WHIP_RETURNED_VALUE ]] # Stay in menu if empty option was selected (separator line) do G_WHIP_INIT 2 @@ -783,6 +784,7 @@ $grey───────────────────────── then local WHIP_ERROR WHIP_BACKTITLE WHIP_SCROLLTEXT WHIP_SIZE_X WHIP_SIZE_Y WHIP_SIZE_Z WHIP_MESSAGE=$* NOCANCEL=() [[ $G_WHIP_NOCANCEL == 1 ]] && NOCANCEL=('--nocancel') + G_WHIP_BUTTON_OK_TEXT=${G_WHIP_BUTTON_OK_TEXT:-Confirm} G_WHIP_INIT 3 # shellcheck disable=SC2086 G_WHIP_RETURNED_VALUE=$(whiptail ${G_PROGRAM_NAME:+--title "$G_PROGRAM_NAME"} --backtitle "$WHIP_BACKTITLE | Use spacebar to toggle selection" --checklist "$WHIP_MESSAGE" --separate-output --ok-button "$G_WHIP_BUTTON_OK_TEXT" --cancel-button "$G_WHIP_BUTTON_CANCEL_TEXT" "${NOCANCEL[@]}" --default-item "$G_WHIP_DEFAULT_ITEM" $WHIP_SCROLLTEXT "$WHIP_SIZE_Y" "$WHIP_SIZE_X" "$WHIP_SIZE_Z" -- "${G_WHIP_CHECKLIST_ARRAY[@]}" 3>&1 1>&2 2>&3-; echo $? > /tmp/.WHIP_CHECKLIST_RESULT) From a5ef615bce3a9d3499edfd0ab555d698cb13612b Mon Sep 17 00:00:00 2001 From: MichaIng Date: Fri, 6 Dec 2024 16:47:33 +0100 Subject: [PATCH 45/66] v9.9 - DietPi-Software | Box86/64: Update fallback versions and Odroid target --- dietpi/dietpi-software | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 3ab3ad881e..b6929c1efb 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -11069,7 +11069,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.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.3.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/box86/archive/$version.tar.gz" # Build for targets: https://github.com/ptitSeb/box86/blob/master/CMakeLists.txt @@ -11087,10 +11087,10 @@ _EOF_ elif (( $G_HW_MODEL == 4 )) then G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DRPI4=1 - # - Odroids - elif (( $G_HW_MODEL < 20 )) + # - Odroid XU4 + elif (( $G_HW_MODEL == 11 )) then - G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DODROID=1 + G_EXEC cmake .. -DNOGIT=1 -DCMAKE_BUILD_TYPE=Release -DODROIDXU4=1 # - ASUS Tinker Board elif (( $G_HW_MODEL == 52 )) then @@ -11118,7 +11118,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.3.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"; } + [[ $version ]] || { version='v0.3.2'; 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 From 20d18c5568f8f28507b589e0500a88d71ccc8416 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 8 Dec 2024 21:07:54 +0100 Subject: [PATCH 46/66] v9.9 - CHANGELOG | Typo --- .update/patches | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.update/patches b/.update/patches index e7c3e05533..3ce9dfc38f 100755 --- a/.update/patches +++ b/.update/patches @@ -1453,7 +1453,7 @@ 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_DIETPI-NOTIFY 2 'Removing obsolete USBridge Sig driver update script, since Allo does not provides those for recent kernel versions anymore' G_EXEC rm /etc/kernel/postinst.d/dietpi-USBridgeSig fi From 1524072079e1ae6252d6d2c93b51c7d1a732df3d Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 9 Dec 2024 14:56:31 +0100 Subject: [PATCH 47/66] v9.9 - CI | Amiberry: Build v5.7.4 until v7.0.0 stable has been released. It requires a major rework, using cmake and no device-specific targets anymore. --- .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 7db831b63f..254a795ae8 100755 --- a/.build/software/Amiberry/build.bash +++ b/.build/software/Amiberry/build.bash @@ -112,7 +112,8 @@ v_ami=$(curl -sSf 'https://api.github.com/repos/BlitterStudio/amiberry/releases/ [[ $v_ami ]] || { G_DIETPI-NOTIFY 1 'No latest Amiberry version found, aborting ...'; exit 1; } v_ami=${v_ami#v} # - ARMv6: v5.7.2 dropped support for Raspberry Pi 1, hence use v5.7.1 -[[ $PLATFORM == 'rpi1'* ]] && v_ami='5.7.1' +# - Build v5.7.4 until v7.0.0 stable has been released. It requires a major rework, using cmake and no device-specific targets anymore. +[[ $PLATFORM == 'rpi1'* ]] && v_ami='5.7.1' || v_ami='5.7.4' G_DIETPI-NOTIFY 2 "Building Amiberry version \e[33m$v_ami\e[90m for platform: \e[33m$PLATFORM" G_EXEC cd /tmp G_EXEC curl -sSfLO "https://github.com/BlitterStudio/amiberry/archive/v$v_ami.tar.gz" From 3ffb0b2c3f0d9ec4b91feaa13e51f673c7bd1977 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 9 Dec 2024 15:35:12 +0100 Subject: [PATCH 48/66] v9.9 - DietPi-Services | "dietpi-services start" will not start disabled services anymore. This aligns with the behaviour of the "restart" command, which as well skips disabled services. The script is used within other DietPi scripts to (re)start services after maintenance operations, and it is unexpected when services, who were not running before, but explicitly disabled, are running afterwards. To manually start/stop individual services from the console, we recommend using "systemctl" directly, like on any other Linux distribution with systemd. Many thanks to @intiplink for reporting this unexpected behaviour while using dietpi-drive_manager: https://github.com/MichaIng/DietPi/issues/7302 --- CHANGELOG.txt | 1 + dietpi/dietpi-services | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 72a33a5196..4b4f455235 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -7,6 +7,7 @@ New images: - NanoPi M6 | Support for this FriendlyELEC SBC with RK3588 SoC has been added to DietPi. Enhancements: +- DietPi-Services | "dietpi-services start" will not start disabled services anymore. This aligns with the behaviour of the "restart" command, which as well skips disabled services. The script is used within other DietPi scripts to (re)start services after maintenance operations, and it is unexpected when services, who were not running before, but explicitly disabled, are running afterwards. To manually start/stop individual services from the console, we recommend using "systemctl" directly, like on any other Linux distribution with systemd. Many thanks to @intiplink for reporting this unexpected behaviour while using dietpi-drive_manager: https://github.com/MichaIng/DietPi/issues/7302 - DietPi-Software | NFS Server: The "fsid=0" option has been removed from the /mnt/dietpi_userdata default export. As it is uncommon and not respected in "showmount -e" export lists, it caused confusion and issues. - DietPi-Software | YaCy: The latest YaCy version will now be installed, and the global software password will be set as default admin password on fresh installs. - DietPi-Software | MineOS: As a security enhancement and workaround for a web UI login issue, a dedicated "mineos" user is created again. For new MineOS installs or after reinstall, one can login with this user, and the global software password. It has permissions to install and manage Minecraft instances. diff --git a/dietpi/dietpi-services b/dietpi/dietpi-services index 646992a4d5..f4d42fbef4 100755 --- a/dietpi/dietpi-services +++ b/dietpi/dietpi-services @@ -433,7 +433,8 @@ _EOF_ do # Skip masked services if not to be unmasked [[ $command != 'unmask' && ${aSERVICE_MODE[$i]} == 'masked' ]] && { G_DIETPI-NOTIFY 2 "skip : ${aSERVICE_NAME[$i]} (masked)"; continue; } - [[ $command == 'restart' && ${aSERVICE_MODE[$i]:=$(systemctl is-enabled "${aSERVICE_NAME[$i]}")} == 'disabled' ]] && { G_DIETPI-NOTIFY 2 "skip : ${aSERVICE_NAME[$i]} (disabled)"; continue; } + # Skip (re)start of disabled services + [[ ( $command == 'start' || $command == 'restart' ) && ${aSERVICE_MODE[$i]:=$(systemctl is-enabled "${aSERVICE_NAME[$i]}")} == 'disabled' ]] && { G_DIETPI-NOTIFY 2 "skip : ${aSERVICE_NAME[$i]} (disabled)"; continue; } G_DIETPI-NOTIFY -2 "$command : ${aSERVICE_NAME[$i]}" systemctl -q --no-reload "$command" "${aSERVICE_NAME[$i]}" 2> /dev/null Print_Status "$command" "${aSERVICE_NAME[$i]}" $? From 1aff231e26a14da7458f7fb548b799792c682b56 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 11 Dec 2024 21:34:55 +0100 Subject: [PATCH 49/66] v9.9 - DietPi-Software | Logitech Media Server: LMS has been renamed to Lyrion Music Server. For more details, see their new official website: https://lyrion.org/reference/lyrion-music-server/ --- .meta/dietpi-survey_report | 2 +- CHANGELOG.txt | 1 + dietpi/dietpi-software | 10 +++++----- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index a12747d60f..aef2ee6960 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -241,7 +241,7 @@ shopt -s extglob [32]='ympd' [33]='Airsonic-Advanced' [34]='Subsonic' - [35]='Logitech Media Server' + [35]='Lyrion Media Server' [36]='Squeezelite' [37]='Shairport Sync' [38]='FreshRSS' diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 4b4f455235..43f85ae815 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -13,6 +13,7 @@ Enhancements: - DietPi-Software | MineOS: As a security enhancement and workaround for a web UI login issue, a dedicated "mineos" user is created again. For new MineOS installs or after reinstall, one can login with this user, and the global software password. It has permissions to install and manage Minecraft instances. - DietPi-Software | frp: It is now possible to connect the client to a server which has no (an empty) authentication token configured. frp can now be installed non-interactively, where client + server daemons are both installed and configured to work with each other, with respective defaults for all inputs. - DietPi-Software | frp: Since the ini format for config files has been deprecated, and support will be removed in a future frp release, new installs and reinstalls/updates will generated toml format config files from now on. As of the large amount of config keys, which all changed between those formats, an automated conversion is sadly not possible. When doing a reinstall with existing ini configs, you will be informed about it, the old config(s) will be kept as backup in place, for a manual migration. All config keys for the toml format can be found here: https://github.com/fatedier/frp/tree/dev/conf +- DietPi-Software | Logitech Media Server: LMS has been renamed to Lyrion Music Server. For more details, see their new official website: https://lyrion.org/reference/lyrion-music-server/ Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index b6929c1efb..4736aaf7bc 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -361,8 +361,8 @@ Available commands: aSOFTWARE_DEPS[$software_id]='5 7 196' #------------------ software_id=35 - aSOFTWARE_NAME[$software_id]='Logitech Media Server' - aSOFTWARE_DESC[$software_id]='fka. SlimServer, SqueezeboxServer, SliMP3' + aSOFTWARE_NAME[$software_id]='Lyrion Media Server' + aSOFTWARE_DESC[$software_id]='formerly Logitech Media Server and Squeezebox Server' aSOFTWARE_CATX[$software_id]=2 aSOFTWARE_DOCS[$software_id]='https://dietpi.com/docs/software/media/#logitech-media-server' # - RISC-V: No package: https://lms-community.github.io/lms-server-repository/stable.xml @@ -7037,14 +7037,14 @@ _EOF_ G_EXEC chmod 0600 /etc/haproxy/haproxy.cfg fi - if To_Install 35 logitechmediaserver # Logitech Media Server + if To_Install 35 logitechmediaserver # Lyrion Media Server then # Grab architecture local arch='arm' (( $G_HW_ARCH == 10 )) && arch='amd64' # Grab latest package URL - local fallback_url="https://downloads.lms-community.org/nightly/logitechmediaserver_8.5.1~1712473975_$arch.deb" + local fallback_url="https://downloads.lms-community.org/nightly/lyrionmusicserver_9.0.1~1733855934_$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 @@ -13274,7 +13274,7 @@ _EOF_ [[ -d '/usr/local/share/man/man1' ]] && G_EXEC rmdir -p --ignore-fail-on-non-empty /usr/local/share/man/man1 fi - if To_Uninstall 35 # Logitech Media Server + if To_Uninstall 35 # Lyrion Media Server then # Stop systemd service, which is not done by postinst, failing to remove user then Remove_Service logitechmediaserver From dfdbbd2bf9dba012bcaac5d404619a2b0117e20c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 11 Dec 2024 21:50:47 +0100 Subject: [PATCH 50/66] v9.9 - DietPi-Software | Lyrion Music Server: It is "Music" not "Media" now, reasonably, and as the service name has changed without an alies, we need to migrate it on DietPi update --- .meta/dietpi-survey_report | 2 +- .update/patches | 11 ++++++++++- dietpi/dietpi-services | 2 +- dietpi/dietpi-software | 14 +++++++------- 4 files changed, 19 insertions(+), 10 deletions(-) diff --git a/.meta/dietpi-survey_report b/.meta/dietpi-survey_report index aef2ee6960..45f2b61bcf 100755 --- a/.meta/dietpi-survey_report +++ b/.meta/dietpi-survey_report @@ -241,7 +241,7 @@ shopt -s extglob [32]='ympd' [33]='Airsonic-Advanced' [34]='Subsonic' - [35]='Lyrion Media Server' + [35]='Lyrion Music Server' [36]='Squeezelite' [37]='Shairport Sync' [38]='FreshRSS' diff --git a/.update/patches b/.update/patches index 3ce9dfc38f..6281bd5de3 100755 --- a/.update/patches +++ b/.update/patches @@ -1533,7 +1533,7 @@ Patch_9_2() 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.8' - echo 108 >> /var/tmp/dietpi/dietpi-update_reinstalls + G_EXEC eval 'echo 108 >> /var/tmp/dietpi/dietpi-update_reinstalls' fi fi } @@ -2053,6 +2053,15 @@ Patch_9_9() (( $G_DISTRO < 7 )) || G_EXEC sed -i 's/bullseye/bookworm/g' /etc/apt/sources.list.d/mopidy.list G_EXEC mv /etc/apt/sources.list.d/{,dietpi-}mopidy.list fi + # Logitech Media Server => Lyrion Music Server: https://github.com/MichaIng/DietPi/issues/7306 + if grep -q '^[[:blank:]]*aSOFTWARE_INSTALL_STATE\[35\]=2' /boot/dietpi/.installed && [[ -f '/lib/systemd/system/logitechmediaserver.service' ]] + then + G_DIETPI-NOTIFY 2 'Preparing Logitech Media Server reinstall to migrate to Lyrion Music Server ...' + G_EXEC systemctl --no-reload unmask logitechmediaserver + G_EXEC systemctl --no-reload disable --now logitechmediaserver + G_EXEC eval 'echo 35 >> /var/tmp/dietpi/dietpi-update_reinstalls' + fi + fi } diff --git a/dietpi/dietpi-services b/dietpi/dietpi-services index f4d42fbef4..387ccc3f0b 100755 --- a/dietpi/dietpi-services +++ b/dietpi/dietpi-services @@ -174,7 +174,7 @@ _EOF_ # - Media 'ympd' 'mympd' - 'logitechmediaserver' + 'lyrionmusicserver' 'airsonic' 'mopidy' 'koel' diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 4736aaf7bc..492a8a80d2 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -361,7 +361,7 @@ Available commands: aSOFTWARE_DEPS[$software_id]='5 7 196' #------------------ software_id=35 - aSOFTWARE_NAME[$software_id]='Lyrion Media Server' + aSOFTWARE_NAME[$software_id]='Lyrion Music Server' aSOFTWARE_DESC[$software_id]='formerly Logitech Media Server and Squeezebox Server' aSOFTWARE_CATX[$software_id]=2 aSOFTWARE_DOCS[$software_id]='https://dietpi.com/docs/software/media/#logitech-media-server' @@ -7037,7 +7037,7 @@ _EOF_ G_EXEC chmod 0600 /etc/haproxy/haproxy.cfg fi - if To_Install 35 logitechmediaserver # Lyrion Media Server + if To_Install 35 lyrionmusicserver # Lyrion Music Server then # Grab architecture local arch='arm' @@ -7046,8 +7046,8 @@ _EOF_ # Grab latest package URL local fallback_url="https://downloads.lms-community.org/nightly/lyrionmusicserver_9.0.1~1733855934_$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 + G_EXEC systemctl stop lyrionmusicserver + Remove_SysV lyrionmusicserver # Grant user write access to DietPi media dirs for creating infobrowser.opml. G_EXEC usermod -aG dietpi squeezeboxserver @@ -13274,11 +13274,11 @@ _EOF_ [[ -d '/usr/local/share/man/man1' ]] && G_EXEC rmdir -p --ignore-fail-on-non-empty /usr/local/share/man/man1 fi - if To_Uninstall 35 # Lyrion Media Server + if To_Uninstall 35 # Lyrion Music Server then # Stop systemd service, which is not done by postinst, failing to remove user then - Remove_Service logitechmediaserver - G_AGP logitechmediaserver + Remove_Service lyrionmusicserver + G_AGP lyrionmusicserver [[ -d '/var/lib/squeezeboxserver' ]] && G_EXEC rm -R /var/lib/squeezeboxserver fi From 3913d0d61f1a353b38f098e8604e7cc8b74d4db9 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Wed, 11 Dec 2024 21:57:37 +0100 Subject: [PATCH 51/66] v9.9 - CI | DietPi-Software test: Update service name for LMS --- .github/workflows/dietpi-software.bash | 2 +- .update/patches | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/dietpi-software.bash b/.github/workflows/dietpi-software.bash index 0c3383578a..204f3e118e 100644 --- a/.github/workflows/dietpi-software.bash +++ b/.github/workflows/dietpi-software.bash @@ -105,7 +105,7 @@ Process_Software() 30) aSERVICES[i]='nxserver' aTCP[i]='4000';; 32) aSERVICES[i]='ympd' aTCP[i]='1337';; 33) (( $arch == 10 )) && aSERVICES[i]='airsonic' aTCP[i]='8080' aDELAY[i]=30;; # Fails in QEMU-emulated containers, probably due to missing device access - 35) aSERVICES[i]='logitechmediaserver' aTCP[i]='9000'; (( $arch < 10 )) && aDELAY[i]=60;; + 35) aSERVICES[i]='lyrionmusicserver' aTCP[i]='9000'; (( $arch < 10 )) && aDELAY[i]=60;; 36) aCOMMANDS[i]='squeezelite -t';; # Service listens on random high UDP port and exits if no audio device has been found, which does not exist on GitHub Actions runners, respectively within the containers 37) aSERVICES[i]='shairport-sync' aTCP[i]='5000';; # AirPlay 2 would be TCP port 7000 39) aSERVICES[i]='minidlna' aTCP[i]='8200';; diff --git a/.update/patches b/.update/patches index 6281bd5de3..bb164da1a4 100755 --- a/.update/patches +++ b/.update/patches @@ -2061,7 +2061,6 @@ Patch_9_9() G_EXEC systemctl --no-reload disable --now logitechmediaserver G_EXEC eval 'echo 35 >> /var/tmp/dietpi/dietpi-update_reinstalls' fi - fi } From af587d4801f105192408a794ccef0f17e047d323 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 12 Dec 2024 12:45:20 +0100 Subject: [PATCH 52/66] v9.9 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 492a8a80d2..d4eb768d64 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8606,8 +8606,8 @@ _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='v5.1.1'; 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 == 'v5.'* ]] || version='v5.1.1' + [[ $version ]] || { version='v5.1.3'; 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 == 'v5.'* ]] || version='v5.1.3' Download_Install "https://github.com/Novik/ruTorrent/archive/$version.tar.gz" # - Reinstall freshly with preserved configs and 3rd party plugins @@ -10076,7 +10076,7 @@ _EOF_ 3) local arch='arm64';; *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.4.2686/Readarr.develop.0.4.4.2686.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.5.2699/Readarr.develop.0.4.5.2699.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)" # Install: Remove previous instance on reinstall @@ -10648,7 +10648,7 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.22.4/gitea-1.22.4-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.22.5/gitea-1.22.5-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 @@ -11232,7 +11232,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.2.0/tasmoadmin_v4.2.0.tar.gz' + local fallback_url='https://github.com/TasmoAdmin/TasmoAdmin/releases/download/v4.2.1/tasmoadmin_v4.2.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 77ada0340175af99daa9340f730d55dae52179c2 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 12 Dec 2024 18:45:45 +0100 Subject: [PATCH 53/66] v9.9 - DietPi-Patches | LMS: Avoid that purging the old package removes user, log and data dir which are still in use by the new package. Also purging fails, if the squeezeboxserver user does not exist anymore, since the postrm script tries it unconditionally with "-e" flag. --- .update/patches | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.update/patches b/.update/patches index bb164da1a4..5d129c7d89 100755 --- a/.update/patches +++ b/.update/patches @@ -2059,6 +2059,8 @@ Patch_9_9() G_DIETPI-NOTIFY 2 'Preparing Logitech Media Server reinstall to migrate to Lyrion Music Server ...' G_EXEC systemctl --no-reload unmask logitechmediaserver G_EXEC systemctl --no-reload disable --now logitechmediaserver + # Avoid that purging the old package removes user, log and data dir which are still in use by the new package + G_EXEC sed -i '/^if \[ "$1" = purge \]; then/,/^fi/d' /var/lib/dpkg/info/logitechmediaserver.postrm G_EXEC eval 'echo 35 >> /var/tmp/dietpi/dietpi-update_reinstalls' fi fi From ed5586b534419a1c43472ce3b9f0b7d2279cf349 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Thu, 12 Dec 2024 18:51:51 +0100 Subject: [PATCH 54/66] v9.9 - DietPi-Patches | Satisfy shellcheck --- .update/patches | 1 + 1 file changed, 1 insertion(+) diff --git a/.update/patches b/.update/patches index 5d129c7d89..a3a0ae86c8 100755 --- a/.update/patches +++ b/.update/patches @@ -2060,6 +2060,7 @@ Patch_9_9() G_EXEC systemctl --no-reload unmask logitechmediaserver G_EXEC systemctl --no-reload disable --now logitechmediaserver # Avoid that purging the old package removes user, log and data dir which are still in use by the new package + # shellcheck disable=SC2016 G_EXEC sed -i '/^if \[ "$1" = purge \]; then/,/^fi/d' /var/lib/dpkg/info/logitechmediaserver.postrm G_EXEC eval 'echo 35 >> /var/tmp/dietpi/dietpi-update_reinstalls' fi From a3511e5e875abd7814dbf2dda0a64577d06cbca6 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 15 Dec 2024 14:28:47 +0100 Subject: [PATCH 55/66] v9.9 - 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 d4eb768d64..5cbe2bbf7c 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -10648,7 +10648,7 @@ _EOF_ *) local arch='arm-6';; esac - local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.22.5/gitea-1.22.5-linux-$arch.xz" + local fallback_url="https://github.com/go-gitea/gitea/releases/download/v1.22.6/gitea-1.22.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 370a261f3bf2e81280ecedf9206dd0d1b0bc05ed Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 15 Dec 2024 17:01:33 +0100 Subject: [PATCH 56/66] v9.9 (#7309) - DietPi-DDNS | The "IPv6or4" option to update IPv6 only, if supported by server, network and provider, has been replaced with "IPv4and6". A server being reachable via IPv6 only is rarely wanted, as many networks do not support it. Instead, usually one will want to have it reachable via both, IPv4 as well as IPv6, which is now possible when using DietPi-DDNS, and the new default. If, e.g. for security reason, IPv6 only is wanted, this option of course remains available, like before. Many thanks to @LOGIN-TB for doing this suggestion: https://github.com/MichaIng/DietPi/issues/7278 - DietPi-DDNS | The cron job does now log server response messages and connection errors separately with respective severities. Some DDNS providers do not return an HTTP error code, but an error text embedded into a regular HTTP 200 response. This, as well as success responses can now be seen via "journalctl -t dietpi-ddns". Many thanks to @jtmoon79 for doing this suggestion: https://github.com/MichaIng/DietPi/issues/5954 --- CHANGELOG.txt | 2 + dietpi/dietpi-ddns | 97 ++++++++++++++++++++++++++++++++-------------- 2 files changed, 69 insertions(+), 30 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 43f85ae815..ccfb40a06a 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -7,6 +7,8 @@ New images: - NanoPi M6 | Support for this FriendlyELEC SBC with RK3588 SoC has been added to DietPi. Enhancements: +- DietPi-DDNS | The "IPv6or4" option to update IPv6 only, if supported by server, network and provider, has been replaced with "IPv4and6". A server being reachable via IPv6 only is rarely wanted, as many networks do not support it. Instead, usually one will want to have it reachable via both, IPv4 as well as IPv6, which is now possible when using DietPi-DDNS, and the new default. If, e.g. for security reason, IPv6 only is wanted, this option of course remains available, like before. Many thanks to @LOGIN-TB for doing this suggestion: https://github.com/MichaIng/DietPi/issues/7278 +- DietPi-DDNS | The cron job does now log server response messages and connection errors separately with respective severities. Some DDNS providers do not return an HTTP error code, but an error text embedded into a regular HTTP 200 response. This, as well as success responses can now be seen via "journalctl -t dietpi-ddns". Many thanks to @jtmoon79 for doing this suggestion: https://github.com/MichaIng/DietPi/issues/5954 - DietPi-Services | "dietpi-services start" will not start disabled services anymore. This aligns with the behaviour of the "restart" command, which as well skips disabled services. The script is used within other DietPi scripts to (re)start services after maintenance operations, and it is unexpected when services, who were not running before, but explicitly disabled, are running afterwards. To manually start/stop individual services from the console, we recommend using "systemctl" directly, like on any other Linux distribution with systemd. Many thanks to @intiplink for reporting this unexpected behaviour while using dietpi-drive_manager: https://github.com/MichaIng/DietPi/issues/7302 - DietPi-Software | NFS Server: The "fsid=0" option has been removed from the /mnt/dietpi_userdata default export. As it is uncommon and not respected in "showmount -e" export lists, it caused confusion and issues. - DietPi-Software | YaCy: The latest YaCy version will now be installed, and the global software password will be set as default admin password on fresh installs. diff --git a/dietpi/dietpi-ddns b/dietpi/dietpi-ddns index b19b4ce35d..8327b8eed9 100755 --- a/dietpi/dietpi-ddns +++ b/dietpi/dietpi-ddns @@ -22,11 +22,9 @@ Available options: -p Password or token, depending on provider In combination with a custom provider, this is used for HTTP authentication. -t Duration between DDNS updates in minutes (optional, defaults to 10) - -4 Force IPv4 usage for the DDNS update (optional, the default) - -6 Force IPv6 usage for the DDNS update (optional) - -6or4 Do not force any IP family for the DDNS update (optional) - IPv6 is then used, if enabled on this server and if the DDNS provider is - reachable via IPv6, else IPv4 is used. + -4and6 Update IPv4 and IPv6 addresses for your DDNS (optional, the default) + -4 Update only the IPv4 address for your DDNS (optional) + -6 Update only the IPv6 address for your DDNS (optional) Available providers: Full URL to update against a custom DDNS provider Use the "-u" and "-p" options if HTTP authentication is required. @@ -73,10 +71,10 @@ Input() '-u') shift; USERNAME=$1;; '-p') shift; PASSWORD=$1;; '-t') shift; TIMESPAN=$1;; - '-'[46]|'-6or4') IPFAMILY=$1;; + '-'[46]|'-4and6') IPFAMILY=$1;; 'apply') COMMAND=$1; shift; PROVIDER=$1;; 'remove') COMMAND=$1;; - *) G_DIETPI-NOTIFY 1 "Invalid input ($1). Aborting...$USAGE"; exit 1;; + *) G_DIETPI-NOTIFY 1 "Invalid input ($1). Aborting ...$USAGE"; exit 1;; esac shift done @@ -144,8 +142,24 @@ Read() fi # IP family - [[ $IPFAMILY ]] || IPFAMILY=${command#curl } IPFAMILY=${IPFAMILY%% *} - [[ $IPFAMILY == '-'[46] ]] || IPFAMILY='-6or4' + if [[ ! $IPFAMILY ]] + then + if grep -q 'curl -4 ' /var/lib/dietpi/dietpi-ddns/update.sh + then + if grep -q 'curl -6 ' /var/lib/dietpi/dietpi-ddns/update.sh + then + IPFAMILY='-4and6' + else + IPFAMILY='-4' + fi + + elif grep -q 'curl -6 ' /var/lib/dietpi/dietpi-ddns/update.sh + then + IPFAMILY='-6' + else + IPFAMILY='-4and6' # Pre-v9.9 + fi + fi # Time span [[ ! $TIMESPAN && -f '/var/spool/cron/crontabs/dietpi-ddns' ]] || return @@ -157,8 +171,8 @@ Read() Apply() { # Generate URL and set HTTP authentication flag based on provider - local url http_auth=1 ipfamily=${IPFAMILY:--4} - [[ $ipfamily == '-6or4' ]] && ipfamily= + local url http_auth=1 + [[ $IPFAMILY ]] || IPFAMILY='-4and6' # - DuckDNS if [[ $PROVIDER == 'DuckDNS' ]] then @@ -200,7 +214,7 @@ Apply() fi # Create DietPi-DDNS group - G_DIETPI-NOTIFY 2 'Preparing unprivileged DietPi-DDNS UNIX group...' + G_DIETPI-NOTIFY 2 'Preparing unprivileged DietPi-DDNS UNIX group ...' if getent group dietpi-ddns > /dev/null then G_EXEC groupmod -p '!' dietpi-ddns @@ -209,7 +223,7 @@ Apply() fi # Create DietPi-DDNS user - G_DIETPI-NOTIFY 2 'Preparing unprivileged DietPi-DDNS UNIX user...' + G_DIETPI-NOTIFY 2 'Preparing unprivileged DietPi-DDNS UNIX user ...' if getent passwd dietpi-ddns > /dev/null then G_EXEC usermod -g 'dietpi-ddns' -G '' -d '/nonexistent' -s '/usr/sbin/nologin' -p '!' dietpi-ddns @@ -218,10 +232,10 @@ Apply() fi # Test DDNS update - G_DIETPI-NOTIFY 2 'Testing DDNS update...' + G_DIETPI-NOTIFY 2 'Testing DDNS update ...' local result # shellcheck disable=SC2086 - if ! result=$(curl $ipfamily -sSfL ${http_auth:+ -u "$USERNAME:$PASSWORD"} "$url" 2>&1) || + if ! result=$(curl "${IPFAMILY%and6}" -sSfL ${http_auth:+ -u "$USERNAME:$PASSWORD"} "$url" 2>&1) || [[ $PROVIDER == 'DuckDNS' && $result == 'KO' ]] || [[ $PROVIDER == 'YDNS' && $result != 'good'* && $result != 'nochg'* ]] || [[ $PROVIDER == 'Dynu' && $result != 'good'* && $result != 'nochg'* ]] @@ -231,13 +245,32 @@ Apply() return 1 else STATUS="DDNS update test succeeded${result:+:\n$result}" - G_DIETPI-NOTIFY 2 "$STATUS" + G_DIETPI-NOTIFY 0 "$STATUS" + + # Test IPv6 as well if both are enabled + if [[ $IPFAMILY == '-4and6' ]] + then + G_DIETPI-NOTIFY 2 'Testing IPv6 DDNS update ...' + local status6 + if ! result=$(curl "${IPFAMILY/4and}" -sSfL ${http_auth:+ -u "$USERNAME:$PASSWORD"} "$url" 2>&1) || + [[ $PROVIDER == 'DuckDNS' && $result == 'KO' ]] || + [[ $PROVIDER == 'YDNS' && $result != 'good'* && $result != 'nochg'* ]] || + [[ $PROVIDER == 'Dynu' && $result != 'good'* && $result != 'nochg'* ]] + then + status6="IPv6 DDNS update test failed. Your server, network or DDNS provider might not support IPv6${result:+:\n$result}" + G_DIETPI-NOTIFY 1 "$status6" + else + status6="IPv6 DDNS update test succeeded${result:+:\n$result}" + G_DIETPI-NOTIFY 0 "$status6" + fi + STATUS+="\n\n$status6" + fi fi # Check and in case remove obsolete No-IP client if command -v noip2 > /dev/null then - G_DIETPI-NOTIFY 2 'Removing obsolete No-IP client from your system...' + G_DIETPI-NOTIFY 2 'Removing obsolete No-IP client from your system ...' if [[ -f '/etc/systemd/system/noip2.service' ]] then G_EXEC systemctl disable --now noip2 @@ -262,10 +295,12 @@ Apply() G_EXEC chown dietpi-ddns:dietpi-ddns /var/lib/dietpi/dietpi-ddns/update.sh # Shellcheck false positive: https://github.com/koalaman/shellcheck/issues/2168 # shellcheck disable=SC2016 - echo "curl${ipfamily:+ $ipfamily} -sSfL${http_auth:+ -u '$USERNAME:$PASSWORD'} '$url' 2>&1 > /dev/null | logger -t dietpi-ddns -p 3" >> /var/lib/dietpi/dietpi-ddns/update.sh + echo "{ curl ${IPFAMILY%and6} -sSfL${http_auth:+ -u '$USERNAME:$PASSWORD'} '$url' | logger -t dietpi-ddns -p 6; } 2>&1 | logger -t dietpi-ddns -p 3" >> /var/lib/dietpi/dietpi-ddns/update.sh + # shellcheck disable=SC2016 + [[ $IPFAMILY == '-4and6' ]] && echo "{ curl ${IPFAMILY/4and} -sSfL${http_auth:+ -u '$USERNAME:$PASSWORD'} '$url' | logger -t dietpi-ddns -p 6; } 2>&1 | logger -t dietpi-ddns -p 3" >> /var/lib/dietpi/dietpi-ddns/update.sh # Apply Cron job - G_DIETPI-NOTIFY 2 'Applying DietPi-DDNS Cron job...' + G_DIETPI-NOTIFY 2 'Applying DietPi-DDNS Cron job ...' crontab -u dietpi-ddns - <<< "*/${TIMESPAN:-10} * * * * /var/lib/dietpi/dietpi-ddns/update.sh" } @@ -372,15 +407,16 @@ Menu_Password() Menu_IPfamily() { G_WHIP_MENU_ARRAY=( - 'IPv4' ': Force IPv4 usage for the DDNS update (best compatibility)' - 'IPv6or4' ': Do not force any IP family for the DDNS update' - 'IPv6' ': Force IPv6 usage for the DDNS update (for modern clients)' + 'IPv4and6' ': Update IPv4 and IPv6 addresses for your DDNS' + 'IPv4' ': Update only the IPv4 address for your DDNS' + 'IPv6' ': Update only the IPv6 address for your DDNS' ) - G_WHIP_DEFAULT_ITEM=${IPFAMILY:--4} G_WHIP_DEFAULT_ITEM=${G_WHIP_DEFAULT_ITEM/-/IPv} - G_WHIP_MENU 'Please select whether you want to force an IP family to associate with your DDNS domain. -\nFor best compatibility with all clients and networks, we recommend to use IPv4. -\nIf you do not force any IP family, IPv6 is used, if enabled on this server and if the DDNS provider is reachable via IPv6, else IPv4 is used. -\nIf IPv6 is used, only clients with IPv6 enabled and connected via networks which support IPv6 can reach your server.' || return 1 + G_WHIP_DEFAULT_ITEM=${IPFAMILY/-/IPv} + G_WHIP_MENU 'Please select which IP family address to associate with your DDNS domain. +\nUsually one would want to update both, the IPv4 and IPv6 address, if your server has one. +\nIf you do not have a public IPv6 address, or want to keep the amount of DDNS requests low, update the IPv4 address only. +\nIf you have a public IPv6 address, want to support only clients with IPv6 enabled, and connected via networks which support IPv6, then you could update the IPv6 address only. +Choosing this could lower requests and attacks from random bots, which almost always try to connect via IPv4. But it can prevent your own/intended clients from being able to connect.' || return 1 IPFAMILY=${G_WHIP_RETURNED_VALUE/IPv/-} } @@ -405,7 +441,7 @@ Menu_Main() [[ $PROVIDER == 'DuckDNS' || $PROVIDER == 'Dynu' || $PROVIDER == 'FreeDNS' || $PROVIDER == 'YDNS' ]] || G_WHIP_MENU_ARRAY+=("$username" ": [$USERNAME]") G_WHIP_MENU_ARRAY+=( "$password" ": [${PASSWORD//?/*}]" - 'IP family' ": [${IPFAMILY:--4}]" + 'IP family' ": [${IPFAMILY/-/IPv}]" 'Timespan' ": [${TIMESPAN:-10} minutes]" '' '●─ Apply ' 'Apply' ': Create or update Cron job with above settings' @@ -447,7 +483,7 @@ then then Remove || exit 1 else - G_DIETPI-NOTIFY 1 "Input found but no command. Aborting...$USAGE" + G_DIETPI-NOTIFY 1 "Input found but no command. Aborting ...$USAGE" exit 1 fi @@ -455,10 +491,11 @@ then else # Read current settings from existing Cron job Read + [[ $IPFAMILY ]] || IPFAMILY='-4and6' # Read status of existing Cron job via last two journal lines: "dietpi-ddns" tag shows curl errors, "cron" tag with "dietpi-ddns" string shows Cron job execution STATUS='Manage DDNS settings to keep your dynamic IP with the static domain provided by your DDNS provider in sync' - [[ $PROVIDER ]] && STATUS="Last DietPi-DDNS logs:\n$(journalctl -r -t dietpi-ddns -t CRON | grep -m2 dietpi-ddns)" + [[ $PROVIDER ]] && STATUS="Last DietPi-DDNS logs:\n$(journalctl -r -t dietpi-ddns -t CRON | grep -m4 dietpi-ddns | sort)" NEXT_MENU_START='Provider' while Menu_Main; do :; done From 72c72e6690039227a186744aeb4ab03bc69adbcb Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 15 Dec 2024 17:58:24 +0100 Subject: [PATCH 57/66] v9.9 (#7307) - DietPi-Software | Move to Sonarr v4 --- CHANGELOG.txt | 1 + dietpi/dietpi-software | 83 +++++++++++++++++++++++++++++++++--------- 2 files changed, 67 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index ccfb40a06a..76b2e25ae6 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -16,6 +16,7 @@ Enhancements: - DietPi-Software | frp: It is now possible to connect the client to a server which has no (an empty) authentication token configured. frp can now be installed non-interactively, where client + server daemons are both installed and configured to work with each other, with respective defaults for all inputs. - DietPi-Software | frp: Since the ini format for config files has been deprecated, and support will be removed in a future frp release, new installs and reinstalls/updates will generated toml format config files from now on. As of the large amount of config keys, which all changed between those formats, an automated conversion is sadly not possible. When doing a reinstall with existing ini configs, you will be informed about it, the old config(s) will be kept as backup in place, for a manual migration. All config keys for the toml format can be found here: https://github.com/fatedier/frp/tree/dev/conf - DietPi-Software | Logitech Media Server: LMS has been renamed to Lyrion Music Server. For more details, see their new official website: https://lyrion.org/reference/lyrion-music-server/ +- DietPi-Software | Sonarr: Sonarr v4 will be installed from now on, and a migration to Sonarr v4 is now possible by reinstall it via "dietpi-software reinstall 144". Note that, since Sonarr v4 does not support ARMv6, this is not the case and not possible on RPi 1 and Zero (1). After a migration, once might want to uninstall Mono, which is not required for Sonarr v4 anymore. Note that some settings may be lost as of the database migration. At best create a backup, offered before the reinstall, and inform yourself about possible database migration issues and losses on the Sonarr websites. Bug fixes: - NanoPi M1 Plus | Resolved an issue where Ethernet did not work because of a faulty kernel patch. Many thanks to @InnovoMagicCube and @InnovoDeveloper for reporting this issue: https://github.com/MichaIng/DietPi/issues/6974 diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 5cbe2bbf7c..b7e7a75b18 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -663,7 +663,8 @@ Available commands: aSOFTWARE_DESC[$software_id]='Automatically download TV shows' aSOFTWARE_CATX[$software_id]=3 aSOFTWARE_DOCS[$software_id]='https://dietpi.com/docs/software/bittorrent/#sonarr' - aSOFTWARE_DEPS[$software_id]='87 150' + aSOFTWARE_DEPS[$software_id]='87' + (( $G_HW_ARCH == 1 )) && aSOFTWARE_DEPS[$software_id]+=' 150' # - RISC-V: Missing package aSOFTWARE_AVAIL_G_HW_ARCH[$software_id,11]=0 #------------------ @@ -9488,23 +9489,71 @@ _EOF_ if To_Install 144 sonarr # Sonarr then - # https://sonarr.tv/#downloads-v3-linux-debian - # APT key - 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' + # Sonarr v4 does not support ARMv6 + if (( $G_HW_ARCH == 1 )) + then + # https://sonarr.tv/#downloads-v3-linux-debian + # APT key + 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' + # 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' - # Update package lists - G_AGUP + # Update package lists + G_AGUP - # Pre-configure DEB package - G_EXEC eval "debconf-set-selections <<< 'sonarr sonarr/owning_group string dietpi'" - G_EXEC eval "debconf-set-selections <<< 'sonarr sonarr/config_directory string /mnt/dietpi_userdata/sonarr'" + # Pre-configure DEB package + G_EXEC eval "debconf-set-selections <<< 'sonarr sonarr/owning_group string dietpi'" + G_EXEC eval "debconf-set-selections <<< 'sonarr sonarr/config_directory string /mnt/dietpi_userdata/sonarr'" + + # Install Sonarr and mediainfo + G_AGI sonarr mediainfo + G_EXEC systemctl stop sonarr + + local install_dir='/usr/lib/sonarr' + local exe="$(command -v mono) $install_dir/bin/Sonarr.exe" + else + # Pre-v9.9 cleanup + [[ -f '/etc/apt/sources.list.d/sonarr.list' ]] && G_EXEC rm /etc/apt/sources.list.d/sonarr.list + [[ -f '/etc/apt/trusted.gpg.d/dietpi-sonarr.gpg' ]] && G_EXEC rm /etc/apt/trusted.gpg.d/dietpi-sonarr.gpg + if dpkg-query -s 'sonarr' &> /dev/null + then + G_AGP sonarr + # Offer to uninstall Mono + if (( ${aSOFTWARE_INSTALL_STATE[150]} == 2 )) + then + G_WHIP_BUTTON_OK_TEXT='Yes' G_WHIP_BUTTON_CANCEL_TEXT='No' G_WHIP_DEFAULT_ITEM='Yes' + G_WHIP_YESNO '[ INFO ] Mono is no dependency of Sonarr v4 anymore +\nA migration from Sonarr v3 to Sonarr v4 is done, which does not require Mono anymore. If you do not need Mono for something else, it can hence be uninstalled to free up some space. +\nDo you want to uninstall Mono now? It can be done any time later via "dietpi-software".' && aSOFTWARE_INSTALL_STATE[150]=-1 + fi + fi - # Install Sonarr and mediainfo - G_AGI sonarr mediainfo - G_EXEC systemctl stop sonarr + # APT dependencies + aDEPS=('mediainfo') + # - .NET: https://github.com/dotnet/docs/blob/main/docs/core/install/linux-debian.md#dependencies + case $G_DISTRO in + 6) aDEPS+=('libicu67');; + *) aDEPS+=('libicu72');; + esac + + # Download + case $G_HW_ARCH in + 2) local arch='arm';; + 3) local arch='arm64';; + *) local arch='x64';; + esac + + local fallback_url="https://github.com/Sonarr/Sonarr/releases/download/v4.0.11.2680/Sonarr.main.4.0.11.2680.linux-$arch.tar.gz" + Download_Install "$(curl -sSfL 'https://api.github.com/repos/Sonarr/Sonarr/releases/latest' | mawk -F\" "/^ *\"browser_download_url\": \".*linux-$arch\.tar\.gz\"$/{print \$4}")" + + # Install: Remove previous instance on reinstall + [[ -d '/opt/sonarr' ]] && G_EXEC rm -R /opt/sonarr + G_EXEC mv Sonarr /opt/sonarr + + local install_dir='/opt/sonarr' + local exe="$install_dir/Sonarr" + fi # Pre-v7.1: Remove Sonarr v2 key, PID file and database backups from DietPi-Arr_to_RAM if [[ -f '/etc/apt/trusted.gpg' && $(apt-key --keyring /etc/apt/trusted.gpg list 'A236C58F409091A18ACA53CBEBFF6B99D9B78493' 2> /dev/null) ]] @@ -9535,7 +9584,7 @@ SyslogIdentifier=Sonarr User=sonarr UMask=002 LogsDirectory=sonarr -ExecStart=$(command -v mono) /usr/lib/sonarr/bin/Sonarr.exe -nobrowser -data=/mnt/dietpi_userdata/sonarr +ExecStart=$exe -nobrowser -data=/mnt/dietpi_userdata/sonarr TimeoutStopSec=20 KillMode=process Restart=on-failure @@ -9559,7 +9608,7 @@ _EOF_ G_EXEC ln -s /var/log/sonarr/logs.db-wal /mnt/dietpi_userdata/sonarr/logs.db-wal # Permissions - G_EXEC chown -R sonarr:dietpi /mnt/dietpi_userdata/sonarr /usr/lib/sonarr + G_EXEC chown -R sonarr:dietpi /mnt/dietpi_userdata/sonarr "$install_dir" fi if To_Install 145 radarr # Radarr @@ -12883,7 +12932,7 @@ _EOF_ Remove_Service sonarr 1 1 # group for pre-v6.29 G_AGP sonarr nzbdrone # Pre-v7.1 [[ -d '/var/log/sonarr' ]] && G_EXEC rm -R /var/log/sonarr - G_EXEC rm -Rf /mnt/dietpi_userdata/sonarr /opt/NzbDrone # Pre-v7.1 + G_EXEC rm -Rf /opt/sonarr /mnt/dietpi_userdata/sonarr /opt/NzbDrone # Pre-v7.1 [[ -f '/etc/apt/sources.list.d/sonarr.list' ]] && G_EXEC rm /etc/apt/sources.list.d/sonarr.list [[ -f '/etc/apt/trusted.gpg.d/dietpi-sonarr.gpg' ]] && G_EXEC rm /etc/apt/trusted.gpg.d/dietpi-sonarr.gpg # Pre-v7.1: Remove Sonarr v2 key From 957667a1661cb635c3b85a8b74c1b61fa4e004c0 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 15 Dec 2024 18:00:25 +0100 Subject: [PATCH 58/66] v9.9 - DietPi-Software | Update rutorrent fallback URL --- dietpi/dietpi-software | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index b7e7a75b18..5095f10cd7 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -8607,8 +8607,8 @@ _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='v5.1.3'; 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 == 'v5.'* ]] || version='v5.1.3' + [[ $version ]] || { version='v5.1.4'; 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 == 'v5.'* ]] || version='v5.1.4' Download_Install "https://github.com/Novik/ruTorrent/archive/$version.tar.gz" # - Reinstall freshly with preserved configs and 3rd party plugins From c7e757291042babcddfd58ff3f9a6e08d20cf5ce Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 15 Dec 2024 18:16:15 +0100 Subject: [PATCH 59/66] v9.9 - DietPi-Installer | Enable systemd-logind by default on VMs for ACPI functionality, required for shutdown/reboot via virtualiser. It is usually expected by users, and VMs are usually not that low on resources, that those two processes with ~10 MiB additional RAM usage would cause any issues. --- .build/images/dietpi-build | 1 - .build/images/dietpi-installer | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 1c850759cd..8f223bff03 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -1262,7 +1262,6 @@ then # - Mount and edit dietpi.txt G_EXEC mkdir rootfs G_EXEC mount "${FP_LOOP}p1" rootfs - G_CONFIG_INJECT 'AUTO_UNMASK_LOGIND=' 'AUTO_UNMASK_LOGIND=1' rootfs/boot/dietpi.txt # - Remove loop device G_EXEC sync G_EXEC sleep 1 diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 2c376c2ad3..8b5ca734a0 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -1021,6 +1021,8 @@ setenv rootuuid "true"' /boot/boot.cmd then # VM: Install tiny-initramfs with limited features but sufficient and much smaller + faster apackages+=('tiny-initramfs') + # Enable systemd-logind by default for ACPI functionality, required for shutdown/reboot via virtualiser + G_CONFIG_INJECT 'AUTO_UNMASK_LOGIND=' 'AUTO_UNMASK_LOGIND=1' /boot/dietpi.txt else # Install and use zstd for better initramfs compression apackages+=('initramfs-tools' 'zstd') From d8338cff26e0c19d2cb93ac3fe9b8056e5649e19 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Sun, 15 Dec 2024 18:23:54 +0100 Subject: [PATCH 60/66] v9.9 - DietPi-Build | Complement Proxmix image code change as systemd-logind is now enabled by default --- .build/images/dietpi-build | 16 ---------------- CHANGELOG.txt | 1 + 2 files changed, 1 insertion(+), 16 deletions(-) diff --git a/.build/images/dietpi-build b/.build/images/dietpi-build index 8f223bff03..ddf9b67d94 100755 --- a/.build/images/dietpi-build +++ b/.build/images/dietpi-build @@ -1253,22 +1253,6 @@ fi ####### Proxmox ############################ if [[ $VMTYPE =~ ^(proxmox|all)$ ]] then - # Enable systemd-logind for APCI functionality - # - Create loop device - FP_LOOP=$(losetup -f) - G_EXEC losetup "$FP_LOOP" "$OUTPUT_IMG_NAME.img" - G_EXEC partprobe "$FP_LOOP" - G_EXEC partx -u "$FP_LOOP" - # - Mount and edit dietpi.txt - G_EXEC mkdir rootfs - G_EXEC mount "${FP_LOOP}p1" rootfs - # - Remove loop device - G_EXEC sync - G_EXEC sleep 1 - G_EXEC umount -R rootfs - G_EXEC rmdir rootfs - G_EXEC losetup -d "$FP_LOOP" - # Convert raw image to QCOW2 image_name=${OUTPUT_IMG_NAME/_VM-/_Proxmox-} G_EXEC qemu-img convert -c -O qcow2 "$OUTPUT_IMG_NAME.img" "$image_name.qcow2" diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 76b2e25ae6..76c63b86c1 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -7,6 +7,7 @@ New images: - NanoPi M6 | Support for this FriendlyELEC SBC with RK3588 SoC has been added to DietPi. Enhancements: +- Virtual Machines | systemd-logind is now enabled by default on VMs, as it provides ACPI functionality, needed to properly shutdown or reboot the VM from the virtualiser software, usually expected by users. - DietPi-DDNS | The "IPv6or4" option to update IPv6 only, if supported by server, network and provider, has been replaced with "IPv4and6". A server being reachable via IPv6 only is rarely wanted, as many networks do not support it. Instead, usually one will want to have it reachable via both, IPv4 as well as IPv6, which is now possible when using DietPi-DDNS, and the new default. If, e.g. for security reason, IPv6 only is wanted, this option of course remains available, like before. Many thanks to @LOGIN-TB for doing this suggestion: https://github.com/MichaIng/DietPi/issues/7278 - DietPi-DDNS | The cron job does now log server response messages and connection errors separately with respective severities. Some DDNS providers do not return an HTTP error code, but an error text embedded into a regular HTTP 200 response. This, as well as success responses can now be seen via "journalctl -t dietpi-ddns". Many thanks to @jtmoon79 for doing this suggestion: https://github.com/MichaIng/DietPi/issues/5954 - DietPi-Services | "dietpi-services start" will not start disabled services anymore. This aligns with the behaviour of the "restart" command, which as well skips disabled services. The script is used within other DietPi scripts to (re)start services after maintenance operations, and it is unexpected when services, who were not running before, but explicitly disabled, are running afterwards. To manually start/stop individual services from the console, we recommend using "systemctl" directly, like on any other Linux distribution with systemd. Many thanks to @intiplink for reporting this unexpected behaviour while using dietpi-drive_manager: https://github.com/MichaIng/DietPi/issues/7302 From c406924aff0b0f953e26e8a96ba52c8570ac3dd9 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 23 Dec 2024 09:54:43 +0700 Subject: [PATCH 61/66] v9.9 - DietPi-Software | Update fallback URLs - CI | Squeezelite: Update Trixie dependencies --- .build/software/squeezelite/build.bash | 2 +- dietpi/dietpi-software | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.build/software/squeezelite/build.bash b/.build/software/squeezelite/build.bash index a21169ae0b..5abcdc5f7b 100755 --- a/.build/software/squeezelite/build.bash +++ b/.build/software/squeezelite/build.bash @@ -11,7 +11,7 @@ adeps=('libc6' 'libasound2' 'libmad0' 'libvorbisfile3' 'libmpg123-0' 'libsoxr0' case $G_DISTRO in 6) adeps+=('libflac8' 'libavformat58' 'libssl1.1');; 7) adeps+=('libflac12' 'libavformat59' 'libssl3');; - 8) adeps+=('libflac12' 'libavformat60' 'libssl3');; + 8) adeps+=('libflac12' 'libavformat61' 'libssl3');; *) G_DIETPI-NOTIFY 1 "Unsupported distro version: $G_DISTRO_NAME (ID=$G_DISTRO)"; exit 1;; esac for i in "${adeps[@]}" diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 5095f10cd7..f58dea51d4 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6227,7 +6227,7 @@ _EOF_ *) local arch='amd64';; esac - local fallback_url="https://github.com/navidrome/navidrome/releases/download/v0.53.3/navidrome_0.53.3_linux_$arch.tar.gz" + local fallback_url="https://github.com/navidrome/navidrome/releases/download/v0.54.2/navidrome_0.54.2_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 @@ -8607,8 +8607,8 @@ _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='v5.1.4'; 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 == 'v5.'* ]] || version='v5.1.4' + [[ $version ]] || { version='v5.1.5'; 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 == 'v5.'* ]] || version='v5.1.5' Download_Install "https://github.com/Novik/ruTorrent/archive/$version.tar.gz" # - Reinstall freshly with preserved configs and 3rd party plugins @@ -10125,7 +10125,7 @@ _EOF_ 3) local arch='arm64';; *) local arch='x64';; esac - local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.5.2699/Readarr.develop.0.4.5.2699.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Readarr/Readarr/releases/download/v0.4.6.2711/Readarr.develop.0.4.6.2711.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)" # Install: Remove previous instance on reinstall @@ -10641,7 +10641,7 @@ _EOF_ *) 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 fallback_url="https://github.com/gogs/gogs/releases/download/v0.13.1/gogs_0.13.1_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 From cd1a147a71bc8f32ca7eceb6147a41322fb6bf9c Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 23 Dec 2024 10:26:17 +0700 Subject: [PATCH 62/66] v9.9 - DietPi-Software | Update fallback URLs --- dietpi/dietpi-software | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index f58dea51d4..52992df981 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6533,7 +6533,7 @@ _EOF_ esac # Download - local fallback_url="https://github.com/fatedier/frp/releases/download/v0.61.0/frp_0.61.0_linux_$arch.tar.gz" + local fallback_url="https://github.com/fatedier/frp/releases/download/v0.61.1/frp_0.61.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_* @@ -7501,7 +7501,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.14.1/komga-1.14.1.jar' + local fallback_url='https://github.com/gotson/komga/releases/download/1.15.1/komga-1.15.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 @@ -7600,10 +7600,10 @@ _EOF_ # Download: Ampache v7 requires PHP 8.2 if (( $G_DISTRO > 6 )) then - local fallback_url="https://github.com/ampache/ampache/releases/download/7.0.1/ampache-7.0.1_all_php$PHP_VERSION.zip" + local fallback_url="https://github.com/ampache/ampache/releases/download/7.1.1/ampache-7.1.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 else - local fallback_url="https://github.com/ampache/ampache/releases/download/6.6.4/ampache-6.6.4_all_php$PHP_VERSION.zip" + local fallback_url="https://github.com/ampache/ampache/releases/download/6.6.5/ampache-6.6.5_all_php$PHP_VERSION.zip" Download_Install "$(curl -sSfL 'https://api.github.com/repos/ampache/ampache/releases' | mawk -F\" "/^ *\"browser_download_url\": \".*\/ampache-[0-9\.]*_all_php$PHP_VERSION.zip\"$/{print \$4}")" ampache fi @@ -9636,7 +9636,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.15.1.9463/Radarr.master.5.15.1.9463.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Radarr/Radarr/releases/download/v5.16.3.9541/Radarr.master.5.16.3.9541.linux-core-$arch.tar.gz" fi Download_Install "$url" @@ -9726,7 +9726,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.7.1.4417/Lidarr.master.2.7.1.4417.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Lidarr/Lidarr/releases/download/v2.8.2.4493/Lidarr.master.2.8.2.4493.linux-core-$arch.tar.gz" fi Download_Install "$url" @@ -10057,7 +10057,7 @@ _EOF_ 3) local arch='arm64';; *) local arch='x64';; esac - local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.27.0.4852/Prowlarr.master.1.27.0.4852.linux-core-$arch.tar.gz" + local fallback_url="https://github.com/Prowlarr/Prowlarr/releases/download/v1.28.2.4885/Prowlarr.master.1.28.2.4885.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}")" # Install: Remove previous instance on reinstall From 251dfc30fe103854a969178418e392a6b20ccdfd Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 23 Dec 2024 11:31:58 +0700 Subject: [PATCH 63/66] v9.9 - RC up --- .update/version | 2 +- CHANGELOG.txt | 2 +- dietpi/func/dietpi-globals | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.update/version b/.update/version index c3a736ce59..0f107f5c7b 100644 --- a/.update/version +++ b/.update/version @@ -3,7 +3,7 @@ # Available DietPi version G_REMOTE_VERSION_CORE=9 G_REMOTE_VERSION_SUB=9 -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 76c63b86c1..e346bf7e00 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,5 +1,5 @@ v9.9 -(2024-11-16) +(2024-11-23) New images: - Orange Pi 5 Max | Support for this new variant of the Orange Pi 5 family has been added to DietPi. diff --git a/dietpi/func/dietpi-globals b/dietpi/func/dietpi-globals index 44ed22332f..a77d84b5fa 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=9 - [[ $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 3e31ecd57a0c1e75bd08e2a0688b708cccb78da8 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 23 Dec 2024 11:52:07 +0700 Subject: [PATCH 64/66] v9.9 - CHANGELOG | Add release PR --- CHANGELOG.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index e346bf7e00..002ede3efd 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -31,7 +31,7 @@ Bug fixes: - DietPi-Software | Node.js: Resolved an issue where node failed on ARMv7 Bullseye systems, since the latest version for this architecture requires a newer C++ standard library than provided on Bullseye. - DietPi-Software | frp: Resolved an issue where server address and port inputs for the client config generation were parsed incorrectly. -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/7313 ----------------------------------------------------------------------------------------------------------- From 55421790bdc5b1a5d98c9d33fab1024faf9101b4 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 23 Dec 2024 13:42:15 +0700 Subject: [PATCH 65/66] v9.9 - DietPi-Installer | Add mawk as installer dependency, as it is not essential in Debian anymore (any awk implementation satisfies essential dependencies), and has been found missing in one case: https://github.com/MichaIng/DietPi/issues/7311 --- .build/images/dietpi-installer | 1 + 1 file changed, 1 insertion(+) diff --git a/.build/images/dietpi-installer b/.build/images/dietpi-installer index 8b5ca734a0..60443c18a4 100755 --- a/.build/images/dietpi-installer +++ b/.build/images/dietpi-installer @@ -115,6 +115,7 @@ _EOF_ 'curl' # Download DietPi-Globals... 'ca-certificates' # ...via HTTPS 'whiptail' # G_WHIP + 'mawk' # lightweight awk implementation used in DietPi ) for i in "${aAPT_PREREQS[@]}" do From aafe99d4341d22fe9e823f84d6d24203387479de Mon Sep 17 00:00:00 2001 From: MichaIng Date: Mon, 23 Dec 2024 16:41:20 +0700 Subject: [PATCH 66/66] v9.9 - CHANGELOG | Update new image changelogs --- CHANGELOG.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 002ede3efd..4e5da62e14 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,9 +2,9 @@ v9.9 (2024-11-23) New images: -- Orange Pi 5 Max | Support for this new variant of the Orange Pi 5 family has been added to DietPi. -- Orange Pi 5 Pro | Support for this new variant of the Orange Pi 5 family has been added to DietPi. -- NanoPi M6 | Support for this FriendlyELEC SBC with RK3588 SoC has been added to DietPi. +- Orange Pi 5 Pro | Support for this new variant of the Orange Pi 5 family has been added to DietPi. Compared to the original Orange Pi 5, it features onboard WiFi 5, an eMMC slot, dual HDMI, and supports NVMe SSDs up to 2280 format. +- Orange Pi 5 Max | Support for this new variant of the Orange Pi 5 family has been added to DietPi. Compared to the Orange Pi 5 Pro, it features onboard WiFi 6E and 2.5G Ethernet. +- NanoPi M6 | Support for this FriendlyELEC SBC with RK3588 SoC has been added to DietPi. Compared to the NanoPi R6S/R6C and NanoPC T6, aside of the great onboard features, we observed a significantly lower idle power usage. As usual, the optional metal case keeps it at cool temperatures, and has an LCD display builtin, which can be enabled via device tree overlay in DietPi. A related dietpi-config toggle is added with next release. Enhancements: - Virtual Machines | systemd-logind is now enabled by default on VMs, as it provides ACPI functionality, needed to properly shutdown or reboot the VM from the virtualiser software, usually expected by users.