From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id yNt7DZNS6mNJQQEAbAwnHQ (envelope-from ) for ; Mon, 13 Feb 2023 16:09:07 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id mCMeDZNS6mNfBwAAauVa8A (envelope-from ) for ; Mon, 13 Feb 2023 16:09:07 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id CFA2633F7 for ; Mon, 13 Feb 2023 16:09:06 +0100 (CET) Authentication-Results: aspmx1.migadu.com; dkim=none; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1676300947; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=yGl6mZb8XuiiahIt2vzgtOsKW/jv7BvNO9728bCToow=; b=pCdMBfDPMX4JNAze+nfPPG/j3GHQqf7mwh01L4yAFE60mJBipp301FtMoGalzF8y26vinN 9ifC73lDcDnWtnyEUD0OePXXhJKI4rKJAGnz1+PEnUD/zbHtLopJCAfXlFCicI9qptD1e+ GIzTv8JdCzwVZs0wUwEa9CfhHWnS4+WdfhRcq9C6HUPE+xbgE0ntMzKYbiEWUAo8qrEc6T PE1LLxB2Nw192oQ8kjMguimRJlfDhDnkXKG+TH8iNaQm1RyT2kNRq+FslMSq/IubBz8/RJ /aBFLUEDBPuaoSM77w2Ms7haarzlNcFOrBYYKVpiWg+4cUxubSKtBgqYUsdbEg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Seal: i=1; s=key1; d=yhetil.org; t=1676300947; a=rsa-sha256; cv=none; b=I7u30aKD3+cwA1dImXxiRFwyeGRkynZFZJ8xOBDNQkiwn/EwB36mVd4hWgcMYTGjFyUi35 JDVpuXVwxdUn0/XrOqXcduVgkAootKt0ZKBMYo/Oxn0xWtEWeXcD3yqtdBewz2waP9byai aOLb6wFBVqXeHLKyYF29Gk4xRByOLuqXqCQMBvW3QHMXqGjiZiRDGPxFefm/iluUUnTorJ YFOE5KK7QTpTZpulcLowXJgM4liftuOgTsk6AqIpEhb6cfltxqLRMuyhIj2DJG/ZSrAEtY fdE98myhRg7899538hGrMkAUFjUsVGNJiR68ULQYpBipg265m2IbCX00J9HC0g== Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pRaRk-0007ge-KZ; Mon, 13 Feb 2023 10:08:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pRaRi-0007dA-PY for help-guix@gnu.org; Mon, 13 Feb 2023 10:08:46 -0500 Received: from marvid.fr ([163.172.81.107] helo=courriel.marvid.fr) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pRaRg-00021O-SC for help-guix@gnu.org; Mon, 13 Feb 2023 10:08:46 -0500 Received: from localhost (schwifty.marvid.fr [51.159.4.137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by sahkopoika (Postfix) with ESMTPSA id D95947E23708; Mon, 13 Feb 2023 16:08:05 +0100 (CET) References: <87k00pi15e.fsf@colimite.fr> <87r0uw4e78.fsf@remworks.net> User-agent: mu4e 1.8.13; emacs 28.2 From: Sergiu Ivanov To: Remco van 't Veer Cc: help-guix@gnu.org Subject: Re: Examples of local-host-entries or hosts-service-type? Date: Mon, 13 Feb 2023 11:49:17 +0100 In-reply-to: <87r0uw4e78.fsf@remworks.net> Message-ID: <87k00ltxgs.fsf@colimite.fr> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: none client-ip=163.172.81.107; envelope-from=sivanov@colimite.fr; helo=courriel.marvid.fr X-Spam_score_int: 7 X-Spam_score: 0.7 X-Spam_bar: / X-Spam_report: (0.7 / 5.0 requ) BAYES_00=-1.9, DATE_IN_PAST_03_06=1.592, FORGED_SPF_HELO=1, SPF_HELO_PASS=-0.001, SPF_NONE=0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: X-Migadu-Queue-Id: CFA2633F7 X-Spam-Score: -2.22 X-Migadu-Spam-Score: -2.22 X-Migadu-Scanner: scn0.migadu.com List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: help-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-TUID: +FCiE9v0Pa2G Hi Bruno, hi Remco, Thank you very much for your suggestions! Remco van 't Veer [2023-02-11T12:46:35+0100]: > 2023/02/10 23:40, Sergiu Ivanov: >> >> Could someone point me to an example of how I should update >> my configuration? > > In the guix manual I found this: > > https://guix.gnu.org/en/manual/devel/en/html_node/Service-Reference.html#index-hosts_002dservice_002dtype > > So instead of using (hosts-file ..) you'll have to use > (hosts-service-type ..) instead, as you already mentioned. You'll end > up with something like to following: > > (operating-system > ;; ... > > (essential-services > (modify-services > (operating-system-default-essential-services this-operating-system) > (hosts-service-type config => > (cons* (host "some.ip.address.1" "machine1") > (host "some.other.ip.address" "machine2") > (local-host-entries host-name))))) > > ;; ... Oh, thank you very much for the specific solution! It worked for me flawlessly. Actually, where did you get local-host-entries from? The documentation page you and Bruno cite doesn't seem to ever mention this function :O Unless I am looking at some old version of the docs. > Also, I agree the documentation needs some love here. I am willing to contribute. What would be the best place to do changes to the documentation? I would follow this mini-roadmap: 1. Add the explanation of local-host-entries to https://guix.gnu.org/en/manual/devel/en/html_node/Service-Reference.html#index-hosts_002dservice_002dtype 2. Say here https://guix.gnu.org/manual/en/html_node/operating_002dsystem-Reference.html that hosts-file is deprecated. 3. Update the examples here to use hosts-service-type instead of hosts-file: https://guix.gnu.org/manual/en/guix.html What do you think? I've never submitted a patch to Guix docs before, so all suggestions and hints are welcome :-) - Sergiu