// 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
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))
}