From 332a955814246a54bb26bef0eaedec1a1184a382 Mon Sep 17 00:00:00 2001 From: Adam Williamson Date: Thu, 15 Dec 2016 16:11:37 -0800 Subject: [PATCH] disable updates as well as updates-testing in repo_setup This should solve all those annoying "Failed to synchronize cache for repo 'updates'" failures we've had: there's no need for the 'updates' repository to be enabled when we've decided we want the `repo_setup` changes to be made, and having it enabled causes problems when we run right after the Rawhide compose completes. We hit the awkward period where the rawhide repo has been synced but mirrormanager has not been updated with the new metadata checksums, so mirrormanager rejects the metadata from dl.fp.o and DNF has to go out and hit other mirrors until it finds one which didn't sync yet. Since the point of `repo_setup` is specifically to hack up the config so we only use packages from the compose *anyway*, there's no reason at all to worry about leaving 'updates' enabled and nerfing it like we do 'fedora' and 'rawhide', we can just turn it off. --- lib/installedtest.pm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/installedtest.pm b/lib/installedtest.pm index 2a17dd1c..46230145 100644 --- a/lib/installedtest.pm +++ b/lib/installedtest.pm @@ -82,10 +82,11 @@ sub start_cockpit { } sub repo_setup { - # disable updates-testing and use the compose location rather than - # mirrorlist, so we're testing the right packages + # disable updates-testing and updates and use the compose location + # as the target for fedora and rawhide rather than mirrorlist, so + # tools see only packages from the compose under test my $location = get_var("LOCATION"); - assert_script_run 'dnf config-manager --set-disabled updates-testing'; + assert_script_run 'dnf config-manager --set-disabled updates-testing updates'; # we use script_run here as the rawhide repo file won't always exist # and we don't want to bother testing or predicting its existence; # assert_script_run doesn't buy you much with sed anyway as it'll