forcing script to be run as root

This commit is contained in:
John Lancaster
2026-03-12 09:20:16 -05:00
parent 42b7ec401a
commit 2f00e6902b

View File

@@ -15,6 +15,11 @@ GREEN_CHECK="\e[32m✔\e[0m"
RED_X="\e[31m✗\e[0m"
YELLOW_BANG="\e[33m!\e[0m"
if [[ "${EUID:-$(id -u)}" -ne 0 ]]; then
echo -e "${RED_X} This script must be run as root or with sudo." >&2
exit 1
fi
CREATE_USER_CA=0
CREATE_HOST_CERT=0
NEEDS_RESTART=0