Re: jail_<name>_conf in /etc/rc.conf

From: Fabian Keil <freebsd-listen_at_fabiankeil.de>
Date: Wed, 14 Jun 2006 12:19:06 +0200
"Raphael H. Becker" <rabe_at_p-i-n.com> wrote:

> having a jail-server and maintaining lots of jails may cause headache,
> when editing /etc/rc.conf. 
> 
> My idea is to define per-jail.conf files outside /etc/rc.conf.

> This would make using conf-templates much easier and you don't 
> need to do evil "script-magic" on /etc/rc.conf.

> Any alternative solution getting something like this running?

Try /usr/ports/sysutils/ezjail/
<http://erdgeist.org/arts/software/ezjail/>

It only requires one line in rc.conf
and uses one configuration file for every jail:

fk_at_TP51 ~ $grep jail /etc/rc.conf
ezjail_enable="YES"

fk_at_TP51 ~ $cat /usr/local/etc/ezjail/porttest 
# To specify the start up order of your ezjails, use these lines to
# create a Jail dependency tree. See rcorder(8) for more details.
#
# PROVIDE: standard_ezjail
# REQUIRE: 
# BEFORE: 
#

export jail_porttest_hostname="porttest"
export jail_porttest_ip="192.168.6.100"
export jail_porttest_rootdir="/usr/jails/porttest"
export jail_porttest_exec="/bin/sh /etc/rc"
export jail_porttest_mount_enable="YES"
export jail_porttest_devfs_enable="YES"
export jail_porttest_devfs_ruleset="devfsrules_pf_jail"
export jail_porttest_procfs_enable="YES"
export jail_porttest_fdescfs_enable="YES"
export jail_porttest_image=""
export jail_porttest_imagetype=""
export jail_porttest_attachparams=""
export jail_porttest_attachblocking=""
export jail_porttest_forceblocking=""

Fabian
-- 
http://www.fabiankeil.de/

Received on Wed Jun 14 2006 - 08:19:24 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:57 UTC