Dynamically defining classes, ordering, hardware detection
Niall Young
niall at chime.net.au
Thu Jan 16 07:25:30 CET 2003
On Wed, 15 Jan 2003, AUSTIN MURPHY wrote:
> On Wed, 15 Jan 2003, Niall Young wrote:
> >
> > How about overriding other class behaviour with hooks and files, I
> > guess that gets back to the order in which everything is defined
> > and run - e.g. class FOO installs /etc/lilo.conf but if class BAH
> > also has one, how can I guarantee that BAH replaces it *after* FOO
> > has finished?
>
> If you use fcopy, and BAH is defined before FOO, fcopy will copy the
> lilo.conf from BAH. If BAH is not defined, but FOO is, then fcopy will
> copy FOO's lilo.conf.
Exactly, what I'm saying is to override the order in which classes are
executed - give them some sort of priority or execution order, maybe
instead of the order they're defined or an alphabetical sort of
FAI_CONFIGDIR/scripts/* we could check if "dependency" classes have been
executed yet and if not stick ours at the end of the queue?
> > I'm back to thinking about class ordering and inheritence now, anyone
> > looking into this stuff already?
>
> I have a patch that does this that we spoke about a few months ago.
> http://toolbox.rutgers.edu/~amurphy/fai/rec_def_cls.txt
Sorry, never had a decent look. It looks great, but only covers
defining the classes - I'm suggesting a similar approach for when
they're executed, or maybe this solves that problem too if they're
executed in order of definition? I should really be reading the source
instead of ranting yet again ;-)
Niall Young Chime Communications Pty Ltd
niall at chime.net.au Level 6, 263 Adelaide Terrace
Ph: (+61) 08 9213 1330 / 0408 192 797 Perth, Western Australia 6000
"there's a lot of movement in my trousers at the moment"
-- Dennis Kristofich, Sep 2002
More information about the linux-fai
mailing list