Skip to content

Instantly share code, notes, and snippets.

@sarcasticadmin
Created May 13, 2025 15:44
Show Gist options
  • Save sarcasticadmin/d72de1e146188ea0b1ea941f1105f9dd to your computer and use it in GitHub Desktop.
Save sarcasticadmin/d72de1e146188ea0b1ea941f1105f9dd to your computer and use it in GitHub Desktop.
example of greating a jail from zfs snapshot
zfs send tiger/jail/imgs/12-1-base@init | zfs receive tiger/jail/$1
cat << EOF >> /etc/jail.conf
$1 {
vnet;
vnet.interface="e0b_$1";
devfs_ruleset=5;
allow.raw_sockets = 1;
enforce_statfs = 2;
securelevel = 2;
}
EOF
echo "$1 jail ready!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment