import osbuild-42-1.el9

This commit is contained in:
CentOS Sources 2021-12-07 12:15:43 -05:00 committed by Stepan Oksanichenko
parent 5b250da3be
commit 8cda1f6b47
4 changed files with 10 additions and 56 deletions

2
.gitignore vendored
View File

@ -1 +1 @@
SOURCES/osbuild-35.tar.gz
SOURCES/osbuild-42.tar.gz

View File

@ -1 +1 @@
e7c0228039b6cbab841af199cbe2558254362526 SOURCES/osbuild-35.tar.gz
b8cf5a56914828be3315523c90271c46ae8ceda8 SOURCES/osbuild-42.tar.gz

View File

@ -1,43 +0,0 @@
From e1311c029501fac714e42c63e6f75ab5ea608924 Mon Sep 17 00:00:00 2001
From: Sanne Raymaekers <sanne.raymaekers@gmail.com>
Date: Fri, 3 Sep 2021 19:27:10 +0200
Subject: [PATCH 1/2] util/rhsm: Check if repositories is None before iterating
When `get_fallback_rhsm_secrets` was used, `Subscriptions.repositories`
was None, and `get_secrets` never returned the fallback secrets.
So check if `repositories` is None before
iterating over it, otherwise return the fallback secrets.
---
osbuild/util/rhsm.py | 15 ++++++++-------
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/osbuild/util/rhsm.py b/osbuild/util/rhsm.py
index 21a2d50..3ab1729 100644
--- a/osbuild/util/rhsm.py
+++ b/osbuild/util/rhsm.py
@@ -93,13 +93,14 @@ class Subscriptions:
def get_secrets(self, url):
# Try to find a matching URL from redhat.repo file first
- for parameters in self.repositories.values():
- if parameters["matchurl"].match(url) is not None:
- return {
- "ssl_ca_cert": parameters["sslcacert"],
- "ssl_client_key": parameters["sslclientkey"],
- "ssl_client_cert": parameters["sslclientcert"]
- }
+ if self.repositories is not None:
+ for parameters in self.repositories.values():
+ if parameters["matchurl"].match(url) is not None:
+ return {
+ "ssl_ca_cert": parameters["sslcacert"],
+ "ssl_client_key": parameters["sslclientkey"],
+ "ssl_client_cert": parameters["sslclientcert"]
+ }
# In case there is no matching URL, try the fallback
if self.secrets:
--
2.31.1

View File

@ -1,7 +1,7 @@
%global forgeurl https://github.com/osbuild/osbuild
%global selinuxtype targeted
Version: 35
Version: 42
%forgemeta
@ -9,16 +9,12 @@ Version: 35
%global pkgdir %{_prefix}/lib/%{pypi_name}
Name: %{pypi_name}
Release: 2%{?dist}
Release: 1%{?dist}
License: ASL 2.0
URL: %{forgeurl}
Source0: %{forgesource}
# https://github.com/osbuild/osbuild/pull/795
Patch1: rhsm-none-check.patch
BuildArch: noarch
Summary: A build system for OS images
@ -104,7 +100,6 @@ manifests and osbuild.
%prep
%forgesetup
%patch1 -p1
%build
%py3_build
@ -180,7 +175,7 @@ exit 0
%files -n python3-%{pypi_name}
%license LICENSE
%doc README.md NEWS.md
%doc README.md
%{python3_sitelib}/%{pypi_name}-*.egg-info/
%{python3_sitelib}/%{pypi_name}/
@ -212,9 +207,11 @@ fi
%changelog
* Tue Sep 14 2021 Christian Kellner <gicmo@redhat.com> - 35-2
- Include patch to fix a potential crash in the detection of rhsm
secrets when 'redhat.repo' is missing.
* Wed Nov 17 2021 'Gianluca Zuccarelli' <'<gzuccare@redhat.com>'> - 42-1
- New upstream release
* Thu Oct 07 2021 Simon Steinbeiß <simon.steinbeiss@redhat.com> - 39-1
- New upstream release
* Sun Aug 29 2021 Tom Gundersen <tgunders@redhat.com> - 35-1
- Upstream release 35