diff --git a/usr/local/bin/bastille b/usr/local/bin/bastille index 3aea524e..6979af0d 100755 --- a/usr/local/bin/bastille +++ b/usr/local/bin/bastille @@ -203,9 +203,11 @@ case "${CMD}" in # Commands that don't allow parallel mode bootstrap| \ clone| \ + cmd| \ console| \ convert| \ create| \ + destroy| \ edit| \ etcupdate| \ export| \ @@ -213,10 +215,13 @@ case "${CMD}" in import| \ limits| \ list| \ + migrate| \ network| \ + pkg| \ rcp| \ rdr| \ rename| \ + service| \ setup| \ top| \ update| \ @@ -227,17 +232,12 @@ case "${CMD}" in fi ;; # Commands that allow parallel mode - cmd| \ config| \ cp| \ - destroy| \ jcp| \ limits| \ - migrate| \ mount| \ - pkg| \ restart| \ - service| \ start| \ stop| \ sysrc| \ diff --git a/usr/local/share/bastille/cmd.sh b/usr/local/share/bastille/cmd.sh index 2f8c05e9..10f15fb7 100644 --- a/usr/local/share/bastille/cmd.sh +++ b/usr/local/share/bastille/cmd.sh @@ -93,8 +93,6 @@ set_target "${TARGET}" for _jail in ${JAILS}; do - ( - # Validate jail state check_target_is_running "${_jail}" || if [ "${AUTO}" -eq 1 ]; then bastille start "${_jail}" @@ -114,12 +112,7 @@ for _jail in ${JAILS}; do fi bastille_check_exit_code "${_jail}" "$?" - - ) & - - bastille_running_jobs "${bastille_process_limit}" done -wait bastille_return_exit_code diff --git a/usr/local/share/bastille/destroy.sh b/usr/local/share/bastille/destroy.sh index 4403442d..56081e10 100644 --- a/usr/local/share/bastille/destroy.sh +++ b/usr/local/share/bastille/destroy.sh @@ -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 diff --git a/usr/local/share/bastille/migrate.sh b/usr/local/share/bastille/migrate.sh index fb23b54c..eacaa753 100644 --- a/usr/local/share/bastille/migrate.sh +++ b/usr/local/share/bastille/migrate.sh @@ -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 diff --git a/usr/local/share/bastille/pkg.sh b/usr/local/share/bastille/pkg.sh index 1d79b491..677b4f4a 100644 --- a/usr/local/share/bastille/pkg.sh +++ b/usr/local/share/bastille/pkg.sh @@ -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 diff --git a/usr/local/share/bastille/service.sh b/usr/local/share/bastille/service.sh index 9551307c..b2988066 100644 --- a/usr/local/share/bastille/service.sh +++ b/usr/local/share/bastille/service.sh @@ -91,8 +91,6 @@ set_target "${TARGET}" for _jail in ${JAILS}; do - ( - # Validate jail state check_target_is_running "${_jail}" || if [ "${AUTO}" -eq 1 ]; then bastille start "${_jail}" @@ -108,12 +106,7 @@ for _jail in ${JAILS}; do bastille_check_exit_code "${_jail}" "$?" - ) & - - bastille_running_jobs "${bastille_process_limit}" - done -wait echo bastille_return_exit_code