Bugfix create cmd for jails with alias IP

This commit is contained in:
JRGTH
2025-07-17 03:04:32 -04:00
parent f5332cbf1a
commit 25638463db

View File

@@ -69,7 +69,7 @@ validate_name() {
# Make sure NAME has only allowed characters # Make sure NAME has only allowed characters
if [ -n "$(echo "${NAME_SANITY}" | awk "/^[-_].*$/" )" ]; then if [ -n "$(echo "${NAME_SANITY}" | awk "/^[-_].*$/" )" ]; then
error_exit "[ERROR]: Jail names may not begin with (-|_) characters!" error_exit "[ERROR]: Jail names may not begin with (-|_) characters!"
elif [ "${VNET_JAIL}" -eq 1 ] && echo "${NAME_VERIFY}" | grep -qE '(-|_)'; then elif [ -n "${VNET_JAIL}" ] && echo "${NAME_VERIFY}" | grep -qE '(-|_)'; then
error_exit "[ERROR]: VNET jail names may not contain (-|_) characters." error_exit "[ERROR]: VNET jail names may not contain (-|_) characters."
elif [ "${NAME_VERIFY}" != "${NAME_SANITY}" ]; then elif [ "${NAME_VERIFY}" != "${NAME_SANITY}" ]; then
error_exit "[ERROR]: Jail names may not contain special characters!" error_exit "[ERROR]: Jail names may not contain special characters!"