From da3181c20cc707e5a89a99cc58f0276a9660bf30 Mon Sep 17 00:00:00 2001 From: Haylin Moore Date: Mon, 9 Mar 2026 13:32:41 -0700 Subject: [PATCH] nixosTests.calibre-web: fix test failure with PrivateTmp hardening The service hardening added PrivateTmp=true, which conflicts with the test library path under /tmp. Move the library to /var/lib/test-books. --- nixos/tests/calibre-web.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/nixos/tests/calibre-web.nix b/nixos/tests/calibre-web.nix index cf66ed1f1921..27080e5626ba 100644 --- a/nixos/tests/calibre-web.nix +++ b/nixos/tests/calibre-web.nix @@ -3,6 +3,7 @@ let port = 3142; defaultPort = 8083; + libraryPath = "/var/lib/test-books"; in { name = "calibre-web"; @@ -16,7 +17,7 @@ in enable = true; listen.port = port; options = { - calibreLibrary = "/tmp/books"; + calibreLibrary = libraryPath; reverseProxyAuth = { enable = true; header = "X-User"; @@ -30,7 +31,7 @@ in start_all() customized.succeed( - "mkdir /tmp/books && calibredb --library-path /tmp/books add -e --title test-book" + "mkdir -p ${libraryPath} && calibredb --library-path ${libraryPath} add -e --title test-book" ) customized.succeed("systemctl restart calibre-web") customized.wait_for_unit("calibre-web.service")