diff options
| author | Rutherther <rutherther@ditigal.xyz> | 2025-12-21 13:25:59 +0100 |
|---|---|---|
| committer | Rutherther <rutherther@ditigal.xyz> | 2025-12-22 11:00:17 +0100 |
| commit | 2a0ac4cba5e3816e203b412934ee66345667c5ca (patch) | |
| tree | 4c687744f286d99186663b52f828f0fd6e9d48bd /gnu.scm | |
| parent | 09eda1627e41bfdf966539c80a260bce6307e57c (diff) | |
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>
Diffstat (limited to 'gnu.scm')
0 files changed, 0 insertions, 0 deletions
