From owner-freebsd-questions@FreeBSD.ORG Sun Feb 26 22:38:00 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BFF6E16A420 for ; Sun, 26 Feb 2006 22:38:00 +0000 (GMT) (envelope-from scott@fishballoon.org) Received: from mta07-winn.ispmail.ntl.com (mta07-winn.ispmail.ntl.com [81.103.221.47]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3DDA243D68 for ; Sun, 26 Feb 2006 22:37:55 +0000 (GMT) (envelope-from scott@fishballoon.org) Received: from aamta12-winn.ispmail.ntl.com ([81.103.221.35]) by mta07-winn.ispmail.ntl.com with ESMTP id <20060226223754.TPUT15056.mta07-winn.ispmail.ntl.com@aamta12-winn.ispmail.ntl.com> for ; Sun, 26 Feb 2006 22:37:54 +0000 Received: from llama.fishballoon.org ([81.104.195.171]) by aamta12-winn.ispmail.ntl.com with ESMTP id <20060226223753.JVWO1804.aamta12-winn.ispmail.ntl.com@llama.fishballoon.org> for ; Sun, 26 Feb 2006 22:37:53 +0000 Received: from tuatara.fishballoon.org ([192.168.1.6]) by llama.fishballoon.org with esmtp (Exim 4.60 (FreeBSD)) (envelope-from ) id 1FDUWV-0006m3-NH for freebsd-questions@freebsd.org; Sun, 26 Feb 2006 22:37:51 +0000 Received: (from scott@localhost) by tuatara.fishballoon.org (8.13.4/8.13.4/Submit) id k1QMbpbv002408 for freebsd-questions@freebsd.org; Sun, 26 Feb 2006 22:37:51 GMT (envelope-from scott) Date: Sun, 26 Feb 2006 22:37:51 +0000 From: Scott Mitchell To: freebsd-questions@freebsd.org Message-ID: <20060226223751.GA1053@tuatara.fishballoon.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.1i X-Operating-System: FreeBSD 5.4-STABLE i386 Subject: portupgrade -s and NFS /usr/ports? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 26 Feb 2006 22:38:00 -0000 Hi all, Just wondering if anyone else out there has a similar setup to this and can offer any hints on improving it: - NFS-exported /usr/ports, permissions set so it's writable by anyone in the 'ports' group. - Mount this on various client machines where portupgrade will be run to build ports and generate packages. The pkgtools.conf file is set up so that packages will be written to /usr/ports/packages-, e.g. packages-5-stable. - I was hoping to be able to avoid root access to /usr/ports by using the -s flag to portupgrade, but portupgrade seems to want to be root whenever it invokes a make command on a port. I can move the actual build onto a local filesystem by setting WRKDIRPREFIX - I did this anyway for performance reasons. However, I want downloaded distfiles and built packages to go in /usr/ports where other machines can see them, but there doesn't seem to be a way to prevent portupgrade from fetching distfiles or building packages as root in every situation. The best workaround I've come up with is to maproot=some_user on the NFS export, where some_user is a member of the 'ports' group. This _almost_ works, except when trying to overwrite a package that is owned by someone else (the ports framework doesn't move/delete the old package first - but a wrapper script around pkg_create fixes that) or if I run portupgrade on the NFS server and end up with files owned by root that need to be fixed up manually afterwards. I could use maproot=root, but /usr/ports shares a filesystem with a bunch of other stuff, and I'd rather not have the whole lot be remotely root-writable. Is anyone else running a setup like this and found a better workaround for these problems? Thanks, Scott -- =========================================================================== Scott Mitchell | PGP Key ID | "Eagles may soar, but weasels Cambridge, England | 0x54B171B9 | don't get sucked into jet engines" scott at fishballoon.org | 0xAA775B8B | -- Anon