about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRobert Hensing <robert@roberthensing.nl>2022-10-15 11:56:42 +0200
committerRobert Hensing <robert@roberthensing.nl>2022-10-15 11:57:58 +0200
commit18e3f431e1b36d4f569ddddd415f95921e1b7748 (patch)
tree62d6cb52e818fdc95c28b2b46ab36200b00873b0
parent1ab9d1beb1668e4cd3da2bfdd52851de0972a781 (diff)
networking.fqdnOrHostName: Elaborate and format the descriptions
-rw-r--r--nixos/modules/tasks/network-interfaces.nix8
1 files changed, 6 insertions, 2 deletions
diff --git a/nixos/modules/tasks/network-interfaces.nix b/nixos/modules/tasks/network-interfaces.nix
index c21675285f64c..9d55dc8bab831 100644
--- a/nixos/modules/tasks/network-interfaces.nix
+++ b/nixos/modules/tasks/network-interfaces.nix
@@ -473,9 +473,12 @@ in
       defaultText = literalExpression ''"''${networking.hostName}.''${networking.domain}"'';
       description = lib.mdDoc ''
         The fully qualified domain name (FQDN) of this host. It is the result
-        of combining networking.hostName and networking.domain. Using this
+        of combining `networking.hostName` and `networking.domain.` Using this
         option will result in an evaluation error if the hostname is empty or
         no domain is specified.
+
+        Modules that accept a mere `networing.hostName` but prefer a fully qualified
+        domain name may use `networking.fqdnOrHostName` instead.
       '';
     };
 
@@ -491,7 +494,8 @@ in
         it does not exists.
 
         This is a convenience option for modules to read instead of `fqdn` when
-        a mere `hostName` is also an acceptable value.
+        a mere `hostName` is also an acceptable value; this option does not
+        throw an error when `domain` is unset.
       '';
     };