From 3d0237b89b4f18c2a01aaccb8b0077cac746e3a7 Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Sat, 16 Apr 2022 14:44:36 -0700 Subject: HOSTNAME:CONFIGURED: drop seemingly unnecessary DOMAIN argument Signed-off-by: Sean Whitton --- src/property/hostname.lisp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'src/property') diff --git a/src/property/hostname.lisp b/src/property/hostname.lisp index f4d4d8e..9bed5c3 100644 --- a/src/property/hostname.lisp +++ b/src/property/hostname.lisp @@ -32,12 +32,8 @@ Unlikely to be useful for hosts defined using DEFHOST." (defpropspec configured :posix (&optional (hostname (get-hostname) hostname-supplied-p) - (domain (domain hostname)) &aux (short (car (split-string hostname :separator ".")))) - "Set the hostname in the standard Debian way. -When HOSTNAME is an FQDN, DOMAIN is the domain part of the hostname, -defaulting to everything after the first dot. (For some hosts, the domain -should rather be the whole hostname.)" + "Set the hostname in the standard Debian way." (:desc "Hostname configured") `(seqprops ,@(and hostname-supplied-p `((is ,hostname))) @@ -46,7 +42,7 @@ should rather be the whole hostname.)" (cmd:single ,(strcat "hostname " short)))) (file:contains-conf-tab "/etc/hosts" - ,@(and (plusp (length domain)) + ,@(and (position #\. hostname) `("127.0.1.1" ,(strcat hostname " " short))) "127.0.0.1" "localhost"))) -- cgit v1.2.3