diff options
-rw-r--r-- | nixos/modules/system/etc/etc.nix | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/nixos/modules/system/etc/etc.nix b/nixos/modules/system/etc/etc.nix index 300ae0acda534..9d5b3db472c3d 100644 --- a/nixos/modules/system/etc/etc.nix +++ b/nixos/modules/system/etc/etc.nix @@ -112,8 +112,9 @@ in config = { target = mkDefault name; - source = mkIf (config.text != null) - (mkDefault (pkgs.writeText "etc-file" config.text)); + source = mkIf (config.text != null) ( + let name' = "etc-" + baseNameOf name; + in mkDefault (pkgs.writeText name' config.text)); }; }); |