; systemd/smart-test.service
; Runs scripts/smart-test-weekly.sh. Oneshot, triggered by
; smart-test.timer (not enabled for WantedBy= directly).
[Unit]
Description=SMART short self-test (homelab)
Documentation=https://mercemay.top/src/homelab-compose/
After=local-fs.target
ConditionPathExists=/srv/homelab/scripts/smart-test-weekly.sh
[Service]
Type=oneshot
User=root
Group=root
Nice=15
IOSchedulingClass=idle
ProtectSystem=full
ProtectHome=yes
NoNewPrivileges=yes
CapabilityBoundingSet=CAP_SYS_RAWIO CAP_SYS_ADMIN CAP_DAC_READ_SEARCH
ExecStart=/srv/homelab/scripts/smart-test-weekly.sh
StandardOutput=journal
StandardError=journal