[Fedora-livecd-list] Refactoring livecd-creator and providing an API
Jeroen van Meeuwen
kanarip at kanarip.com
Thu Nov 22 02:19:18 UTC 2007
I've taken a good look at the proposed API and for now I'll just state
some items where I have some questions, doubts or concerns on how to
perform what it is we need to perform.
* In the 'image.InstallPackages()', would it be possible to not use the
yum object provided by livecd-creator itself? Given that tools built
upon livecd-creator may already have a complete yum object it could be
useful to hand over the yum object to this function
* In conjunction with the previous question would it be possible to not
have livecd-creator set up it's own yum object -merely an efficiency
question and completely secondary-?
* For any type of extra configuration or external configuration (e.g.
non-kickstart), would it be possible to have variables such as
'build_dir', 'yum_cache' and '_instroot' defined in (for example)
__init__() so that once we create a class instance we can override them
with another value? More specifically; if we call ImageCreator.setup()
directly now, there's nothing we can do anymore to point our existing
yum installroot to the 'install_root/' directory under which the
loopback filesystem is mounted. More granular functions all doing
little, very little bits and pieces might help too.
Regarding this I see ImageCreatorBase._get_instroot() and _instroot =
property(_get_instroot) -I'm not sure how I could override that -if
possible.
* Can we please drop the '-' in the 'livecd-creator' file so that we can
import it? It'll be a lot easier for us to provide actual feedback in
the form of patches, on what we need changed in the API.
Kind regards,
Jeroen van Meeuwen
-kanarip
Jeremy Katz wrote:
> It's time to get back to something that's been discussed on and off for
> a while now and really do it. And that's to refactor out the core of
> livecd-creator so that it can be used for generating other types of
> images as well as then providing an API to be used by people wanting to
> build various types of interfaces on top of the tools.
>
> After sitting down and poking a little, I've got something that I'm at
> least starting to be happy with and figure it's about time to put it up
> for others to look at and poke at. Right now, the git tree is on
> fedorapeople rather than in the main repo. You can get it with
> git clone http://katzj.fedoraproject.org/git/livecd-tools.git
>
> I've written up a short overview of the API and included it in the repo
> and attached it to this message as well. I've tried to keep the amount
> that we expose pretty minimal so that we can continue to have a fair bit
> of freedom in changing out the backend bits, especially the ones related
> to writing out configuration[1] info.
>
> Comments and suggestions appreciated, especially from those building on
> top of livecd-tools or wanting to build other image builders. I'm going
> to likely go ahead and get this merged within the next week or so as
> long as it's not entirely crazy. Also, it's pending on splitting up the
> current __init__ into separate modules to allow for cleaner namespacing
>
> Jeremy
>
> [1] In the future, this is something that we want to be able to share
> with anaconda as we're currently doing a lot of duplication of bugfixes
> and having to deal with slight variations in behavior between the two.
> Which sucks.
>
>
> ------------------------------------------------------------------------
>
> --
> Fedora-livecd-list mailing list
> Fedora-livecd-list at redhat.com
> https://www.redhat.com/mailman/listinfo/fedora-livecd-list
More information about the Fedora-livecd-list
mailing list