aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/jail/jail.conf.5
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/jail/jail.conf.5')
-rw-r--r--usr.sbin/jail/jail.conf.537
1 files changed, 34 insertions, 3 deletions
diff --git a/usr.sbin/jail/jail.conf.5 b/usr.sbin/jail/jail.conf.5
index ce414b96463e..0b82a972020c 100644
--- a/usr.sbin/jail/jail.conf.5
+++ b/usr.sbin/jail/jail.conf.5
@@ -22,9 +22,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $FreeBSD$
-.\"
-.Dd April 18, 2021
+.Dd September 5, 2023
.Dt JAIL.CONF 5
.Os
.Sh NAME
@@ -163,6 +161,25 @@ would apply to jails with names like
.Dq foo.bar
and
.Dq foo.bar.baz .
+.Ss Includes
+A line of the form
+.Bd -literal -offset ident
+\&.include "filename";
+.Ed
+.Pp
+will include another file (or files) in the configuration.
+The filename should be either absolute, or relative to the
+configuration file's directory. It cannot contain variable
+expansions, but may contain
+.Xr glob 3
+patterns.
+.Pp
+The included file must exist, though a filename glob may match zero or
+more files. This allows inclusion of any/all files in a directory,
+such as
+.Dq /etc/jail.conf.d/*.conf ,
+or conditional inclusion of a single file, such as
+.Dq jail.foo[.]conf .
.Ss Comments
The configuration file may contain comments in the common C, C++, and
shell formats:
@@ -178,6 +195,13 @@ shell formats:
.Pp
Comments are legal wherever whitespace is allowed, i.e. anywhere except
in the middle of a string or a token.
+.Sh FILES
+.Bl -tag -width "indent" -compact
+.It Pa /etc/jail.conf
+.It Pa /etc/jail.*.conf
+.It Pa /etc/jail.conf.d/*.conf
+.It Pa /usr/share/examples/jails/
+.El
.Sh EXAMPLES
.Bd -literal
# Typical static defaults:
@@ -205,6 +229,13 @@ bar {
mount.nodevfs;
persist; // Required because there are no processes
}
+
+# Include configurations from standard locations.
+\[char46]include "/etc/jail.conf.d/*.conf";
+\[char46]include "/etc/jail.*.conf";
+\[char46]include "/usr/local/etc/jail[.]conf";
+\[char46]include "/usr/local/etc/jail.conf.d/*.conf";
+\[char46]include "/usr/local/etc/jail.*.conf";
.Ed
.Sh SEE ALSO
.Xr jail_set 2 ,