RE: Turning a hostname list into a class list

2010-01-29 Thread Justin Lloyd
nating ] for character class" in expression " E[ XE[ " at 9 Thanks, Justin -Original Message- From: Nakarin Phooripoom [mailto:mynameisje...@gmail.com] Sent: Friday, January 29, 2010 12:24 PM To: Justin Lloyd Cc: help-cfengine@cfengine.org Subject: Re: Turning a hostna

Re: Turning a hostname list into a class list

2010-01-29 Thread Nakarin Phooripoom
Could we do something like this following? classes: "test_hosts_c" or => { classmatch(canonify("$(test_hosts)")) }; Cheers, --Nakarin On Jan 29, 2010, at 8:02 PM, Justin Lloyd wrote: > If I have a list of hostnames, many of which have hyphens in them, what’s the > cleanest way of generat

Turning a hostname list into a class list

2010-01-29 Thread Justin Lloyd
If I have a list of hostnames, many of which have hyphens in them, what's the cleanest way of generating a class list. For example, say I have the following slist, which may come from a text file, LDAP, or may just be hard-coded in a policy file. vars: "test_hosts" slist => { "foo