import osbuild-53-2.el8

This commit is contained in:
CentOS Sources 2022-05-10 03:01:23 -04:00 committed by Stepan Oksanichenko
parent e61a53e822
commit a45260a5fc
6 changed files with 82 additions and 172 deletions

2
.gitignore vendored
View File

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

View File

@ -1 +1 @@
e7c0228039b6cbab841af199cbe2558254362526 SOURCES/osbuild-35.tar.gz
17e48ab794e3112551f533fe4a8c8b74d6602ef7 SOURCES/osbuild-53.tar.gz

View File

@ -1,75 +0,0 @@
From 7ec305a343c48444678416bc187cd7c2ab54e26d Mon Sep 17 00:00:00 2001
From: Christian Kellner <christian@kellner.me>
Date: Thu, 9 Sep 2021 11:03:12 +0200
Subject: [PATCH 1/2] ostree.config: add `bootloader` config option
Ability to set the bootloader backend that OSTree should use. NB:
normally this should be set to `none` since in modern distros and
bootloaders the BLS is used and the BLS snippets are generated on
`none` but none of the of the specific bootloader tools are run,
like `grub2-mkconfig` for grub.
Update the fedora image manifest to use that config setting.
---
stages/org.osbuild.ostree.config | 8 ++++++++
test/data/manifests/fedora-ostree-image.json | 3 ++-
test/data/manifests/fedora-ostree-image.mpp.json | 3 ++-
3 files changed, 12 insertions(+), 2 deletions(-)
diff --git a/stages/org.osbuild.ostree.config b/stages/org.osbuild.ostree.config
index 5dc378c..4bd25c4 100755
--- a/stages/org.osbuild.ostree.config
+++ b/stages/org.osbuild.ostree.config
@@ -5,6 +5,9 @@ Change OSTree configuration
Change the configuration for an OSTree repository.
Currently only the following values are supported:
- `sysroot.readonly`
+ - `sysroot.bootloader`
+
+See `ostree.repo-config(5)` for more information.
"""
import os
@@ -32,6 +35,11 @@ SCHEMA = """
"additionalProperties": false,
"description": "Options concerning the sysroot",
"properties": {
+ "bootloader": {
+ "description": "Configure the bootloader that OSTree uses (use 'none' for BLS).",
+ "type": "string",
+ "enum": ["none", "auto", "grub2", "syslinux", "uboot", "zipl"]
+ },
"readonly": {
"description": "Read only sysroot and boot",
"type": "boolean"
diff --git a/test/data/manifests/fedora-ostree-image.json b/test/data/manifests/fedora-ostree-image.json
index 2562dab..2e6e716 100644
--- a/test/data/manifests/fedora-ostree-image.json
+++ b/test/data/manifests/fedora-ostree-image.json
@@ -870,7 +870,8 @@
"repo": "/ostree/repo",
"config": {
"sysroot": {
- "readonly": true
+ "readonly": true,
+ "bootloader": "none"
}
}
}
diff --git a/test/data/manifests/fedora-ostree-image.mpp.json b/test/data/manifests/fedora-ostree-image.mpp.json
index bab2eb4..689cbf0 100644
--- a/test/data/manifests/fedora-ostree-image.mpp.json
+++ b/test/data/manifests/fedora-ostree-image.mpp.json
@@ -282,7 +282,8 @@
"repo": "/ostree/repo",
"config": {
"sysroot": {
- "readonly": true
+ "readonly": true,
+ "bootloader": "none"
}
}
}
--
2.31.1

View File

