@@ -186,9 +186,6 @@ Patch_7_3()
186
186
# This is required to call our software CLI wrapper scripts, which contain "sudo -u <service_user>" to assure correct config and data is loaded.
187
187
[[ -f ' /etc/sudoers.d/dietpi' ]] && echo ' dietpi ALL=(ALL:ALL) NOPASSWD: ALL' > /etc/sudoers.d/dietpi
188
188
189
- # When haveged from Bullseye was installed on Buster (on ARM to workaround a bug), mark the related library as auto-installed so that it can be autoremoved when haveged itself is removed.
190
- dpkg-query -s haveged & > /dev/null && dpkg-query -s libhavege2 & > /dev/null && G_EXEC apt-mark auto libhavege2
191
-
192
189
# Update DietPi-Backup filter file
193
190
if [[ -f ' /boot/dietpi/.dietpi-backup_inc_exc' && $( head -1 /boot/dietpi/.dietpi-backup_inc_exc) != ' # DietPi-Backup include/exclude filter' ]]
194
191
then
@@ -306,17 +303,8 @@ Patch_7_6()
306
303
G_EXEC curl -sSfLO " https://dietpi.com/downloads/binaries/buster/haveged_$G_HW_ARCH_NAME .deb"
307
304
G_AGI " ./libhavege2_$G_HW_ARCH_NAME .deb" " ./haveged_$G_HW_ARCH_NAME .deb"
308
305
G_EXEC rm " ./libhavege2_$G_HW_ARCH_NAME .deb" " ./haveged_$G_HW_ARCH_NAME .deb"
309
- fi
310
-
311
- # https://github.com/MichaIng/DietPi/issues/4710
312
- if [[ $G_DISTRO -ge 5 && $G_HW_ARCH == 2 ]] && dpkg-query -s haveged & > /dev/null
313
- then
314
- G_DIETPI-NOTIFY 2 ' Applying workaround for haveged entropy daemon bug:'
315
- G_DIETPI-NOTIFY 2 ' - https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=985196'
316
- G_EXEC mkdir -p /etc/systemd/system/haveged.service.d
317
- G_EXEC eval " echo -e '[Service]\nSystemCallFilter=uname' > /etc/systemd/system/haveged.service.d/dietpi.conf"
318
- G_EXEC systemctl daemon-reload
319
- G_EXEC systemctl restart haveged
306
+ # Mark the library as auto-installed so that it can be autoremoved when haveged itself is removed.
307
+ G_EXEC apt-mark auto libhavege2
320
308
fi
321
309
}
322
310
@@ -743,6 +731,16 @@ Patch_8_4()
743
731
G_EXEC rm /etc/kernel/preinst.d/dietpi-initramfs_cleanup
744
732
G_EXEC rmdir --ignore-fail-on-non-empty /etc/kernel/preinst.d
745
733
fi
734
+
735
+ # https://github.com/MichaIng/DietPi/issues/4710
736
+ if (( $G_HW_ARCH == 2 )) && dpkg-query -s haveged & > /dev/null
737
+ then
738
+ G_DIETPI-NOTIFY 2 ' Applying workaround for haveged entropy daemon bug: https://bugs.debian.org/985196'
739
+ [[ -d ' /etc/systemd/system/haveged.service.d' ]] || G_EXEC mkdir /etc/systemd/system/haveged.service.d
740
+ G_EXEC eval ' echo -e ' \' ' [Service]\nSystemCallFilter=uname' \' ' > /etc/systemd/system/haveged.service.d/dietpi.conf'
741
+ G_EXEC systemctl daemon-reload
742
+ G_EXEC systemctl restart haveged
743
+ fi
746
744
}
747
745
748
746
# v6.35 => v7 migration
0 commit comments