commit
f33755b2d0
@ -0,0 +1 @@
|
||||
f7b6e12ebb69e4061b9ab0aa27b58d5e8b215970 SOURCES/boom-1.4.tar.gz
|
@ -0,0 +1 @@
|
||||
SOURCES/boom-1.4.tar.gz
|
@ -0,0 +1,31 @@
|
||||
From 841e7d3d0dc7ad194e0b82d8cd0930cef1a95301 Mon Sep 17 00:00:00 2001
|
||||
From: Marian Csontos <mcsontos@redhat.com>
|
||||
Date: Fri, 29 Nov 2019 10:23:44 +0100
|
||||
Subject: [PATCH 1/5] man: Fix line starting with '
|
||||
|
||||
Lines starting with ' result in macro not defined warnings:
|
||||
|
||||
1117: warning: macro `boom' not defined
|
||||
1118: warning: macro `+'' not defined
|
||||
---
|
||||
man/man8/boom.8 | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/man/man8/boom.8 b/man/man8/boom.8
|
||||
index 7b862e7..9eee048 100644
|
||||
--- a/man/man8/boom.8
|
||||
+++ b/man/man8/boom.8
|
||||
@@ -1168,8 +1168,8 @@ describing the properties of the configured host profiles.
|
||||
|
||||
The list of fields to display is given with \fB--options\fP as a comma
|
||||
separated list of field names. To obtain a list of available fields run
|
||||
-'\fBboom host list -o help\fP'. If the list of fields begins with the
|
||||
-'\fB+\fP' character the specified fields are appended to the default
|
||||
+\&'\fBboom host list -o help\fP'. If the list of fields begins with the
|
||||
+\&'\fB+\fP' character the specified fields are appended to the default
|
||||
field list. Otherwise the given list of fields replaces the default set
|
||||
of report fields.
|
||||
|
||||
--
|
||||
2.34.3
|
||||
|
@ -0,0 +1,43 @@
|
||||
From a3e33031fb4051eb9d76f950b536b513c58be861 Mon Sep 17 00:00:00 2001
|
||||
From: "Bryn M. Reeves" <bmr@redhat.com>
|
||||
Date: Tue, 14 Jun 2022 07:47:04 -0400
|
||||
Subject: [PATCH 2/5] boom.bootloader: initialise _last_path before parsing
|
||||
BootEntry
|
||||
|
||||
The path from which a boot entry was read can be useful context for
|
||||
logging messages, particularly when a boot entry has been corrupted or
|
||||
manually edited (so that the boot_id no longer matches the expected
|
||||
value).
|
||||
|
||||
Move the initialisation of this member before parsing the boot entry, so
|
||||
that the value is available for log messages.
|
||||
|
||||
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
|
||||
(cherry picked from commit fafa77556e442fe4f016c23eb9739f1015fa9eb8)
|
||||
---
|
||||
boom/bootloader.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/boom/bootloader.py b/boom/bootloader.py
|
||||
index aa9131f..185195d 100644
|
||||
--- a/boom/bootloader.py
|
||||
+++ b/boom/bootloader.py
|
||||
@@ -1484,6 +1484,7 @@ class BootEntry(object):
|
||||
|
||||
entry_basename = basename(entry_file)
|
||||
_log_debug("Loading BootEntry from '%s'" % entry_basename)
|
||||
+ self._last_path = entry_file
|
||||
|
||||
with open(entry_file, "r") as ef:
|
||||
for line in ef:
|
||||
@@ -1536,7 +1537,6 @@ class BootEntry(object):
|
||||
entry_basename)
|
||||
self.read_only = True
|
||||
|
||||
- self._last_path = entry_file
|
||||
self._unwritten = False
|
||||
|
||||
def __init__(self, title=None, machine_id=None, osprofile=None,
|
||||
--
|
||||
2.34.3
|
||||
|
@ -0,0 +1,47 @@
|
||||
From faf43a2b923dd2e558da1e48978541389844f464 Mon Sep 17 00:00:00 2001
|
||||
From: "Bryn M. Reeves" <bmr@redhat.com>
|
||||
Date: Tue, 14 Jun 2022 07:50:11 -0400
|
||||
Subject: [PATCH 3/5] boom.bootloader: improve warning for entries with no
|
||||
root_device
|
||||
|
||||
A boot entry with no root_device= is invalid. Log the path to the file
|
||||
rather than the boot_id since this may have changed if the entry is
|
||||
corrupt/modified, and is not included in the file name for system
|
||||
provided boot entries.
|
||||
|
||||
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
|
||||
(cherry picked from commit b70d2ad6a4b8f7ef7816426bcb18b6f247a52dca)
|
||||
---
|
||||
boom/bootloader.py | 3 +--
|
||||
tests/bootloader_tests.py | 1 +
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/boom/bootloader.py b/boom/bootloader.py
|
||||
index 185195d..bbf7fd5 100644
|
||||
--- a/boom/bootloader.py
|
||||
+++ b/boom/bootloader.py
|
||||
@@ -720,8 +720,7 @@ class BootParams(object):
|
||||
# The root_device key is handled specially since it is required
|
||||
# for a valid BootEntry.
|
||||
if name == 'root_device' and not value:
|
||||
- _log_warn("Entry with boot_id=%s has no root_device"
|
||||
- % be.boot_id)
|
||||
+ _log_warn("No root_device for entry at %s" % be._last_path)
|
||||
setattr(bp, name, "")
|
||||
|
||||
def is_add(opt):
|
||||
diff --git a/tests/bootloader_tests.py b/tests/bootloader_tests.py
|
||||
index 129000d..ace82bd 100644
|
||||
--- a/tests/bootloader_tests.py
|
||||
+++ b/tests/bootloader_tests.py
|
||||
@@ -158,6 +158,7 @@ class MockBootEntry(object):
|
||||
expand_options = "root=/dev/mapper/rhel-root ro rhgb quiet"
|
||||
_osp = None
|
||||
_entry_data = {}
|
||||
+ _last_path = "/some/path/to/somewhere"
|
||||
|
||||
|
||||
class BootEntryBasicTests(unittest.TestCase):
|
||||
--
|
||||
2.34.3
|
||||
|
@ -0,0 +1,46 @@
|
||||
From 31f95734f0d6f90f256754377207f5373ff9015c Mon Sep 17 00:00:00 2001
|
||||
From: "Bryn M. Reeves" <bmr@redhat.com>
|
||||
Date: Tue, 14 Jun 2022 07:54:29 -0400
|
||||
Subject: [PATCH 4/5] boom.bootloader: do not allow deletion of read-only boot
|
||||
entries
|
||||
|
||||
Currently when attempting to delete an entry that has been marked
|
||||
read-only boom generates a misleading error message:
|
||||
|
||||
# boom delete 7fce1e5
|
||||
Entry does not exist: /boot/loader/entries/619c4d9f1efa4cf7bd76f149f12138a0-7fce1e5-5.14.0-108.el9.x86_64.conf
|
||||
|
||||
Boom should not attempt to delete entries that are marked read-only;
|
||||
these are either system provided entries, or entries that have been
|
||||
modified outside of boom's control. Reject attempts to delete these
|
||||
with an error that indicates the reason they cannot be removed:
|
||||
|
||||
# boom delete f6f8df5
|
||||
Cannot delete read-only boot entry: /boot/loader/entries/68f613d8774e41e792fad28212cfedae-4.18.0-348.el8.x86_64.conf
|
||||
|
||||
Resolves: #10
|
||||
|
||||
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
|
||||
(cherry picked from commit 42f66737e1d7dec432cd7fc330f87304a585c308)
|
||||
---
|
||||
boom/bootloader.py | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/boom/bootloader.py b/boom/bootloader.py
|
||||
index bbf7fd5..a81ea84 100644
|
||||
--- a/boom/bootloader.py
|
||||
+++ b/boom/bootloader.py
|
||||
@@ -2445,6 +2445,10 @@ class BootEntry(object):
|
||||
:raises: ``OsError`` if an error occurs removing the file or
|
||||
``ValueError`` if the entry does not exist.
|
||||
"""
|
||||
+ if self.read_only:
|
||||
+ raise ValueError("Cannot delete read-only boot "
|
||||
+ "entry: %s" % self._last_path)
|
||||
+
|
||||
if not path_exists(self._entry_path):
|
||||
raise ValueError("Entry does not exist: %s" % self._entry_path)
|
||||
try:
|
||||
--
|
||||
2.34.3
|
||||
|
@ -0,0 +1,35 @@
|
||||
From cd0c4e28b0b2de9000edd5b4b56612d610337552 Mon Sep 17 00:00:00 2001
|
||||
From: "Bryn M. Reeves" <bmr@redhat.com>
|
||||
Date: Tue, 14 Jun 2022 09:31:33 -0400
|
||||
Subject: [PATCH 5/5] boom.command: add new os-release values to Red Hat
|
||||
optional keys list
|
||||
|
||||
Add "Red Hat Enterprise Linux" (NAME for el8 onwards), and "Fedora
|
||||
Linux" (NAME for fc35 onwards) to the table of names to automatically
|
||||
enable grub optional keys for.
|
||||
|
||||
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
|
||||
(cherry picked from commit 0cb2d8da9de6fa01ebc5193e7ab6710a9c7b7125)
|
||||
---
|
||||
boom/command.py | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/boom/command.py b/boom/command.py
|
||||
index 0ef66ee..07c0616 100644
|
||||
--- a/boom/command.py
|
||||
+++ b/boom/command.py
|
||||
@@ -1094,9 +1094,11 @@ def _default_optional_keys(osp):
|
||||
"""
|
||||
all_optional_keys = "grub_users grub_arg grub_class id"
|
||||
_default_optional_keys = [
|
||||
+ "Red Hat Enterprise Linux",
|
||||
"Red Hat Enterprise Linux Server",
|
||||
"Red Hat Enterprise Linux Workstation",
|
||||
"CentOS Linux",
|
||||
+ "Fedora Linux",
|
||||
"Fedora"
|
||||
]
|
||||
if osp.os_name in _default_optional_keys:
|
||||
--
|
||||
2.34.3
|
||||
|
@ -0,0 +1,246 @@
|
||||
%global summary A set of libraries and tools for managing boot loader entries
|
||||
%global sphinx_docs 1
|
||||
|
||||
Name: boom-boot
|
||||
Version: 1.4
|
||||
Release: 4%{?dist}
|
||||
Summary: %{summary}
|
||||
|
||||
License: GPLv2
|
||||
URL: https://github.com/snapshotmanager/boom
|
||||
Source0: https://github.com/snapshotmanager/boom/archive/%{version}/boom-%{version}.tar.gz
|
||||
Patch1: 0001-man-Fix-line-starting-with.patch
|
||||
# Minor improvements:
|
||||
Patch2: 0002-boom.bootloader-initialise-_last_path-before-parsing.patch
|
||||
Patch3: 0003-boom.bootloader-improve-warning-for-entries-with-no-.patch
|
||||
# BZ 2096447:
|
||||
Patch4: 0004-boom.bootloader-do-not-allow-deletion-of-read-only-b.patch
|
||||
# BZ 2096368:
|
||||
Patch5: 0005-boom.command-add-new-os-release-values-to-Red-Hat-op.patch
|
||||
|
||||
BuildArch: noarch
|
||||
|
||||
BuildRequires: make
|
||||
BuildRequires: python3-setuptools
|
||||
BuildRequires: python3-devel
|
||||
%if 0%{?sphinx_docs}
|
||||
BuildRequires: python3-dbus
|
||||
BuildRequires: python3-sphinx
|
||||
%endif
|
||||
BuildRequires: make
|
||||
|
||||
Requires: python3-boom = %{version}-%{release}
|
||||
Requires: %{name}-conf = %{version}-%{release}
|
||||
|
||||
Obsoletes: boom-boot-grub2 <= 1.3
|
||||
# boom-grub2 was not an official name of subpackage in fedora, but was used upstream:
|
||||
Obsoletes: boom-grub2 <= 1.3
|
||||
|
||||
%package -n python3-boom
|
||||
Summary: %{summary}
|
||||
%{?python_provide:%python_provide python3-boom}
|
||||
Requires: %{__python3}
|
||||
Recommends: (lvm2 or brtfs-progs)
|
||||
Recommends: %{name}-conf = %{version}-%{release}
|
||||
|
||||
# There used to be a boom package in fedora, and there is boom packaged in
|
||||
# copr. How to tell which one is installed? We need python3-boom and no boom
|
||||
# only.
|
||||
Conflicts: boom
|
||||
|
||||
%package conf
|
||||
Summary: %{summary}
|
||||
|
||||
%description
|
||||
Boom is a boot manager for Linux systems using boot loaders that support
|
||||
the BootLoader Specification for boot entry configuration.
|
||||
|
||||
Boom requires a BLS compatible boot loader to function: either the
|
||||
systemd-boot project, or Grub2 with the BLS patch (Red Hat Grub2 builds
|
||||
include this support in both Red Hat Enterprise Linux 7 and Fedora).
|
||||
|
||||
%description -n python3-boom
|
||||
Boom is a boot manager for Linux systems using boot loaders that support
|
||||
the BootLoader Specification for boot entry configuration.
|
||||
|
||||
Boom requires a BLS compatible boot loader to function: either the
|
||||
systemd-boot project, or Grub2 with the BLS patch (Red Hat Grub2 builds
|
||||
include this support in both Red Hat Enterprise Linux 7 and Fedora).
|
||||
|
||||
This package provides python3 boom module.
|
||||
|
||||
%description conf
|
||||
Boom is a boot manager for Linux systems using boot loaders that support
|
||||
the BootLoader Specification for boot entry configuration.
|
||||
|
||||
Boom requires a BLS compatible boot loader to function: either the
|
||||
systemd-boot project, or Grub2 with the BLS patch (Red Hat Grub2 builds
|
||||
include this support in both Red Hat Enterprise Linux 7 and Fedora).
|
||||
|
||||
This package provides configuration files for boom.
|
||||
|
||||
%prep
|
||||
%setup -n boom-%{version}
|
||||
# NOTE: Do not use backup extension - MANIFEST.in is picking them
|
||||
%patch1 -p1
|
||||
%patch2 -p1
|
||||
%patch3 -p1
|
||||
%patch4 -p1
|
||||
%patch5 -p1
|
||||
|
||||
%build
|
||||
%if 0%{?sphinx_docs}
|
||||
make -C doc html
|
||||
rm doc/_build/html/.buildinfo
|
||||
mv doc/_build/html doc/html
|
||||
rm -r doc/_build
|
||||
%endif
|
||||
|
||||
%py3_build
|
||||
|
||||
%install
|
||||
%py3_install
|
||||
|
||||
# Make configuration directories
|
||||
# mode 0700 - in line with /boot/grub2 directory:
|
||||
install -d -m 700 ${RPM_BUILD_ROOT}/boot/boom/profiles
|
||||
install -d -m 700 ${RPM_BUILD_ROOT}/boot/boom/hosts
|
||||
install -d -m 700 ${RPM_BUILD_ROOT}/boot/loader/entries
|
||||
install -d -m 700 ${RPM_BUILD_ROOT}/boot/boom/cache
|
||||
install -m 644 examples/boom.conf ${RPM_BUILD_ROOT}/boot/boom
|
||||
|
||||
mkdir -p ${RPM_BUILD_ROOT}/%{_mandir}/man8
|
||||
mkdir -p ${RPM_BUILD_ROOT}/%{_mandir}/man5
|
||||
install -m 644 man/man8/boom.8 ${RPM_BUILD_ROOT}/%{_mandir}/man8
|
||||
install -m 644 man/man5/boom.5 ${RPM_BUILD_ROOT}/%{_mandir}/man5
|
||||
|
||||
rm doc/Makefile
|
||||
rm doc/conf.py
|
||||
|
||||
# Test suite currently does not operate in rpmbuild environment
|
||||
#%%check
|
||||
#%%{__python3} setup.py test
|
||||
|
||||
%files
|
||||
%license COPYING
|
||||
%doc README.md
|
||||
%{_bindir}/boom
|
||||
%doc %{_mandir}/man*/boom.*
|
||||
|
||||
%files -n python3-boom
|
||||
%license COPYING
|
||||
%doc README.md
|
||||
%{python3_sitelib}/*
|
||||
%doc doc
|
||||
%doc examples
|
||||
%doc tests
|
||||
|
||||
%files conf
|
||||
%license COPYING
|
||||
%doc README.md
|
||||
%dir /boot/boom
|
||||
%config(noreplace) /boot/boom/boom.conf
|
||||
%dir /boot/boom/profiles
|
||||
%dir /boot/boom/hosts
|
||||
%dir /boot/boom/cache
|
||||
%dir /boot/loader/entries
|
||||
|
||||
|
||||
%changelog
|
||||
* Wed Mar 15 2023 MSVSphere Packaging Team <packager@msvsphere.ru> - 1.4-4
|
||||
- Rebuilt for MSVSphere 9.1.
|
||||
|
||||
* Wed Jul 13 2022 Marian Csontos <mcsontos@redhat.com> 1.4-4
|
||||
- Fix handling of read-only entries.
|
||||
- Add OS names for recent versions.
|
||||
|
||||
* Tue May 24 2022 Marian Csontos <mcsontos@redhat.com> 1.4-3
|
||||
- Fix missing /boot/boom/profiles directory.
|
||||
|
||||
* Tue May 24 2022 Marian Csontos <mcsontos@redhat.com> 1.4-2
|
||||
- Update gating.yaml.
|
||||
|
||||
* Mon May 23 2022 Marian Csontos <mcsontos@redhat.com> 1.4-1
|
||||
- Update to release 1.4.
|
||||
|
||||
* Wed Jan 19 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.3-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
||||
|
||||
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.3-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||
|
||||
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 1.3-2
|
||||
- Rebuilt for Python 3.10
|
||||
|
||||
* Fri Jan 29 2021 Marian Csontos <mcsontos@redhat.com> 1.3-1
|
||||
- Update to release 1.3.
|
||||
|
||||
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.2-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
|
||||
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.2-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
* Sun Jun 07 2020 Marian Csontos <mcsontos@redhat.com> 1.2-1
|
||||
- Update to bug fix release 1.2.
|
||||
|
||||
* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 1.1-4
|
||||
- Rebuilt for Python 3.9
|
||||
|
||||
* Tue May 26 2020 Marian Csontos <mcsontos@redhat.com> 1.1-3
|
||||
- Fix unicode entries handling.
|
||||
- Add tracebacks when --debug is used.
|
||||
|
||||
* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 1.1-2
|
||||
- Rebuilt for Python 3.9
|
||||
|
||||
* Thu May 14 2020 Marian Csontos <mcsontos@redhat.com> 1.1-1
|
||||
- Update to new upstream release 1.1.
|
||||
- Add caching of kernel and init ramdisk images.
|
||||
|
||||
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
* Mon Jan 20 2020 Marian Csontos <mcsontos@redhat.com> 1.0-1
|
||||
- Update to new upstream release 1.0.
|
||||
|
||||
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 1.0-0.5.20190329git6ff3e08
|
||||
- Rebuilt for Python 3.8.0rc1 (#1748018)
|
||||
|
||||
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 1.0-0.4.20190329git6ff3e08
|
||||
- Rebuilt for Python 3.8
|
||||
|
||||
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.0-0.3.20190329git6ff3e08
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
* Thu May 09 2019 Marian Csontos <mcsontos@redhat.com> 1.0-0.2.20190329git6ff3e08
|
||||
- Fix packaging issues.
|
||||
|
||||
* Thu May 09 2019 Marian Csontos <mcsontos@redhat.com> 1.0-0.1.20190329git6ff3e08
|
||||
- Pre-release of new version.
|
||||
|
||||
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.9-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Tue Jul 17 2018 Marian Csontos <mcsontos@redhat.com> 0.9-4
|
||||
- Change dependencies.
|
||||
|
||||
* Mon Jul 16 2018 Marian Csontos <mcsontos@redhat.com> 0.9-3
|
||||
- Split executable, python module and configuration.
|
||||
|
||||
* Wed Jun 27 2018 Marian Csontos <mcsontos@redhat.com> 0.9-2
|
||||
- Spin off grub2 into subpackage
|
||||
|
||||
* Wed Jun 27 2018 Marian Csontos <mcsontos@redhat.com> 0.9-1
|
||||
- Update to new upstream 0.9.
|
||||
- Fix boot_id caching.
|
||||
|
||||
* Fri Jun 08 2018 Marian Csontos <mcsontos@redhat.com> 0.8.5-6.2
|
||||
- Remove example files from /boot/boom/profiles.
|
||||
|
||||
* Fri May 11 2018 Marian Csontos <mcsontos@redhat.com> 0.8.5-6.1
|
||||
- Files in /boot are treated as configuration files.
|
||||
|
||||
* Thu Apr 26 2018 Marian Csontos <mcsontos@redhat.com> 0.8.5-6
|
||||
- Package upstream version 0.8-5.6
|
||||
|
Loading…
Reference in new issue