修复Alertmanager无法启动的问题

This commit is contained in:
CN-JS-HuiBai
2026-04-19 16:39:07 +08:00
parent 5fcf0eda8e
commit 350c3be0a9

View File

@@ -61,6 +61,12 @@ echo "--------------------------------------------------------"
read -p "Do you want to enable Email Notifications? [y/N]: " ENABLE_EMAIL
if [[ "$ENABLE_EMAIL" =~ ^[Yy]$ ]]; then
read -p "Enter SMTP Host (e.g. smtp.qq.com:465): " SMTP_HOST
# Ensure port is included
if [[ ! "$SMTP_HOST" == *":"* ]]; then
echo "Warning: Port is missing. Using default port :465"
SMTP_HOST="${SMTP_HOST}:465"
fi
read -p "Enter SMTP Auth Username (Email): " SMTP_USER
read -s -p "Enter SMTP Auth Password: " SMTP_PASS
echo ""