]> ruderich.org/simon Gitweb - safcm/safcm.git/blobdiff - cmd/safcm/config/templates.go
Update copyright years
[safcm/safcm.git] / cmd / safcm / config / templates.go
index b84b4944c017769b10624a675479be4dac6f0f25..01cfb19af1330310b692cb91492e3910b63865f1 100644 (file)
@@ -1,6 +1,6 @@
 // Config: parse templates.yaml and expand templates
 
-// Copyright (C) 2021  Simon Ruderich
+// Copyright (C) 2021-2024  Simon Ruderich
 //
 // This program is free software: you can redistribute it and/or modify
 // it under the terms of the GNU General Public License as published by
@@ -116,7 +116,9 @@ func (t *templateArgs) IsHost(host string) bool {
 func (t *templateArgs) InGroup(group string) bool {
        // Don't permit invalid groups to detect typos; detected groups cannot
        // be checked
-       if !t.allGroups[group] &&
+       if group != GroupAll &&
+               !t.allGroups[group] &&
+               !t.allHosts[group] &&
                !strings.HasPrefix(group, GroupDetectedPrefix) {
                panic(fmt.Sprintf("group %q does not exist", group))
        }