guix/nix
Rutherther 2a0ac4cba5
daemon: Ensure store is writable even as non-root.
If the store is read only, return an error early.
This is bit of a compromise. Not all operations of the daemon need the store
as writable. For example, if hello package is built already `guix build hello`
could previously succeed even if store is RO.

* nix/libstore/local-store.cc
(makeStoreWritable): Rename to ensureStoreWritable.
(ensureStoreWritable): As non-root, check that the store is writable and if
not, throw an error.
(LocalStore::LocalStore): Use it.

* nix/libstore/local-store.hh: Rename makeStoreWritable to ensureStoreWritable.

Change-Id: I94783ba7e32d57bfa77e37e84b6ac316f95e31e2
Signed-off-by: Rutherther <rutherther@ditigal.xyz>
2025-12-22 11:00:17 +01:00
..
libstore daemon: Ensure store is writable even as non-root. 2025-12-22 11:00:17 +01:00
libutil daemon: Use inline functions and variables instead of extern 2025-11-12 18:34:06 +01:00
nix-daemon daemon: Use inline functions and variables instead of extern 2025-11-12 18:34:06 +01:00
.gitignore
AUTHORS
COPYING
local.mk daemon: Use inline functions and variables instead of extern 2025-11-12 18:34:06 +01:00