aboutsummaryrefslogtreecommitdiff
path: root/scripts/testing/lib/validation.sh
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/testing/lib/validation.sh')
-rw-r--r--scripts/testing/lib/validation.sh7
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/testing/lib/validation.sh b/scripts/testing/lib/validation.sh
index f6e7fbf..91270ef 100644
--- a/scripts/testing/lib/validation.sh
+++ b/scripts/testing/lib/validation.sh
@@ -687,9 +687,12 @@ validate_all_services() {
validate_service_optional "cups" "enabled"
validate_service_optional "docker" "enabled"
validate_service_optional "tailscaled" "enabled"
- # Syncthing uses user service (not system), check lingering is enabled
+ # Syncthing uses user service (not system), check lingering is enabled.
+ # test -e, not ls: ls prints the path on success, so the old capture held
+ # "path\nyes" and could never equal "yes" — the check warned on every
+ # run, even with lingering correctly enabled.
step "Checking user lingering for syncthing"
- local linger_enabled=$(ssh_cmd "ls /var/lib/systemd/linger/cjennings 2>/dev/null && echo yes || echo no")
+ local linger_enabled=$(ssh_cmd "test -e /var/lib/systemd/linger/cjennings && echo yes || echo no")
if [ "$linger_enabled" = "yes" ]; then
validation_pass "User lingering enabled for syncthing user service"
else