From 145983adae439caacc4b66ca7f975c1a4c5efa28 Mon Sep 17 00:00:00 2001 From: Jitka Halova <41325380+jobselko@users.noreply.github.com> Date: Tue, 10 Mar 2026 14:26:21 +0100 Subject: [PATCH] Merge pull request #1136 from gerrod3/sync-https Fix syncing with non-https URL (cherry picked from commit 4020a8734b5d00075ac06dfb97346ff8eeefe2e3) --- CHANGES/+non-https-syncs.bugfix | 1 + pulp_python/app/tasks/sync.py | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) create mode 100644 CHANGES/+non-https-syncs.bugfix diff --git a/CHANGES/+non-https-syncs.bugfix b/CHANGES/+non-https-syncs.bugfix new file mode 100644 index 00000000..bc1833da --- /dev/null +++ b/CHANGES/+non-https-syncs.bugfix @@ -0,0 +1 @@ +Fixed sync issue where non https URLs were not allowed. diff --git a/pulp_python/app/tasks/sync.py b/pulp_python/app/tasks/sync.py index b364c3dd..1ceaf207 100644 --- a/pulp_python/app/tasks/sync.py +++ b/pulp_python/app/tasks/sync.py @@ -65,7 +65,6 @@ def create_bandersnatch_config(remote): config = BandersnatchConfig() config["mirror"]["master"] = remote.url config["mirror"]["workers"] = str(remote.download_concurrency) - config["mirror"]["allow_non_https"] = "true" if not config.has_section("plugins"): config.add_section("plugins") config["plugins"]["enabled"] = "blocklist_release\n" @@ -120,7 +119,7 @@ async def run(self): if not isinstance(downloader, HttpDownloader): raise ValueError("Only HTTP(S) is supported for python syncing") - async with Master(url) as master: + async with Master(url, allow_non_https=True) as master: # Replace the session with the remote's downloader session old_session = master.session master.session = downloader.session