From 8f5502e31394a3c460017fb650b6af6c9a7bb413 Mon Sep 17 00:00:00 2001 From: Jose Date: Tue, 1 Oct 2019 17:52:59 -0400 Subject: [PATCH] Start jails if directory not empty --- bastille-init | 10 +++++++--- release_notes | 1 + version | 2 +- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/bastille-init b/bastille-init index 4e4ebc4..fc77f55 100755 --- a/bastille-init +++ b/bastille-init @@ -547,9 +547,13 @@ get_versions() ext_start() { # Start bastille jails. - JAIL_AUTO_START=$(sysrc -qn bastille_enable) - if [ "${JAIL_AUTO_START}" = "YES" ]; then - service bastille start + if [ -d "${CWDIR}/jails" ]; then + if [ "$(ls -A ${CWDIR}/jails)" ]; then + JAIL_AUTO_START=$(sysrc -qn bastille_enable) + if [ "${JAIL_AUTO_START}" = "YES" ]; then + service bastille start + fi + fi fi if [ $? -eq 0 ]; then diff --git a/release_notes b/release_notes index bc1615c..5b9fa48 100644 --- a/release_notes +++ b/release_notes @@ -3,6 +3,7 @@ ====================== Version Description +0.0.4......Start jails if directory not empty. 0.0.3......Minor code adjustment. 0.0.2......Added addon preview page. 0.0.1......First Release. diff --git a/version b/version index bcab45a..81340c7 100644 --- a/version +++ b/version @@ -1 +1 @@ -0.0.3 +0.0.4