From 31cc087ef30d801ea402e0ed615d2db0ed8b006d Mon Sep 17 00:00:00 2001 From: tschettervictor <85497460+tschettervictor@users.noreply.github.com> Date: Mon, 16 Dec 2024 17:44:36 -0700 Subject: [PATCH] Add set_target function --- usr/local/share/bastille/common.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/usr/local/share/bastille/common.sh b/usr/local/share/bastille/common.sh index 85310110..42eb4b66 100644 --- a/usr/local/share/bastille/common.sh +++ b/usr/local/share/bastille/common.sh @@ -92,6 +92,15 @@ check_target_is_running() { fi } +set_target() { + if [ "{1}" = ALL ] || [ "{1}" = all]; then + target_all_jails + else + TARGET="{1}" + check_target_exists "{TARGET}" + fi +} + target_all_jails() { _JAILS=$(/usr/sbin/jls name) JAILS=""