From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id uITFAh5O5l4WMwAA0tVLHw (envelope-from ) for ; Sun, 14 Jun 2020 16:19:42 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id AF41Oh1O5l5jTQAAB5/wlQ (envelope-from ) for ; Sun, 14 Jun 2020 16:19:41 +0000 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 A59A99400B1 for ; Sun, 14 Jun 2020 16:19:41 +0000 (UTC) Received: from localhost ([::1]:37300 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jkVMC-0002e0-M9 for larch@yhetil.org; Sun, 14 Jun 2020 12:19:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40176) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jkVLj-0002TP-Jz for help-guix@gnu.org; Sun, 14 Jun 2020 12:19:11 -0400 Received: from mail-io1-xd2a.google.com ([2607:f8b0:4864:20::d2a]:39817) by eggs.gnu.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jkVLe-0004Nn-0M for help-guix@gnu.org; Sun, 14 Jun 2020 12:19:11 -0400 Received: by mail-io1-xd2a.google.com with SMTP id c8so15288923iob.6 for ; Sun, 14 Jun 2020 09:19:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=references:user-agent:from:to:subject:in-reply-to:date:message-id :mime-version; bh=vWs4hESheQFagNH+bX+R7m64WeDMJoHfYxBIfr2gpRo=; b=ddvFg95UqxH0wiRIUBe7SI1M6hfaaMdVBHGaIZvSAY77/ynFgWM2hXGacV58+97KWv zVpVCDRVP5FUP8nTDV6+wcq5JfWAP6BRUtXo1ee7qmNgKpw1PWyr/wZnPTBK29yE55tq DEs9AlQ5eWXO7O/u0hgLVDtuwVQY+WUHJ/0EJe026Nus1AgTYdPSPvGiaGeZHSep5USq ZdH+OwPon8yc0S2fZNotyE68NAQQZpaoyFGFW7iSoCUeYg+6Tz69qFncKegrHM1n6TVz vuZwfpNkqEUy4+/ljuhzp+RtW4S7kXwgnjH9oFfzAV8ZSL+h1enQaSnLx01ZprCnWHGZ i1oA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:references:user-agent:from:to:subject :in-reply-to:date:message-id:mime-version; bh=vWs4hESheQFagNH+bX+R7m64WeDMJoHfYxBIfr2gpRo=; b=iHNaaxhlFgbzWRNREIM3eAOlNB6AFzKaA88HmgoEaFFT8z6tHi8+A+rMNns3hHEsyG VkH3RcrpwYLludgWxEolTNUWgrfqS9rchKAjCd+J9qGVvHeqPxZaq7Hk56Alqjfl4QF0 31lqEVqPDNcjaZZaAx+mSLWqTgD3hE+lPPM+ZsPR8dsIhfCfLNJ5rYkmFHUsVo6mWL/A Z1Y3nlE/dDk2s7KlWoj2tVlZSRZbdhzicwBtL85jDwpQ2q/RDopW9FR2cIXHx+fjGzkL aadPPcc6zwOumbXgMM5qeKoNj7Bd/lnxfrLS2rk/74lnC7Oh9aVDn4Ra/C/oSmbFnwqV 3r+w== X-Gm-Message-State: AOAM530WuYpUXbsgmPBTjs168C+XsQWGlwoc7RQaIOXc2/GIkNfzScOk I7RoON+E9DCOw2IuwZ+jeNfErYCy X-Google-Smtp-Source: ABdhPJwaGqyy0ZKbhJtWB4bV0jbaeL8VAkE2AQGTSGwkoKcPN261WX1XEdqr0e/oZRmEqvMTAbrItA== X-Received: by 2002:a02:c848:: with SMTP id r8mr16943434jao.15.1592151539221; Sun, 14 Jun 2020 09:18:59 -0700 (PDT) Received: from x1 ([2600:6c48:6d80:c6::4cc]) by smtp.gmail.com with ESMTPSA id t14sm6358112ilp.73.2020.06.14.09.18.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 14 Jun 2020 09:18:58 -0700 (PDT) References: <87d062et82.fsf@gmail.com> User-agent: mu4e 1.4.6; emacs 26.3 From: Kyle Andrews To: help-guix Subject: Re: How configure my desktop to use a static ip address? In-reply-to: <87d062et82.fsf@gmail.com> Date: Sun, 14 Jun 2020 12:18:58 -0400 Message-ID: <878sgpei31.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::d2a; envelope-from=kyle.c.andrews@gmail.com; helo=mail-io1-xd2a.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: "Help-Guix" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b=ddvFg95U; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of help-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=help-guix-bounces@gnu.org X-Spam-Score: -0.71 X-TUID: XkChwgkoTD85 Thanks to generous help from several people in the #guix IRC channel, I learned that the trick I was missing was that I could actually use Network Manager to setup a static IP once the router has been configured to reserve it. This generates a ~*.nmconnection~ configuration file into: : /etc/NetworkManager/system-connections Then a simple-service etc-service can be added to the services list in ~/etc/config.scm~ to make that reproducible. I still need to figure out exactly how to do that, but I have some leads. guix-vits suggested that to simplify the generation of the configuration file in /etc, I could store the file alongside ~/etc/config.scm~ and reference it using some code like: (define (cat-file path) (use-modules (ice-9 textual-ports)) (with-input-from-file path (lambda _ (get-string-all (current-input-port))))) (define %nm-static-connection (cat-file "/etc/nm-static-profile.nmconnection")) (operating-system ... (services (cons* (simple-service 'nm-static-connection etc-service-type `(("NetworkManager/system-connections/nm-static-profile.nmconnection" ,%nm-static-connection)))) ...)) I haven't tested it quite yet, but it makes some sense to me. If you think this is not exactly the right approach, please let me know. Kyle Andrews writes: > Dear Guix, > > I would like to setup my desktop computer so that I can easily > synchronize it with my laptop via ssh and sshfs. Ideally, I would like > to be able to do this from anywhere in the world behind > e.g. AirVPN. However, honestly I know next to nothing about > networking. So, I'm looking for guidance on how I can get there from > here. Hopefully, you can help me and others who are looking to setup > something similar. > > I've managed to setup the openssh-service which allows me to connect via > SSH to my desktop on my local network if I go over to it and type ~ip > address~ to learn the current IP address assigned to it. However, > frequently I run into this scary message when trying to connect: > > @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ > @ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @ > @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ > IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY! > > While I have gotten into the routine of editing ~/.ssh/known_hosts and > deleting the previous entry, I would like to resolve the issue for > good. From my reading I think the best way to do that would be to set up > a static IP for my desktop. I think to do that I need to . Do I need to modify my /etc/config.scm to use > static-networking-service? If so, how? Do I also need to modify my > router configuration?