mirror of
https://github.com/swissmakers/fail2ban-ui.git
synced 2026-04-17 14:03:15 +02:00
Remove LogPath from local connector settings
This commit is contained in:
@@ -22,7 +22,6 @@ import (
|
||||
"net"
|
||||
"os"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
@@ -106,7 +105,7 @@ func main() {
|
||||
|
||||
// Register routes
|
||||
web.RegisterRoutes(router, wsHub)
|
||||
isLOTRMode := isLOTRModeActive(settings.AlertCountries)
|
||||
isLOTRMode := config.IsLOTRModeActive(settings.AlertCountries)
|
||||
printWelcomeBanner(bindAddress, serverPort, isLOTRMode)
|
||||
if isLOTRMode {
|
||||
log.Println("--- Middle-earth Security Realm activated ---")
|
||||
@@ -120,17 +119,6 @@ func main() {
|
||||
log.Fatalf("Could not start server: %v\n", err)
|
||||
}
|
||||
}
|
||||
func isLOTRModeActive(alertCountries []string) bool {
|
||||
if len(alertCountries) == 0 {
|
||||
return false
|
||||
}
|
||||
for _, country := range alertCountries {
|
||||
if strings.EqualFold(country, "LOTR") {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
// Print welcome banner.
|
||||
func printWelcomeBanner(bindAddress, appPort string, isLOTRMode bool) {
|
||||
|
||||
Reference in New Issue
Block a user