upgrader: In jigdo mode, don't check rpm-md repos twice for layers
Typing `rpm-ostree upgrade` was quite verbose with layered packages, we'd see the rpm-md repos twice. The better fix would be to pass the context/sack from one stage to the other, but this is a quick simple fix to at least reduce verbosity (and potentially avoid extra network requests). Closes: #1241 Approved by: jlebon
This commit is contained in:
parent
aa87fe7d1a
commit
782c49b748
@ -865,6 +865,25 @@ prep_local_assembly (RpmOstreeSysrootUpgrader *self,
|
|||||||
cancellable, error))
|
cancellable, error))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
|
RpmOstreeRefspecType refspec_type;
|
||||||
|
const char *refspec;
|
||||||
|
rpmostree_origin_classify_refspec (self->origin, &refspec_type, &refspec);
|
||||||
|
switch (refspec_type)
|
||||||
|
{
|
||||||
|
case RPMOSTREE_REFSPEC_TYPE_OSTREE:
|
||||||
|
break;
|
||||||
|
case RPMOSTREE_REFSPEC_TYPE_ROJIG:
|
||||||
|
{
|
||||||
|
/* We don't want to re-check the metadata, we already did that for the
|
||||||
|
* base. In the future we should try to re-use the DnfContext.
|
||||||
|
*/
|
||||||
|
g_autoptr(DnfState) hifstate = dnf_state_new ();
|
||||||
|
if (!dnf_context_setup_sack (rpmostree_context_get_dnf (self->ctx), hifstate, error))
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
const gboolean have_packages = (self->overlay_packages->len > 0 ||
|
const gboolean have_packages = (self->overlay_packages->len > 0 ||
|
||||||
g_hash_table_size (local_pkgs) > 0 ||
|
g_hash_table_size (local_pkgs) > 0 ||
|
||||||
self->override_remove_packages->len > 0 ||
|
self->override_remove_packages->len > 0 ||
|
||||||
|
Loading…
Reference in New Issue
Block a user