mirror of
https://github.com/BastilleBSD/bastille.git
synced 2025-12-11 09:29:55 +01:00
parallel: Remove pkg, destroy, migrate
This commit is contained in:
@@ -207,6 +207,7 @@ case "${CMD}" in
|
||||
console| \
|
||||
convert| \
|
||||
create| \
|
||||
destroy| \
|
||||
edit| \
|
||||
etcupdate| \
|
||||
export| \
|
||||
@@ -214,7 +215,9 @@ case "${CMD}" in
|
||||
import| \
|
||||
limits| \
|
||||
list| \
|
||||
migrate| \
|
||||
network| \
|
||||
pkg| \
|
||||
rcp| \
|
||||
rdr| \
|
||||
rename| \
|
||||
@@ -231,12 +234,9 @@ case "${CMD}" in
|
||||
# Commands that allow parallel mode
|
||||
config| \
|
||||
cp| \
|
||||
destroy| \
|
||||
jcp| \
|
||||
limits| \
|
||||
migrate| \
|
||||
mount| \
|
||||
pkg| \
|
||||
restart| \
|
||||
start| \
|
||||
stop| \
|
||||
|
||||
@@ -334,17 +334,7 @@ case "${TARGET}" in
|
||||
# Destroy targeted jail(s)
|
||||
set_target "${TARGET}" "reverse"
|
||||
for _jail in ${JAILS}; do
|
||||
if [ "${AUTO_YES}" -eq 1 ]; then
|
||||
(
|
||||
destroy_jail "${_jail}"
|
||||
) &
|
||||
else
|
||||
(
|
||||
destroy_jail "${_jail}"
|
||||
)
|
||||
fi
|
||||
bastille_running_jobs "${bastille_process_limit}"
|
||||
destroy_jail "${_jail}"
|
||||
done
|
||||
wait
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -348,8 +348,6 @@ validate_host_status "${USER}" "${HOST}" "${PORT}"
|
||||
|
||||
for _jail in ${JAILS}; do
|
||||
|
||||
(
|
||||
|
||||
# Validate jail state
|
||||
if [ "${LIVE}" -eq 1 ]; then
|
||||
if ! check_target_is_running "${_jail}"; then
|
||||
@@ -371,9 +369,5 @@ for _jail in ${JAILS}; do
|
||||
|
||||
info "\nSuccessfully migrated '${_jail}' to '${HOST}'.\n"
|
||||
|
||||
) &
|
||||
|
||||
bastille_running_jobs "${bastille_process_limit}"
|
||||
|
||||
done
|
||||
wait
|
||||
echo
|
||||
|
||||
@@ -140,29 +140,8 @@ pkg_run_command() {
|
||||
}
|
||||
|
||||
for _jail in ${JAILS}; do
|
||||
|
||||
if [ "${AUTO_YES}" -eq 1 ]; then
|
||||
|
||||
(
|
||||
|
||||
pkg_run_command "$@"
|
||||
|
||||
) &
|
||||
|
||||
else
|
||||
|
||||
(
|
||||
|
||||
pkg_run_command "$@"
|
||||
|
||||
)
|
||||
|
||||
fi
|
||||
|
||||
bastille_running_jobs "${bastille_process_limit}"
|
||||
|
||||
pkg_run_command "$@"
|
||||
done
|
||||
wait
|
||||
echo
|
||||
|
||||
bastille_return_exit_code
|
||||
|
||||
Reference in New Issue
Block a user