mirror of
https://github.com/prymitive/karma
synced 2026-05-05 03:16:51 +00:00
Merge pull request #140 from cloudflare/min-ttls
We'll get a panic if user sets zero or negative TTL value, add a check
This commit is contained in:
6
main.go
6
main.go
@@ -73,6 +73,12 @@ func main() {
|
||||
log.Infof("Version: %s", version)
|
||||
|
||||
config.Config.Read()
|
||||
|
||||
// timer duration cannot be zero second or a negative one
|
||||
if config.Config.AlertmanagerTTL <= time.Second*0 {
|
||||
log.Fatalf("Invalid AlertmanagerTTL value '%v'", config.Config.AlertmanagerTTL)
|
||||
}
|
||||
|
||||
config.Config.LogValues()
|
||||
transform.ParseRules(config.Config.JiraRegexp)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user