Merge pull request #537 from fewtarius/dev

Move fstrim to autostart so it doesn't block sleep.
This commit is contained in:
fewtarius 2022-09-23 15:26:08 -04:00 committed by GitHub
commit 7617d336a9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 2 additions and 3 deletions

View file

@ -0,0 +1,2 @@
SVC="fstrim.timer"
DAEMONS=("fstrim")

View file

@ -92,5 +92,4 @@ post_install () {
if [ "${SWAP_SUPPORT}" = "yes" ]; then
enable_service swap.service
fi
enable_service fstrim.timer
}

View file

@ -3,7 +3,5 @@ Description=Discard unused blocks on all filesystems
[Service]
Type=oneshot
# don't run immediately on boot when timer event was missed
ExecStartPre=-/usr/bin/sleep 20
ExecStart=-/usr/sbin/fstrim --all --verbose --quiet-unsupported
ExecStart=-/usr/bin/touch /storage/.cache/fstrim.run