@ -1,29 +0,0 @@
From 21ad9fa3992ba0f28750b5808cebdacdde104e08 Mon Sep 17 00:00:00 2001
From: Christian Kellner <christian@kellner.me>
Date: Wed, 22 Sep 2021 10:30:52 +0000
Subject: [PATCH] stages/qemu: fix 'compat' option
The option got renamed to `compat` (and moved into the `qemu`
object) when the stage was extracted from the `qemu` assembler;
but the code, taken from the assembler, still used the old
`qcow2_compat` name for the option. Fix this.
---
stages/org.osbuild.qemu | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/stages/org.osbuild.qemu b/stages/org.osbuild.qemu
index bfefac3..cb6b3a8 100755
--- a/stages/org.osbuild.qemu
+++ b/stages/org.osbuild.qemu
@@ -126,7 +126,7 @@ SCHEMA_2 = r"""
def qcow2_arguments(options):
argv = ["-c"]
- compat = options.get("qcow2_compat")
+ compat = options.get("compat")
if compat:
argv += ["-o", f"compat={compat}"]
--
2.32.0

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: 53
%forgemeta
@ -9,26 +9,19 @@ Version: 35
%global pkgdir %{_prefix}/lib/%{pypi_name}
Name: %{pypi_name}
Release: 3%{?dist}
Release: 2%{?dist}
License: ASL 2.0
URL: %{forgeurl}
Source0: %{forgesource}
# https://github.com/osbuild/osbuild/pull/806
Patch0: ostree-bootloader-backend.patch
# https://github.com/osbuild/osbuild/pull/795
Patch1: rhsm-none-check.patch
# https://github.com/osbuild/osbuild/pull/819
Patch2: qemu-fix-compat-option.patch
BuildArch: noarch
Summary: A build system for OS images
BuildRequires: make
BuildRequires: python3-devel
BuildRequires: python3-docutils
BuildRequires: systemd
Requires: bash
Requires: bubblewrap
@ -76,6 +69,24 @@ Summary: %{summary}
%description -n python3-%{pypi_name}
A build system for OS images
%package lvm2
Summary: LVM2 support
Requires: %{name} = %{version}-%{release}
Requires: lvm2
%description lvm2
Contains the necessary stages and device host
services to build LVM2 based images.
%package luks2
Summary: LUKS2 support
Requires: %{name} = %{version}-%{release}
Requires: cryptsetup
%description luks2
Contains the necessary stages and device host
services to build LUKS2 encrypted images.
%package ostree
Summary: OSTree support
Requires: %{name} = %{version}-%{release}
@ -101,6 +112,7 @@ containers it uses to build OS artifacts.
%package tools
Summary: Extra tools and utilities
Requires: %{name} = %{version}-%{release}
Requires: python3-pyyaml
%description tools
Contains additional tools and utilities for development of
@ -108,9 +120,6 @@ manifests and osbuild.
%prep
%forgesetup
%patch0 -p1
%patch1 -p1
%patch2 -p1
%build
%py3_build
@ -165,6 +174,10 @@ install -p -m 0644 -t %{buildroot}%{_mandir}/man5/ docs/*.5
install -D -m 0644 -t %{buildroot}%{_datadir}/selinux/packages/%{selinuxtype} %{name}.pp.bz2
install -D -m 0644 -t %{buildroot}%{_mandir}/man8 selinux/%{name}_selinux.8
# Udev rules
mkdir -p %{buildroot}%{_udevrulesdir}
install -p -m 0755 data/10-osbuild-inhibitor.rules %{buildroot}%{_udevrulesdir}
%check
exit 0
# We have some integration tests, but those require running a VM, so that would
@ -177,6 +190,14 @@ exit 0
%{_mandir}/man5/%{name}-manifest.5*
%{_datadir}/osbuild/schemas
%{pkgdir}
%{_udevrulesdir}/*.rules
# the following files are in the lvm2 sub-package
%exclude %{pkgdir}/devices/org.osbuild.lvm2*
%exclude %{pkgdir}/stages/org.osbuild.lvm2*
# the following files are in the luks2 sub-package
%exclude %{pkgdir}/devices/org.osbuild.luks2*
%exclude %{pkgdir}/stages/org.osbuild.crypttab
%exclude %{pkgdir}/stages/org.osbuild.luks2*
# the following files are in the ostree sub-package
%exclude %{pkgdir}/assemblers/org.osbuild.ostree*
%exclude %{pkgdir}/inputs/org.osbuild.ostree*
@ -186,10 +207,19 @@ 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}/
%files lvm2
%{pkgdir}/devices/org.osbuild.lvm2*
%{pkgdir}/stages/org.osbuild.lvm2*
%files luks2
%{pkgdir}/devices/org.osbuild.luks2*
%{pkgdir}/stages/org.osbuild.crypttab
%{pkgdir}/stages/org.osbuild.luks2*
%files ostree
%{pkgdir}/assemblers/org.osbuild.ostree*
%{pkgdir}/inputs/org.osbuild.ostree*
@ -216,16 +246,43 @@ fi
%files tools
%{_bindir}/osbuild-mpp
%changelog
* Fri Sep 24 2021 Ondřej Budai <obudai@redhat.com> - 35-3
- Include patch for qemu stage to fix the compat option that was
just ignored before.
* Tue Sep 14 2021 Christian Kellner <gicmo@redhat.com> - 35-2
- Include patch for ostree.config stage to support the selection of
the bootloader backend.
- Include patch to fix a potential crash in the detection of rhsm
secrets when 'redhat.repo' is missing.
%changelog
* Thu Mar 24 2022 Ondřej Budai <ondrej@budai.cz> - 53-2
- Bump release field in order to resolve conflict with 8.7's version of osbuild
* Thu Mar 24 2022 imagebuilder-bot <imagebuilder-bots+imagebuilder-bot@redhat.com> - 53-1
- New upstream release
* Sun Feb 27 2022 Simon Steinbeiss <simon.steinbeiss@redhat.com> - 50-1
- New upstream release
* Wed Feb 23 2022 Simon Steinbeiss <simon.steinbeiss@redhat.com> - 49-1
- New upstream release
* Thu Feb 17 2022 Chloe Kaubisch <chloe.kaubisch@gmail.com> - 48-1
- New upstream release
* Thu Feb 03 2022 Jacob Kozol <jacobdkozol@gmail.com> - 47-1
- New upstream release
* Wed Jan 19 2022 Simon Steinbeiss <simon.steinbeiss@redhat.com> - 46-1
- New upstream release
* Mon Jan 10 2022 Tomas Hozza <thozza@redhat.com> - 45-1
- New upstream release
* Wed Jan 05 2022 Simon Steinbeiss <simon.steinbeiss@redhat.com> - 44-1
- New upstream release
* Wed Dec 01 2021 Achilleas Koutsou <achilleas@redhat.com> - 43-1
- New upstream release
* Mon Nov 29 2021 Ondřej Budai <ondrej@budai.cz> - 42-1
- New upstream release
* Fri Oct 15 2021 Achilleas Koutsou <achilleas@redhat.com> - 39-1
- New upstream release
* Sun Aug 29 2021 Tom Gundersen <teg@jklm.no> - 35-1
- Upstream release 35