From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:203:b4db::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id cL2zI2A0ymFVPgAAgWs5BA (envelope-from ) for ; Mon, 27 Dec 2021 22:47:12 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id 0IH2IGA0ymFaHQEA9RJhRA (envelope-from ) for ; Mon, 27 Dec 2021 22:47:12 +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 5A019EC60 for ; Mon, 27 Dec 2021 22:47:12 +0100 (CET) Received: from localhost ([::1]:37858 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n1xpn-0005dG-4R for larch@yhetil.org; Mon, 27 Dec 2021 16:47:11 -0500 Received: from eggs.gnu.org ([209.51.188.92]:56586) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n1xpe-0005cs-A9 for guix-patches@gnu.org; Mon, 27 Dec 2021 16:47:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:32928) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n1xpe-0006F7-1H for guix-patches@gnu.org; Mon, 27 Dec 2021 16:47:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1n1xpd-0006EJ-Q2 for guix-patches@gnu.org; Mon, 27 Dec 2021 16:47:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#52805] [PATCH] substitute: Add a =?UTF-8?Q?=E2=80=98--clear-cache=E2=80=99?= option. Resent-From: Tobias Geerinckx-Rice Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 27 Dec 2021 21:47:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 52805 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Mathieu Othacehe Cc: 52805@debbugs.gnu.org Received: via spool by 52805-submit@debbugs.gnu.org id=B52805.164064161223931 (code B ref 52805); Mon, 27 Dec 2021 21:47:01 +0000 Received: (at 52805) by debbugs.gnu.org; 27 Dec 2021 21:46:52 +0000 Received: from localhost ([127.0.0.1]:44474 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n1xpU-0006Dv-9s for submit@debbugs.gnu.org; Mon, 27 Dec 2021 16:46:52 -0500 Received: from tobias.gr ([80.241.217.52]:58716) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n1xpR-0006Di-PK for 52805@debbugs.gnu.org; Mon, 27 Dec 2021 16:46:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; s=2018; bh=8d0Ig9TgmPEcL lD0z4HsqwMtUQq3FlXlRPfiEHMHpzI=; h=in-reply-to:date:subject:cc:to: from:references; d=tobias.gr; b=UNgMS20RLGLqgthK5zzLYvQcEDLnbU+3Fst5Hi PEH2EQxyd6wKWUuxXZVel0X5+2MPLp+yyQeoD9KgkKm8fo72arjRW3GVvVjFD5jO3umQuh URMfEmdMu5Rdp3wCDJi8gOLRZRKGoc7evwhU3P7/O98CAvww3dLf4+9fyWDLpfv8hZFzWd /ShUuAKsnoQCT66wVMt4XhPvC28Z7oSMhZfGQycU42x7tKl4whEuE2/DubE59KnDvw96NL 1NYsAcGWNBHD//MXEhnToBkZw+55WQtsCMKf3GDpRjiaZo4S+RFzb6MH6FXRN/ptGHCvtY y93XtZT6EgGFKMRskF/dwVlw== Received: by submission.tobias.gr (OpenSMTPD) with ESMTPSA id 05c8f466 (TLSv1.3:AEAD-AES256-GCM-SHA384:256:NO); Mon, 27 Dec 2021 21:46:46 +0000 (UTC) References: <20211226162126.23749-1-me@tobias.gr> <87ee5x7nwj.fsf@gnu.org> Date: Mon, 27 Dec 2021 22:20:16 +0100 In-reply-to: <87ee5x7nwj.fsf@gnu.org> BIMI-Selector: v=BIMI1; s=default; Message-ID: <87pmphhg8q.fsf@nckx> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" 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 X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1640641632; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=8d0Ig9TgmPEcLlD0z4HsqwMtUQq3FlXlRPfiEHMHpzI=; b=rDnsdnTen8Rut3v7iw521XCH0aqTBYDZyCsy5jUjh2Hq81XxwXVmUmclP+tc5jVPCFW40e THtTs+XrjNjqVardM4NQoIs9lUcaDlwfxndoy93y0TMcuxuIhyQ6LSl1GxOgeampBChvZC pDJXccZWu6doNimSAtoh+23Bp5w+6T05qaK3JvLcfbicBQMLcOd7aAtuwfHaRw948femKT IFJy3W/D3ZFMC+LjpDqVpD/Hj+TwgI0vsSSWPksxCs8nFvgcc+evWe4ym7qbQShwiKCHMd UosYSPA90+4e5JFilxn8ASK8eGXY/TVNvM5pLXf0H7/1TOJJSYPhADS3RlmTDw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1640641632; a=rsa-sha256; cv=none; b=YK3JH5Sgw+PRAp5t6MsY1z22bn7KKbdZAPB1ydXXRKaqSeg8bLqAdVf/1mM92j3sL8M/T7 2itMIRxmWG1imLbEnvwdCC0oImXGA0xhCPOisIcc9k3dvmkMGOuBsTcoB3c7pwqbVxSYBE dkaIX/UIyjUPAXeWA6D1ioWg/ZeAYXEOloxoP4FEMXpAq8AIcuu8Q5X/GKObEr80WoaLA5 lB0Pq8d2F8nKJxOXZ/Q2ajYnH915ZKlVSREcp2wgT+EvUgnWl7fCPc5KaVoZhbaK8jSDI+ kCyJy5l4SiZEytcwvJSo9sfDFyNCrR/pLVXw//rRqMK0ZMunE5QjiHxiYHJM8g== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=tobias.gr header.s=2018 header.b=UNgMS20R; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -5.17 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=tobias.gr header.s=2018 header.b=UNgMS20R; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 5A019EC60 X-Spam-Score: -5.17 X-Migadu-Scanner: scn1.migadu.com X-TUID: 0mg8ZALY4u+2 --=-=-= Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Hi Mathieu, Thanks for the review! Mathieu Othacehe =E5=86=99=E9=81=93=EF=BC=9A > This script is invoked by the daemon as root. In that context, > %narinfo-cache-directory is "/var/guix/substitute/cache",=20 > whereas when > run as an user it is likely: "~/.cache/guix/substitute". Correct. > That would mean that users need to run "sudo guix substitute > --clear-cache". If they want to clear /var instead of ~/.cache, sure. That sounds like a sane interface, if clearing =E2=80=98root=E2=80=99's cac= he were=20 the intention? How would you even do that without sudo,=20 privilege-wise? > Moreover this script is an internal undocumented tool, > so I'm not in favor of adding user commands to it. OK. The point was to have a little command I could ask other users to=20 run, that's guaranteed to clear the correct directory, and doesn't=20 involve a spooky rm (which saves some back-and-forth :-). > Maybe "guix gc" would be a better place? No, I'd rather not add yet another option to =E2=80=98guix gc=E2=80=99 that= has=20 nothing to do with GC. Kind regards, T G-R --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iIMEARYKACsWIQT12iAyS4c9C3o4dnINsP+IT1VteQUCYco0hQ0cbWVAdG9iaWFz LmdyAAoJEA2w/4hPVW15d+4BAPkuQWWC+qZ1C/dkdaYx/U1PC85Yn8QdGWLVDgED STCNAQClkSgUbCbBmujSQMiP17E0ovE+2PBVu7VDCLaNfj0DAQ== =rAZY -----END PGP SIGNATURE----- --=-=-=--