feat(models): widen Site struct and DB schema for ping, port, dns, group monitor types

Add Hostname, Port, Timeout, Method, Description, ParentID, AcceptedCodes,
DNSResolveType, DNSServer, and IgnoreTLS fields. Refactor AddSite/UpdateSite
to accept models.Site instead of individual params. Includes DB migrations
for existing databases, per-monitor timeout/TLS in the engine, new type
options in TUI forms, and TYPE column in the sites table.
This commit is contained in:
2026-05-14 17:10:56 -04:00
parent 2bf452d429
commit f06dd5702b
7 changed files with 231 additions and 76 deletions
+2 -2
View File
@@ -9,8 +9,8 @@ type Store interface {
// Sites
GetSites() []models.Site
AddSite(name, url, sType string, interval, alertID int, checkSSL bool, threshold, retries int)
UpdateSite(id int, name, url, sType string, interval, alertID int, checkSSL bool, threshold, retries int)
AddSite(site models.Site)
UpdateSite(site models.Site)
DeleteSite(id int)
// Alerts