0.2.76 - Icon Packs

This commit is contained in:
ponzischeme89
2026-08-18 14:59:29 +12:00
parent 36d171e51b
commit 8c847c59b8
70 changed files with 5267 additions and 673 deletions
+21
View File
@@ -129,6 +129,15 @@ func (s *Server) embyHealthInterval() time.Duration {
s.cfg.EmbyHealthInterval)
}
// LibrarySyncInterval is how often the catalogue sweep runs. Exported because the syncer's
// schedule reads it every tick rather than closing over it at start-up — a setting read
// once at start-up is not a setting, and an operator lengthening the sweep after wiring up
// the webhooks must not have to restart the container to see it take effect.
func (s *Server) LibrarySyncInterval() time.Duration {
return overrideWindow(s.gatewaySettings.get().LibrarySyncMinutes, time.Minute,
s.cfg.SyncInterval)
}
// overrideWindow reads one of the three settings that can be switched off: a negative
// value is off, zero is "whatever was deployed", anything else is the override in the
// given unit.
@@ -153,6 +162,7 @@ type deployedGatewaySettings struct {
SonarrAlertMinutes int `json:"sonarrAlertMinutes"`
RadarrAlertMinutes int `json:"radarrAlertMinutes"`
EmbyHealthSeconds int `json:"embyHealthSeconds"`
LibrarySyncMinutes int `json:"librarySyncMinutes"`
}
func (s *Server) deployedSettings() deployedGatewaySettings {
@@ -167,6 +177,7 @@ func (s *Server) deployedSettings() deployedGatewaySettings {
SonarrAlertMinutes: int(s.cfg.SonarrAlertWindow / time.Minute),
RadarrAlertMinutes: int(s.cfg.RadarrAlertWindow / time.Minute),
EmbyHealthSeconds: int(s.cfg.EmbyHealthInterval / time.Second),
LibrarySyncMinutes: int(s.cfg.SyncInterval / time.Minute),
}
}
@@ -184,3 +195,13 @@ func levelName(level slog.Level) string {
return "error"
}
}
// ingestSettle is what the console prints beside the webhook activity, and it is a helper
// for the same reason the others here are: the delay is configuration, and the page must
// report the value actually in force rather than the constant it defaults to.
func (s *Server) ingestSettle() time.Duration {
if s.cfg.IngestSettleDelay > 0 {
return s.cfg.IngestSettleDelay
}
return time.Minute
}