[et-mgmt-tools] Looping through possibilities in a "snippet"

Michael DeHaan mdehaan at redhat.com
Fri Apr 11 20:05:18 UTC 2008


>>
>> What if we changed the semantics of...
>>
>> SNIPPET::foosball
>>
>> which would now be smart and would pull one of the following, 
>> whichever exists first:
>>
>> /var/lib/cobbler/snippets/system/foosball/$system_name
>> /var/lib/cobbler/snippets/profile/foosball/$profile_name
>> /var/lib/cobbler/snippets/distro/foosball/$distro_name
>> /var/lib/cobbler/snippets/foosball
>>
>> whichever was found first.
>>
>> I think this is what you're getting at and could be done fairly 
>> cleanly without being package specific.
>>
>> Of course the stock install would lay down none of these paths except 
>> the directories and this would largely be just documented
>> if you decide to use it (on the Wiki).
>
> I think that would be perfect! Thanks!
>
> -s-

I've implemented this here -- with only a slight change to the way the 
above behavior works (basically there are no distro-overrides
and the paths are slightly different):

https://fedorahosted.org/cobbler/wiki/KickstartSnippets

It's under the "Advanced Snippets" section and is available now in the 
git/devel branch. Testing welcome!

--Michael





More information about the et-mgmt-tools mailing list