Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 18 Jun 2004 19:06:59 -0400
From:      Brian Reichert <reichert@numachi.com>
To:        Kevin Way <kevin@insidesystems.net>
Cc:        FreeBSD Ports <ports@freebsd.org>
Subject:    Re: A proper way to install ports into a jail, from the host machine
Message-ID:  <20040618230659.GB95411@numachi.com>
In-Reply-To: <7D71E62F-C136-11D8-B835-000A957B1E86@insidesystems.net>
References:  <BE784FD4-C06E-11D8-B835-000A957B1E86@insidesystems.net> <20040618141945.GD83682@numachi.com> <7D71E62F-C136-11D8-B835-000A957B1E86@insidesystems.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Jun 18, 2004 at 07:47:58AM -0700, Kevin Way wrote:
> The issue occurs when you want to setup/upgrade machines that have N 
> jails on them.  Right now I can install the majority of ports like 
> this:
> 
> 	jail_portinstall shells/zsh all

I've never used 'jail_portinstall', so have no idea what it's
semantics are.

>  and zsh will get installed into every single jail.  The place where 
> this falls apart is jails that do user/group management.  The checks 
> for user/group existence, and the commands for adding users/groups are 
> generally hard coded such that it's not possible to specify an 
> alternate etc directory, or to ensure that you set file ownership 
> correctly if you modify it manually.

What, like this:

  pw -V ${TESTJAIL}/etc groupadd -n wheel -g 0
  pwd_mkdb -d ${TESTJAIL}/etc ${TESTJAIL}/etc/master.passwd
  pw -V ${TESTJAIL}/etc useradd -n root -u 0 -g wheel

I couldn't set passwords, though...

Other trick: go though the hassle of building one reference jail,
then use rsync to crank out as many copies as you want.  It a good
quick way to 'reset' a jail after use...  (Or, if you're worried
about special flags, maintain a star archive...)

> We're looking for feedback on whether a patchset that attempts to 
> modularize the user/group tests would receive any acceptance, and also 
> to find out if anybody else is currently looking at solving this 
> problem.

Hmmm, good luck...

> Kevin Way
> InsideSystems

-- 
Brian Reichert				<reichert@numachi.com>
37 Crystal Ave. #303			Daytime number: (603) 434-6842
Derry NH 03038-1713 USA			BSD admin/developer at large	



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040618230659.GB95411>