From 757c411eae1d75d2e9e4e003de1635716f65437d Mon Sep 17 00:00:00 2001 From: Mark Nipper Date: Tue, 16 Apr 2024 23:44:15 -0700 Subject: Workaround annoying TMPDIR handling --- hosts/common/core/nix.nix | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'hosts') diff --git a/hosts/common/core/nix.nix b/hosts/common/core/nix.nix index 587bac6..dfcbd5c 100644 --- a/hosts/common/core/nix.nix +++ b/hosts/common/core/nix.nix @@ -1,5 +1,14 @@ { inputs, lib, ... }: { + + # work around very annoying TMPDIR handling + # see: https://github.com/NixOS/nix/issues/7154 + boot.tmp.useTmpfs = true; + systemd.services."nix-daemon".environment.TMPDIR = "/nix/tmp"; + systemd.tmpfiles.rules = [ + "d /nix/tmp 770 root nixbld" + ]; + nix = { settings = { trusted-users = [ "root" "@wheel" ]; -- cgit v1.2.3