System Configuration
JD Runyan
Jason.Runyan at nitckc.usda.gov
Fri Feb 8 21:36:47 CST 2002
>> -----Original Message-----
>> From: JD Runyan
>> [snip]
>> This would be a massive project. I would approach it by
>> creating an api
>> to handle config files, then I would pick an app, and figure
>> out how to
>> patch it to access the new api. The api should parse the
>> files, preferably
>> using a mini-python parser, and then "publish" them with a
>> standard interface
>> for the calling application to use. You would then just need
>> to edit the code
>> in the applications to call your library, and request the
>> values it needs. The
>> functions would be the essentially the same, except when they
>> go to look at the
>> file it would call the library instead. It sounds simpler
>> than it is in practice.
>> The chief benefit I would see to using a scripting language
>> for configs, is
>> the ability to use control statements to essentially create a
>> dynamic config
>> to use on multiple varied hosts.
>>
>> You could also achieve a similar result writing the api, and
>> then running a
>> script at startup that writes out the config files in the
>> vendors format. All
>> you would have to do is write the config script, and then run
>> it to output the
>> new configuration
>Easy for you to say! This is my first real python project.
>All I've done so far are samples from the book.
>
>:'o
>
>Yes, modularizing is the approach to take.
>
>Brian
>
Easy to say, but certainly not an easy task
--
JD Runyan
"You can't milk a point."
David M. Kuehn, Ph.D.
More information about the Kclug
mailing list