From d1d6403cb5023490ac629ef7a3f65796f6b2e789 Mon Sep 17 00:00:00 2001
From: Masanori Ogino <167209+omasanori@users.noreply.github.com>
Date: Thu, 5 Nov 2020 16:03:09 +0900
Subject: [PATCH] nixos/networking: make /etc/netgroup by default
This will prevent nscd from complaining /etc/netgroup being absent.
Signed-off-by: Masanori Ogino <167209+omasanori@users.noreply.github.com>
---
nixos/doc/manual/release-notes/rl-2103.xml | 6 ++++++
nixos/modules/config/networking.nix | 4 ++++
2 files changed, 10 insertions(+)
diff --git a/nixos/doc/manual/release-notes/rl-2103.xml b/nixos/doc/manual/release-notes/rl-2103.xml
index 9070957aee4a..d08f81eaf701 100644
--- a/nixos/doc/manual/release-notes/rl-2103.xml
+++ b/nixos/doc/manual/release-notes/rl-2103.xml
@@ -509,6 +509,12 @@ http://some.json-exporter.host:7979/probe?target=https://example.com/some/json/e
The GNOME desktop manager once again installs gnome3.epiphany by default.
+
+
+ NixOS now generates empty /etc/netgroup.
+ /etc/netgroup defines network-wide groups and may affect to setups using NIS.
+
+
diff --git a/nixos/modules/config/networking.nix b/nixos/modules/config/networking.nix
index 4cb7d81c9972..c09588834cf1 100644
--- a/nixos/modules/config/networking.nix
+++ b/nixos/modules/config/networking.nix
@@ -193,6 +193,10 @@ in
cat ${escapeShellArgs cfg.hostFiles} > $out
'';
+ # /etc/netgroup: Network-wide groups.
+ netgroup.text = mkDefault ''
+ '';
+
# /etc/host.conf: resolver configuration file
"host.conf".text = ''
multi on