Where is official documentation for "jail.conf"?

Since the several past releases, we had been been getting this message:

Code:
/etc/rc.d/jail: WARNING: Per-jail configuration via jail_* variables  is obsolete.  Please consider migrating to /etc/jail.conf.

I had been keeping watch on the jails documentation for a few years and still couldn't see any mentioning of "jail.conf". Will the documentation be updated soon?

Thanks!
 
Ummm... I saw this documentation before. It is too brief. I don't want to spend too much doing trial and error to get it to work. Let's hope the official documenation ("Handbook") will be updated soon. :)
 
Not much to it actually, it simply uses the options from jail(8). There's an example jail.conf at the end of jail(8):

Code:
 Create an entry for the jail in
     /etc/jail.conf:

           testjail {
                   path = /tmp/jail/testjail;
                   mount.devfs;
                   host.hostname = testhostname;
                   ip4.addr = 192.0.2.100;
                   interface = ed0;
                   exec.start = "/bin/sh /etc/rc";
                   exec.stop = "/bin/sh /etc/rc.shutdown";
           }

Each of the settings in jail.conf refers to an option of the same name from jail(8).
 
That doesn't look difficult.

So, the existence of the file itself will cause the jail to be started automatically? There is no need to include a reference from the rc.conf file like 'jail_list="testjail"'?
 
You'll need these:
Code:
jail_enable="YES"
jail_list="myjail1 myjail2"
You can define more jails in jail.conf but only the ones listed in jail_list will get started at boot.
 
But of course you don't need the jail_list=".." var. Just having jail_enable="YES" in your rc.conf will start every jail configured in jail.conf
 
But of course you don't need the jail_list=".." var. Just having jail_enable="YES" in your rc.conf will start every jail configured in jail.conf
It defaults to _ALL when jail_list isn't defined. Note that jail_list="" is not the same as not defining it.

Code:
1)      run_rc_command $@ ${jail_list:-_ALL} ;;
 
Back
Top