14 lines
326 B
Go
14 lines
326 B
Go
|
|
package facts
|
||
|
|
|
||
|
|
import "metis/pkg/inventory"
|
||
|
|
|
||
|
|
// RecommendTargets builds per-class targets from snapshots.
|
||
|
|
func RecommendTargets(inv *inventory.Inventory, snaps []Snapshot) map[string]Targets {
|
||
|
|
sum := Aggregate(inv, snaps)
|
||
|
|
out := map[string]Targets{}
|
||
|
|
for cls, s := range sum {
|
||
|
|
out[cls] = ChooseTargets(s)
|
||
|
|
}
|
||
|
|
return out
|
||
|
|
}
|