#!/bin/sh
set -eu

POOL="${1:-zroot}"
PREFIX="${2:-clawdie-runtime}"
JAIL="${3:-controlplane}"
SNAP="${4:-fresh}"

DATASET="${POOL}/${PREFIX}/jails/${JAIL}"

cat <<EOF
zfs list | grep ${PREFIX}
zfs snapshot ${DATASET}@${SNAP}
zfs rollback ${DATASET}@${SNAP}
EOF
