On Mar 4, 2013 7:01 AM, "James Cammarata" <[email protected]> wrote:
>
> On Mon, Mar 4, 2013 at 7:09 AM, Harry Hoffman <[email protected]>
wrote:
>>
>> Thanks guys,
>>
>> The typo was just in my email. But that code didn't work.
>>
>> What did was the following:
>> #set uname = $users.split(",")
>> #for $name in $uname
>> user --name=$name
>> #end for
>
>
> In that case, you may want to use:
>
> #set $uname = $getVar("users","").split(",")
> #for $name in $uname
> user --name=$name
> #end for
>
> I've tested this as follows:
>
> $ cobbler system edit --name=test2 --ksmeta="users=test1,test2,test3"
> $ cobbler system getks --name=test2 | grep name=test
> user --name=test1
> user --name=test2
> user --name=test3

Changing the way of inputting your data was the main part of my response
above. Sorry if that wasnt clear.

Also it doesn't seem that you need to use the $getVar() function with
ksmeta and can just call $users in the cheetah template code.

Andrew
>
>
> _______________________________________________
> cobbler mailing list
> [email protected]
> https://lists.fedorahosted.org/mailman/listinfo/cobbler
>
_______________________________________________
cobbler mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/cobbler

Reply via email to