From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id oJrlEcyJVGGRxgAAgWs5BA (envelope-from ) for ; Wed, 29 Sep 2021 17:44:12 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id oHyFDcyJVGH8aQAA1q6Kng (envelope-from ) for ; Wed, 29 Sep 2021 15:44:12 +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 583A22DE42 for ; Wed, 29 Sep 2021 17:44:11 +0200 (CEST) Received: from localhost ([::1]:54468 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mVbkg-0007gs-Bp for larch@yhetil.org; Wed, 29 Sep 2021 11:44:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52576) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mVbkY-0007fe-Oh for guix-patches@gnu.org; Wed, 29 Sep 2021 11:44:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:38374) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mVbkY-0007kg-HH for guix-patches@gnu.org; Wed, 29 Sep 2021 11:44:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mVbkY-00029J-BL for guix-patches@gnu.org; Wed, 29 Sep 2021 11:44:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50892] [PATCH] guix-install.sh: Authorize all project build farms at once. Resent-From: Tobias Geerinckx-Rice Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 29 Sep 2021 15:44:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 50892 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 50892@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.16329302108208 (code B ref -1); Wed, 29 Sep 2021 15:44:02 +0000 Received: (at submit) by debbugs.gnu.org; 29 Sep 2021 15:43:30 +0000 Received: from localhost ([127.0.0.1]:49920 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mVbjt-00028D-Ne for submit@debbugs.gnu.org; Wed, 29 Sep 2021 11:43:30 -0400 Received: from lists.gnu.org ([209.51.188.17]:56874) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mVbjo-000281-J1 for submit@debbugs.gnu.org; Wed, 29 Sep 2021 11:43:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52284) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mVbjo-0006zm-56 for guix-patches@gnu.org; Wed, 29 Sep 2021 11:43:16 -0400 Received: from tobias.gr ([2a02:c205:2020:6054::1]:60028) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mVbji-00070u-5b for guix-patches@gnu.org; Wed, 29 Sep 2021 11:43:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; s=2018; bh=tnvk0zCzDBqQi gdHuSm/qfcGsYMWaiTeAv2OyGzYgiY=; h=date:subject:to:from; d=tobias.gr; b=p0d6clnhATo91IldyaQRr5ekFExqYC6xx69HZBLbLyKjJ7b6+t6jVBtlyiPAvm+zkyYL Wt+ubW/9akRgd3d5B8swT/mwDtrsLNPTfR3XAN01+mygftGrobgiX4VV4mPozjuGpMIc0D UEdgir5qBz9iaJasfuwRBbkDFLTtWJ6PfSSVkfYhnD7u5y4yYyfzUrK8CMUG2LxupXfGWn OJWvztiYrmiikWxtutP7dcgHU74KerZMLfeYA/4orBvZ168fmWgEXzUupEfMw31hK00s6a 22welshZmBOK52LxlzHMAWrFH+mjWFvAVFiOFywcfjRxU/mt/HZcxHNJd2DHOCYw== Received: by submission.tobias.gr (OpenSMTPD) with ESMTPSA id 6a8a506d (TLSv1.3:AEAD-AES256-GCM-SHA384:256:NO) for ; Wed, 29 Sep 2021 15:43:04 +0000 (UTC) Date: Wed, 29 Sep 2021 17:43:10 +0200 Message-Id: <20210929154310.25788-1-me@tobias.gr> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2a02:c205:2020:6054::1; envelope-from=me@tobias.gr; helo=tobias.gr 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, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" Reply-to: Tobias Geerinckx-Rice X-ACL-Warn: , Tobias Geerinckx-Rice via Guix-patches From: Tobias Geerinckx-Rice via Guix-patches via X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1632930251; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=tnvk0zCzDBqQigdHuSm/qfcGsYMWaiTeAv2OyGzYgiY=; b=Uy5lI5UgcXAFvFA8Pa/gBxvx9mD1UC6LPrlGsoo3WtrFI2RN0g1GFTwMMF9fh0dbT8meFt N11N9guLSp033w6ajij9G0RiacGb8c653dOqL3rh75IHV3n4/EZwhpSXQfjEh1DEBvvgDG R9p4gkSnzPM5acky+3fW5V+DtpwX5MzlzQy9Cfl1HptXMkuJ2xvb/UARM/XnGSIkA951HH d0jRhXWAMrAlqjJPsVPq/0jI/1pn0hfwl146ZHp7ODcDz9GKbqOPT9+NRKkUJDGYSOKxBX RAccL+8FCWx4gfpTNb8P+G4HQc2c1WlQfp/7d5tMS3kp69zfk1/fFnkcqGdQKg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1632930251; a=rsa-sha256; cv=none; b=HtTVybHOPBZ4S15KSP6PXkVEAoRASBpmnmQVej8VyA6MfpBwhZdAkXny7n3kDz4s98lOo8 owGt3yzV+pZbayy7MqrOeWEDF3DRjof55az0j4/gwVx2Bq0n6n90YuOD5WP3bToH79h24y VJt08ZvYeklCMk7ousfPbpwNcQhWeF6VMWvM1J2jWMaJnMzvRyGxE/kMThJS1wgBDO27ot uJj2Xk9oxpY5TuTbskIZrp2dAq6M5yghkBFGUoJqE0fSvP98mnA98dnT5UJETu944to423 MrPJozIBwCRKJMkDJoh3/abP56tSg7duDR7E8JgeK4mtbLaThKUwKYwY3ovwSA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=tobias.gr header.s=2018 header.b=p0d6clnh; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -2.90 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=tobias.gr header.s=2018 header.b=p0d6clnh; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 583A22DE42 X-Spam-Score: -2.90 X-Migadu-Scanner: scn0.migadu.com X-TUID: 1KMVoVGtszbi * etc/guix-install.sh (sys_authorize_build_farms): Iterate over all hosts. --- etc/guix-install.sh | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/etc/guix-install.sh b/etc/guix-install.sh index b0d4a8b95e..e3b8485a50 100755 --- a/etc/guix-install.sh +++ b/etc/guix-install.sh @@ -1,21 +1,21 @@ #!/bin/sh # GNU Guix --- Functional package management for GNU # Copyright © 2017 sharlatan # Copyright © 2018 Ricardo Wurmus # Copyright © 2018 Efraim Flashner -# Copyright © 2019, 2020 Tobias Geerinckx-Rice +# Copyright © 2019–2021 Tobias Geerinckx-Rice # Copyright © 2020 Morgan Smith # Copyright © 2020 Simon Tournier # Copyright © 2020 Daniel Brooks # Copyright © 2021 Jakub Kądziołka # Copyright © 2021 Chris Marusich # Copyright © 2021 Maxim Cournoyer # # This file is part of GNU Guix. # # GNU Guix is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or (at # your option) any later version. # # GNU Guix is distributed in the hope that it will be useful, but @@ -476,38 +476,45 @@ sys_enable_guix_daemon() ;; esac _msg "${INF}making the guix command available to other users" [ -e "$local_bin" ] || mkdir -p "$local_bin" ln -sf "${var_guix}/bin/guix" "$local_bin" [ -e "$info_path" ] || mkdir -p "$info_path" for i in "${var_guix}"/share/info/*; do ln -sf "$i" "$info_path" done } sys_authorize_build_farms() -{ # authorize the public key of the build farm +{ # authorize the public key(s) of the build farm(s) + local hosts=( + ci.guix.gnu.org + bordeaux.guix.gnu.org + ) + if prompt_yes_no "Permit downloading pre-built package binaries from the \ -project's build farm? (yes/no)"; then - guix archive --authorize \ - < "~root/.config/guix/current/share/guix/ci.guix.gnu.org.pub" \ - && _msg "${PAS}Authorized public key for ci.guix.gnu.org" - else - _msg "${INF}Skipped authorizing build farm public keys" +project's build farms? (yes/no)"; then + for host in "${hosts[@]}"; do + guix archive --authorize \ + < "~root/.config/guix/current/share/guix/$host.pub" \ + && _msg "${PAS}Authorized public key for $host" + done + else + _msg "${INF}Skipped authorizing build farm public keys" fi } sys_create_init_profile() { # Define for better desktop integration # This will not take effect until the next shell or desktop session! [ -d "/etc/profile.d" ] || mkdir /etc/profile.d # Just in case cat <<"EOF" > /etc/profile.d/guix.sh # _GUIX_PROFILE: `guix pull` profile _GUIX_PROFILE="$HOME/.config/guix/current" export PATH="$_GUIX_PROFILE/bin${PATH:+:}$PATH" # Export INFOPATH so that the updated info pages can be found # and read by both /usr/bin/info and/or $GUIX_PROFILE/bin/info # When INFOPATH is unset, add a trailing colon so that Emacs # searches 'Info-default-directory-list'. -- 2.33.0