[katello-devel] Katello disconnected ideas
Lukas Zapletal
lzap at redhat.com
Thu Sep 13 14:14:24 UTC 2012
On Thu, Sep 13, 2012 at 09:09:19AM -0400, Todd Sanders wrote:
> <snip>
> >It'd probably be easier to explain in a meeting, so let me know if
> >you want me to set up an elluminate to take you through some code.
> >I strongly suggest we do this before going any further down the
> >road of rewriting this from scratch. It would save a ton of
> >duplicated effort, not only in writing, but in the fact that
> >Preethi is currently QEing these same commands in Pulp itself.
> </snip>
>
> +1
>
> Since this is designed to be separate from the Katello Server and
> thus leverage a different client from the Katello-CLI....it seems to
> make complete sense to leverage the work that has already been done
> by the Pulp Team.
There is no need to be scared of code duplication. The katello
disconnected tool is not a wrapper around pulp or something. It's a tool
that is able to load a manifest, walk down the CDN tree structure
discovering all the repositories and loading them (creating) in the
pulp.
This is what Pulp IMHO cannot do.
Plus it can initiate a sync, watch a progress and it seems it could also
offer ability to schedule sync. Those are very simple REST calls, in the
code it's one or two calls in a loop:
https://github.com/lzap/katello/blob/manifest_parsing/katello-utils/bin/katello-disconnected#L394
You can see clean, configure, synchronize, watch and export methods
there. Those are trivial, it's not like we are building anything
sophisticated around Pulp, it's a small added value. Perhaps the most
complicated one is watch that asks pulp for status.
And the list won't be much longer - from the feedback it seems I just
need to add ranged export and some way to schedule tasks.
Typical session is:
katello-disconnected import -m mymanifest.zip
katello-disconnected configure
katello-disconnected sync
katello-disconnected watch (optional)
katello-disconnected export -t /my/export/dir
Original python scripts
(https://github.com/beav/katello-disconnected-scripts) were creating
three bash scripts that were calling pulp-admin. I have changed that and
turned this into a more comfortable tool which plays well with manifest
re-importing. Lot's of users will eventually need to re-import new
manifests:
With my approach they can do it easily:
katello-disconnected import -m myNEWmanifest.zip
katello-disconnected configure --remove
It reconfigures pulp according to the configuration adding missing repos
and removing those which are no longer available.
Of course, if user wants to have total control, pulp-admin is still
here. Katello disconnected just makes experience easier for those
without pulp knowledge.
Katello disconnected is complementary tool, it does not supersede pulp
or pulp-admin at all.
> Jay, please find a time to schedule an eluminate session to review
> this with Lukas and the rest of the dev team.
Sure, I am in the CET timezone.
--
Later,
Lukas "lzap" Zapletal
#katello #systemengine
More information about the katello-devel
mailing list