1
0
mirror of https://blitiri.com.ar/repos/chasquid synced 2025-12-17 14:37:02 +00:00

Log how many things were loaded for each domain

This patch makes chasquid log how many users, aliases and DKIM keys were
loaded for each domain.

This makes it easier to confirm changes, and troubleshoot problems
related to these per-domain configuration files.
This commit is contained in:
Alberto Bertogli
2024-05-10 11:42:07 +01:00
parent e6a9410377
commit aae0367c60
7 changed files with 45 additions and 24 deletions

View File

@@ -156,12 +156,12 @@ func checkUserDB() {
Fatalf("Error: file %q does not exist", path)
}
_, err := userdb.Load(path)
udb, err := userdb.Load(path)
if err != nil {
Fatalf("Error loading database: %v", err)
}
fmt.Println("Database loaded")
fmt.Printf("Database loaded (%d users)\n", udb.Len())
}
// chasquid-util user-add <user@domain> [--password=<password>] [--receive_only]