From cfb55eaf01dd78136af783f81e9eb48cde7c5db8 Mon Sep 17 00:00:00 2001 From: saite Date: Thu, 28 Mar 2013 18:51:14 +0000 Subject: Introduce _post_start_script. --- ezjail.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ezjail.sh b/ezjail.sh index 37cd42a..2e16e4b 100755 --- a/ezjail.sh +++ b/ezjail.sh @@ -112,6 +112,7 @@ do_cmd() eval ezjail_zfs_datasets=\"\$jail_${ezjail_safename}_zfs_datasets\" eval ezjail_cpuset=\"\$jail_${ezjail_safename}_cpuset\" + eval ezjail_post_start_script=\"\$jail_${ezjail_safename}_post_start_script\" # Attach ZFS-datasets to the jail for zfs in ${ezjail_zfs_datasets}; do @@ -120,6 +121,9 @@ do_cmd() # Configure processor sets for the jail via cpuset(1) [ -z "${ezjail_cpuset}" ] || /usr/bin/cpuset -l ${ezjail_cpuset} -j ${ezjail_id} || echo -n "Error: The defined cpuset is malformed" + + # Run post start script + [ -z "${ezjail_post_start_script}" ] || "${ezjail_post_start_script}" ${ezjail_id} "${ezjail}" || echo -n "Error: Post Start Script failed" done fi -- cgit v1.2.3