help-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Examples of local-host-entries or hosts-service-type?


From: Remco van 't Veer
Subject: Re: Examples of local-host-entries or hosts-service-type?
Date: Mon, 27 Feb 2023 07:23:14 +0100
User-agent: mu4e 1.8.13; emacs 28.2

Hi Bruno,

Thanks for the clarification!

2023/02/21 16:45, Bruno Victal:

> You only override the hosts-service-type value when you don't want to
> have 'localhost' as an alias of your _hostname_ or you don't want to
> set '127.0.0.1' / '::1' as IPs for localhost / _hostname_.

Or when you want to provide extra aliases for localhost?

Like this?

  (essential-services
   (modify-services
       (operating-system-default-essential-services this-operating-system)
     (hosts-service-type config =>
                         (list (host "127.0.0.1" "localhost" (list host-name 
"foo" "bar"))
                               (host "::1"       "localhost" (list host-name 
"foo" "bar"))))))

Cheers,
Remco



reply via email to

[Prev in Thread] Current Thread [Next in Thread]