From c64a9718ce82c2579c1f707748e066bb9596d50b Mon Sep 17 00:00:00 2001 From: Erik Arvstedt Date: Mon, 26 Nov 2018 22:22:09 +0100 Subject: [PATCH] nixos/containers: simplify env var definition Also clear up the misleading comment: This env var isn't root-specific, it's needed for all users. --- nixos/modules/virtualisation/container-config.nix | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/nixos/modules/virtualisation/container-config.nix b/nixos/modules/virtualisation/container-config.nix index 561db7cabcfb..78c59d98a5eb 100644 --- a/nixos/modules/virtualisation/container-config.nix +++ b/nixos/modules/virtualisation/container-config.nix @@ -22,12 +22,8 @@ with lib; # Not supported in systemd-nspawn containers. security.audit.enable = false; - # Make sure that root user in container will talk to host nix-daemon - environment.etc."profile".text = '' - export NIX_REMOTE=daemon - ''; - - + # Use the host's nix-daemon. + environment.variables.NIX_REMOTE = "daemon"; };