From owner-freebsd-questions@FreeBSD.ORG Wed Oct 1 06:20:50 2003 Return-Path: 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 F01F416A4C0 for ; Wed, 1 Oct 2003 06:20:50 -0700 (PDT) Received: from smtp.infracaninophile.co.uk (ns0.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id CBF1943FFB for ; Wed, 1 Oct 2003 06:20:46 -0700 (PDT) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost [127.0.0.1]) h91DK7fs089710 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 1 Oct 2003 14:20:37 +0100 (BST) (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost)id h91DK7CN089696; Wed, 1 Oct 2003 14:20:07 +0100 (BST) (envelope-from matthew) Date: Wed, 1 Oct 2003 14:20:07 +0100 From: Matthew Seaman To: Aragon Gouveia Message-ID: <20031001132007.GB11691@happy-idiot-talk.infracaninophile.co.uk> Mail-Followup-To: Matthew Seaman , Aragon Gouveia , questions@freebsd.org References: <20031001124829.GA15390@phat.za.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="K8nIJk4ghYZn606h" Content-Disposition: inline In-Reply-To: <20031001124829.GA15390@phat.za.net> User-Agent: Mutt/1.5.4i X-Spam-Status: No, hits=-4.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=2.60 X-Spam-Checker-Version: SpamAssassin 2.60 (1.212-2003-09-23-exp) on happy-idiot-talk.infracaninophile.co.uk cc: questions@freebsd.org Subject: Re: port install to jail root from host system X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Oct 2003 13:20:51 -0000 --K8nIJk4ghYZn606h Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Oct 01, 2003 at 02:48:29PM +0200, Aragon Gouveia wrote: > I've compiled a port as normal (apache13 in this case). I'd like to run > 'make install' now and tell it to install the package to the base of the > root filesystem of a jail from the jail's host. Possibly also to skip > registering it in the host's package database. >=20 > Does anyone know an easy way to do this with the ports system? >=20 > I realise apache is dependant on various libraries that may not be in the > jail, but these dependancies I will resolve manually. It actually works quite well if you use mount_null(8) to re-mount your /usr/ports tree inside the jail, and set the WRKDIRPREFIX environment variable to something like /usr/obj so that you don't actually write into the /usr/ports tree while compiling. A line something like: /usr/ports /jail/192.168.0.2/usr/ports null rw 0 0 in /etc/fstab in the host system should do the trick nicely. That way, you can just ssh(1) into your jailed system and manage ports/packages exactly as you do in the host system. This will also avoid, in a trivially simple way, problems caused by corrupting the /var/db/pkg database in the host system. Cheers, Matthew --=20 Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way PGP: http://www.infracaninophile.co.uk/pgpkey Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK --K8nIJk4ghYZn606h Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (FreeBSD) iD8DBQE/etSHdtESqEQa7a0RAt+sAJ4srgBf+b8Mezw0/zY7ls9kra5N6QCfVA2Z bzWKwQaNtXdfVcl/TlX1yqw= =dUC3 -----END PGP SIGNATURE----- --K8nIJk4ghYZn606h--