Atom Powers wrote: > Is it possible to glob hard class names? > For instance I currently have: > -- > Groups: > freebsd_4 = ( freebsd_4_11_STABLE freebsd_4_10_STABLE > freebsd_4_10_RELEASE_p3 ) > freebsd_5 = ( freebsd_5_3_RELEASE freebsd_5_3_STABLE ) > -- > > But I'm still missing a lot of systems. "freebsd_5_4_PRERELEASE", for > example, won't match either group. Can I do something like: > > -- > Groups: > freebsd_4 = ( freebsd_4_* ) > freebsd_5 = ( freebsd_5_* ) > -- > > Or is there another way to easily define a group for these hard classes? (And > still catch "freebsd_5_4_STABLE" when it is released.)
How about a module or an ExecResult() class? Maybe: classes: freebsd_4 = ( freebsd ExecResult(/bin/sh -c '/usr/bin/uname -r | /usr/bin/grep ^4') ) freebsd_5 = ( freebsd ExecResult(/bin/sh -c '/usr/bin/uname -r | /usr/bin/grep ^5') ) I don't manage any FreeBSD machines, so I'm not sure if there is a better way, but I bet that would work. Best, Brendan _______________________________________________ Help-cfengine mailing list Help-cfengine@gnu.org http://lists.gnu.org/mailman/listinfo/help-cfengine