From owner-freebsd-ports@freebsd.org Tue Apr 27 07:24:26 2021 Return-Path: Delivered-To: freebsd-ports@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 479D5623734 for ; Tue, 27 Apr 2021 07:24:26 +0000 (UTC) (envelope-from 6yearold@gmail.com) Received: from mail-lf1-f54.google.com (mail-lf1-f54.google.com [209.85.167.54]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FTtYj4088z3McF for ; Tue, 27 Apr 2021 07:24:25 +0000 (UTC) (envelope-from 6yearold@gmail.com) Received: by mail-lf1-f54.google.com with SMTP id x19so61818504lfa.2 for ; Tue, 27 Apr 2021 00:24:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=PZELrFsBMFXIgsRBrCkQAjAScHMK/F4d0tEMrHHE0ts=; b=Oz6TgnL+J10zVCWippxasVXj1i62l2rftdsdiMYRviwan+AKtYPXrslWxJSJ2U43c6 NURPiAQULM+eOBzpCDocVJDlMsIpUDSa7A0j5VsSg9QP5xf7ySvARWe7oJ2D9cfevH2/ ScZrPsH0H1y4y20jj8/8Vpqa/a2Wq3ZgeLlT57yEHLdb4JJi5Xs7rt7kDT316YGSyelK 1BH5geMqrI2FWQMvXETDboA5StxyPupcMlbQL6aAybxWZ/CKptMEnJnPfKZL3eBld1Sg d/I7qat67T3Ph37d/EcbFojnp6OOQz+BK5C/21bX6i8/5FwA29S8c4168ebsV8C55Dvb gphg== X-Gm-Message-State: AOAM531oX6pQ9NVD1C1QuFCEXiQHaBR8m66kFF4aN5SawGJMz6yKsjp7 JD7Y3Z/bEiBeZf1D6yTTPOMc8gvMzw0Lbg== X-Google-Smtp-Source: ABdhPJxmS6Wfrzr2gTjUuAHu4yxCSvtwl8UYXLhZxPAKYMPnqkKVNypmYK7r3qrp7sfxAhJ7/G9eAQ== X-Received: by 2002:a05:6512:150:: with SMTP id m16mr16594614lfo.374.1619508263770; Tue, 27 Apr 2021 00:24:23 -0700 (PDT) Received: from mail-lj1-f176.google.com (mail-lj1-f176.google.com. [209.85.208.176]) by smtp.gmail.com with ESMTPSA id o16sm1641120lfu.228.2021.04.27.00.24.23 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 27 Apr 2021 00:24:23 -0700 (PDT) Received: by mail-lj1-f176.google.com with SMTP id b38so25910901ljf.5 for ; Tue, 27 Apr 2021 00:24:23 -0700 (PDT) X-Received: by 2002:a05:651c:205:: with SMTP id y5mr15595854ljn.301.1619508263471; Tue, 27 Apr 2021 00:24:23 -0700 (PDT) MIME-Version: 1.0 References: <5A7F1B5C-4382-450C-9674-C9F4866E632E@lassitu.de> In-Reply-To: From: Gleb Popov Date: Tue, 27 Apr 2021 10:23:58 +0300 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: Changing daemon user, dir ownership and updating packages To: Dewayne Geraghty Cc: FreeBSD Ports X-Rspamd-Queue-Id: 4FTtYj4088z3McF X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of 6yearold@gmail.com designates 209.85.167.54 as permitted sender) smtp.mailfrom=6yearold@gmail.com X-Spamd-Result: default: False [-3.00 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:209.85.128.0/17]; RCVD_COUNT_THREE(0.00)[4]; TO_DN_ALL(0.00)[]; NEURAL_HAM_SHORT(-1.00)[-1.000]; RCPT_COUNT_TWO(0.00)[2]; FORGED_SENDER(0.30)[arrowd@freebsd.org,6yearold@gmail.com]; MIME_TRACE(0.00)[0:+,1:+,2:~]; RBL_DBL_DONT_QUERY_IPS(0.00)[209.85.167.54:from]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:209.85.128.0/17, country:US]; FROM_NEQ_ENVFROM(0.00)[arrowd@freebsd.org,6yearold@gmail.com]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; R_DKIM_NA(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-ports@freebsd.org]; DMARC_NA(0.00)[freebsd.org]; SPAMHAUS_ZRD(0.00)[209.85.167.54:from:127.0.2.255]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[209.85.167.54:from]; RWL_MAILSPIKE_POSSIBLE(0.00)[209.85.167.54:from]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-ports] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.34 X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Apr 2021 07:24:26 -0000 On Mon, Apr 26, 2021 at 10:13 PM Dewayne Geraghty < dewayne@heuristicsystems.com.au> wrote: > On 26/04/2021 6:03 pm, Stefan Bethke wrote: > > But that still leaves pkg updating the ownership/mode of existing > directories as a surprise on updating a package. I think the "right" thing > here would be a kind of three-way merge between changes an updated package > brings in vs. changes the user has made on their system. > > Sometimes the right thing isn't easy ;) > > There are some cases where I explicitly assign ownership and more > restrictive modes to installed ports. Would "pkg add -I" prevent file > ownership/mode changes or just prevent the execution of installation > scripts... (hint for a flag to prevent file mode/ownership changes on > existing systems) > > I suspect Gleb's paradigm of a separate file to explicitly control file > attributes (after upgrades) is reasonable, but this is problematic and > negates the value of a packaging system. > It only shifts the task of organizing runtime files/dirs to the software upstream, which is a right thing, IMO. The same way we use automatic pkg-plist generation for Python easyinstall-based ports. That tmpfiles.d thing seems to be an established way to do that sort of stuff in the Linux world, so I believe we should get on the train too.