diff --git a/usr/local/share/bastille/bootstrap.sh b/usr/local/share/bastille/bootstrap.sh index 2e21289d..ada5cb85 100644 --- a/usr/local/share/bastille/bootstrap.sh +++ b/usr/local/share/bastille/bootstrap.sh @@ -458,6 +458,20 @@ if [ -n "${NAME_VERIFY}" ]; then bootstrap_release else usage +fi + ;; +*-stable-build-*|*-STABLE-BUILD-*) +## check for HardenedBSD(for current changes) +NAME_VERIFY=$(echo "${RELEASE}" | grep -iwE '([0-9]{1,2})(-stable-build|-STABLE-BUILD)-([0-9]{1,2})$' | sed 's/BUILD/build/g' | sed 's/STABLE/stable/g') +NAME_RELEASE=$(echo ${NAME_VERIFY} | sed 's/-build-[0-9]\{1,2\}//g') +NAME_BUILD=$(echo ${NAME_VERIFY} | sed 's/[0-9]\{1,2\}-stable-//g') +if [ -n "${NAME_VERIFY}" ]; then + RELEASE="${NAME_VERIFY}" + UPSTREAM_URL="http://ci-01.nyi.hardenedbsd.org/pub/hardenedbsd/${NAME_RELEASE}/${HW_MACHINE}/${HW_MACHINE_ARCH}/${NAME_BUILD}" + bootstrap_directories + bootstrap_release +else + usage fi ;; http?://github.com/*/*|http?://gitlab.com/*/*) diff --git a/usr/local/share/bastille/create.sh b/usr/local/share/bastille/create.sh index 918e64d3..fe8fd755 100644 --- a/usr/local/share/bastille/create.sh +++ b/usr/local/share/bastille/create.sh @@ -333,6 +333,15 @@ fi *-stable-LAST|*-STABLE-last|*-stable-last|*-STABLE-LAST) ## check for HardenedBSD releases name NAME_VERIFY=$(echo "${RELEASE}" | grep -iwE '^([1-9]{2,2})(-stable-LAST|-STABLE-last|-stable-last|-STABLE-LAST)$' | sed 's/STABLE/stable/g' | sed 's/last/LAST/g') +if [ -n "${NAME_VERIFY}" ]; then + RELEASE="${NAME_VERIFY}" +else + usage +fi + ;; +*-stable-build-*|*-STABLE-BUILD-*) +## check for HardenedBSD(for current changes) +NAME_VERIFY=$(echo "${RELEASE}" | grep -iwE '([0-9]{1,2})(-stable-build|-STABLE-BUILD)-([0-9]{1,2})$' | sed 's/BUILD/build/g' | sed 's/STABLE/stable/g') if [ -n "${NAME_VERIFY}" ]; then RELEASE="${NAME_VERIFY}" else diff --git a/usr/local/share/bastille/destroy.sh b/usr/local/share/bastille/destroy.sh index e899b837..5f2659bb 100644 --- a/usr/local/share/bastille/destroy.sh +++ b/usr/local/share/bastille/destroy.sh @@ -146,7 +146,6 @@ case "${NAME}" in usage fi ;; - *-stable-LAST|*-STABLE-last|*-stable-last|*-STABLE-LAST) ## check for HardenedBSD releases name NAME_VERIFY=$(echo "${NAME}" | grep -iwE '^([1-9]{2,2})(-stable-LAST|-STABLE-last|-stable-last|-STABLE-LAST)$' | sed 's/STABLE/stable/g' | sed 's/last/LAST/g') @@ -157,8 +156,17 @@ case "${NAME}" in usage fi ;; +*-stable-build-*|*-STABLE-BUILD-*) +## check for HardenedBSD(for current changes) +NAME_VERIFY=$(echo "${NAME}" | grep -iwE '([0-9]{1,2})(-stable-build|-STABLE-BUILD)-([0-9]{1,2})$' | sed 's/BUILD/build/g' | sed 's/STABLE/stable/g') + if [ -n "${NAME_VERIFY}" ]; then + NAME="${NAME_VERIFY}" + destroy_rel + else + usage + fi + ;; *) - ## just destroy a jail destroy_jail ;;