import boom-boot-0.9-7.el8
This commit is contained in:
		
						commit
						5bec5648d3
					
				
							
								
								
									
										1
									
								
								.boom-boot.metadata
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								.boom-boot.metadata
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1 @@ | ||||
| dd96613e238f342641b5be8977ee8598662e8ab9 SOURCES/boom-0.9.tar.gz | ||||
							
								
								
									
										1
									
								
								.gitignore
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								.gitignore
									
									
									
									
										vendored
									
									
										Normal file
									
								
							| @ -0,0 +1 @@ | ||||
| SOURCES/boom-0.9.tar.gz | ||||
							
								
								
									
										13
									
								
								SOURCES/Disable-GRUB2-plugin-on-RHEL-8.patch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								SOURCES/Disable-GRUB2-plugin-on-RHEL-8.patch
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,13 @@ | ||||
|  etc/default/boom | 4 ++-- | ||||
|  1 file changed, 2 insertions(+), 2 deletions(-) | ||||
| 
 | ||||
| diff --git a/etc/default/boom b/etc/default/boom
 | ||||
| index cd5f772..451cb37 100755
 | ||||
| --- a/etc/default/boom
 | ||||
| +++ b/etc/default/boom
 | ||||
| @@ -1,3 +1,3 @@
 | ||||
| -BOOM_USE_SUBMENU="yes"
 | ||||
| +BOOM_USE_SUBMENU="no"
 | ||||
|  BOOM_SUBMENU_NAME="Snapshots" | ||||
| -BOOM_ENABLE_GRUB="yes"
 | ||||
| +BOOM_ENABLE_GRUB="no"
 | ||||
							
								
								
									
										33
									
								
								SOURCES/Reduce-log-level-of-Could-not-load-BootEntry.patch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								SOURCES/Reduce-log-level-of-Could-not-load-BootEntry.patch
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,33 @@ | ||||
| From 13ed30d16790d0ee205c8acc5bead3133845a9ac Mon Sep 17 00:00:00 2001 | ||||
| From: "Bryn M. Reeves" <bmr@redhat.com> | ||||
| Date: Tue, 8 Jan 2019 16:48:19 +0000 | ||||
| Subject: [PATCH] boom: reduce log level of "Could not load BootEntry" messages | ||||
| 
 | ||||
| On systems where other BLS implementations are in use, and where | ||||
| those entries use non-standard BLS keys, boom will emit a warning | ||||
| message for each foreign entry found. This is noisy and of little | ||||
| use to end users: reduce the log message to "info" level, making | ||||
| these errors silent without increased verbosity. | ||||
| 
 | ||||
| Signed-off-by: Bryn M. Reeves <bmr@redhat.com> | ||||
| (cherry picked from commit 40ddddf5c1fa14cd7d39731fd545fe02aab328d0) | ||||
| ---
 | ||||
|  boom/bootloader.py | 2 +- | ||||
|  1 file changed, 1 insertion(+), 1 deletion(-) | ||||
| 
 | ||||
| diff --git a/boom/bootloader.py b/boom/bootloader.py
 | ||||
| index cf50b4e..bc86cb8 100644
 | ||||
| --- a/boom/bootloader.py
 | ||||
| +++ b/boom/bootloader.py
 | ||||
| @@ -504,7 +504,7 @@ def load_entries(machine_id=None):
 | ||||
|          try: | ||||
|              _add_entry(BootEntry(entry_file=entry_path)) | ||||
|          except Exception as e: | ||||
| -            _log_warn("Could not load BootEntry '%s': %s" %
 | ||||
| +            _log_info("Could not load BootEntry '%s': %s" %
 | ||||
|                        (entry_path, e)) | ||||
|   | ||||
|      _log_info("Loaded %d entries" % len(_entries)) | ||||
| -- 
 | ||||
| 1.8.3.1 | ||||
| 
 | ||||
| @ -0,0 +1,70 @@ | ||||
| From eda695b6cda61a5f1901479b6a0b22d8ba1ed96b Mon Sep 17 00:00:00 2001 | ||||
| From: "Bryn M. Reeves" <bmr@redhat.com> | ||||
| Date: Wed, 9 Jan 2019 15:20:27 +0000 | ||||
| Subject: [PATCH] bootloader: raise LookupError on unknown BLS keys | ||||
| 
 | ||||
| When loading a BootEntry from file, if an unknown BLS key is read | ||||
| a generic KeyError is raised when attempting to access a key in | ||||
| the MAP_KEY (bls-to-boom key name map) dictionary. This leads to | ||||
| a fairly cryptic error message: | ||||
| 
 | ||||
|  # boom list -V --debug all | ||||
|  INFO - Could not load BootEntry '/boot/loader/entries/611f38fd887d41dea7eb3403b2730a76-4.15.17-200.fc26.x86_64.conf': 'id' | ||||
| 
 | ||||
| With --debug=all the cause is a little more obvious: | ||||
| 
 | ||||
|  # boom list --debug all | ||||
|  Traceback (most recent call last): | ||||
|    File "bin/boom", line 7, in <module> | ||||
|      main(sys.argv) | ||||
|    File "/home/breeves/src/git/boom/boom/command.py", line 1951, in main | ||||
|      status = command[1](cmd_args, select, opts, identifier) | ||||
|    File "/home/breeves/src/git/boom/boom/command.py", line 1287, in _list_cmd | ||||
|      opts=opts, sort_keys=cmd_args.sort) | ||||
|    File "/home/breeves/src/git/boom/boom/command.py", line 631, in print_entries | ||||
|      bes = find_entries(selection=selection) | ||||
|    File "/home/breeves/src/git/boom/boom/bootloader.py", line 769, in find_entries | ||||
|      load_entries() | ||||
|    File "/home/breeves/src/git/boom/boom/bootloader.py", line 659, in load_entries | ||||
|      _add_entry(BootEntry(entry_file=entry_path)) | ||||
|    File "/home/breeves/src/git/boom/boom/bootloader.py", line 1310, in __init__ | ||||
|      return self.__from_file(entry_file, boot_params) | ||||
|    File "/home/breeves/src/git/boom/boom/bootloader.py", line 1229, in __from_file | ||||
|      key = MAP_KEY[_transform_key(bls_key)] | ||||
|  KeyError: 'id' | ||||
| 
 | ||||
| Instead, raise the exception explicitly if the key is not present, | ||||
| and set the exception string to a meaningful error: | ||||
| 
 | ||||
|  INFO - Could not load BootEntry '/boot/loader/entries/611f38fd887d41dea7eb3403b2730a76-4.15.17-200.fc26.x86_64.conf': Unknown BLS key 'id' | ||||
| 
 | ||||
| The more specific KeyError is not used here since it is specific | ||||
| to dictionary lookup failures. | ||||
| 
 | ||||
| Signed-off-by: Bryn M. Reeves <bmr@redhat.com> | ||||
| (cherry picked from commit 72a67d8beba4c4f36d1c0682a6628b2a823041a4) | ||||
| 
 | ||||
| Conflicts: | ||||
| 	boom/bootloader.py | ||||
| ---
 | ||||
|  boom/bootloader.py | 4 ++++ | ||||
|  1 file changed, 4 insertions(+) | ||||
| 
 | ||||
| diff --git a/boom/bootloader.py b/boom/bootloader.py
 | ||||
| index bc86cb8..dd2a53a 100644
 | ||||
| --- a/boom/bootloader.py
 | ||||
| +++ b/boom/bootloader.py
 | ||||
| @@ -1067,6 +1067,10 @@ class BootEntry(object):
 | ||||
|                      comment += line if line else "" | ||||
|                  else: | ||||
|                      bls_key, value = _parse_name_value(line, separator=None) | ||||
| +                    # Convert BLS key name to Boom notation
 | ||||
| +                    key = _transform_key(bls_key)
 | ||||
| +                    if key not in MAP_KEY:
 | ||||
| +                        raise LookupError("Unknown BLS key '%s'" % bls_key)
 | ||||
|                      key = MAP_KEY[_transform_key(bls_key)] | ||||
|                      entry_data[key] = value | ||||
|                      if comment: | ||||
| -- 
 | ||||
| 1.8.3.1 | ||||
| 
 | ||||
							
								
								
									
										190
									
								
								SPECS/boom-boot.spec
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										190
									
								
								SPECS/boom-boot.spec
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,190 @@ | ||||
| %global summary A set of libraries and tools for managing boot loader entries | ||||
| %global sphinx_docs 1 | ||||
| 
 | ||||
| Name:		boom-boot | ||||
| Version:	0.9 | ||||
| Release:	7%{?dist} | ||||
| Summary:	%{summary} | ||||
| 
 | ||||
| License:	GPLv2 | ||||
| URL:		https://github.com/bmr-cymru/boom | ||||
| Source0:	https://github.com/bmr-cymru/boom/archive/%{version}/boom-%{version}.tar.gz | ||||
| Patch0:         Disable-GRUB2-plugin-on-RHEL-8.patch | ||||
| Patch1:		Reduce-log-level-of-Could-not-load-BootEntry.patch | ||||
| Patch2:		bootloader-raise-LookupError-on-unknown-BLS-keys.patch | ||||
| 
 | ||||
| BuildArch:	noarch | ||||
| 
 | ||||
| BuildRequires:	python3-setuptools | ||||
| BuildRequires:	python3-devel | ||||
| %if 0%{?sphinx_docs} | ||||
| BuildRequires:	python3-sphinx | ||||
| %endif | ||||
| 
 | ||||
| Requires: python3-boom | ||||
| Requires: %{name}-conf | ||||
| 
 | ||||
| %package -n python3-boom | ||||
| Summary: %{summary} | ||||
| %{?python_provide:%python_provide python3-boom} | ||||
| Requires: %{__python3} | ||||
| Recommends: (lvm2 or brtfs-progs) | ||||
| Recommends: %{name}-conf | ||||
| 
 | ||||
| # 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} | ||||
| 
 | ||||
| %package grub2 | ||||
| Summary: %{summary} | ||||
| Supplements: (grub2 and boom-boot) | ||||
| 
 | ||||
| %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. | ||||
| 
 | ||||
| %description grub2 | ||||
| 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 integration scripts for grub2 bootloader. | ||||
| 
 | ||||
| %prep | ||||
| %setup -q -n boom-%{version} | ||||
| # NOTE: Do not use backup extension - MANIFEST.in is picking them | ||||
| %patch0 -p1 | ||||
| %patch1 -p1 | ||||
| %patch2 -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 | ||||
| 
 | ||||
| # Install Grub2 integration scripts | ||||
| mkdir -p ${RPM_BUILD_ROOT}/etc/grub.d | ||||
| mkdir -p ${RPM_BUILD_ROOT}/etc/default | ||||
| install -m 755 etc/grub.d/42_boom ${RPM_BUILD_ROOT}/etc/grub.d | ||||
| install -m 644 etc/default/boom ${RPM_BUILD_ROOT}/etc/default | ||||
| 
 | ||||
| # 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/loader/entries | ||||
| 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/loader/entries | ||||
| 
 | ||||
| %files grub2 | ||||
| %license COPYING | ||||
| %doc README.md | ||||
| %{_sysconfdir}/grub.d/42_boom | ||||
| %config(noreplace) %{_sysconfdir}/default/boom | ||||
| 
 | ||||
| 
 | ||||
| %changelog | ||||
| * Mon Jan 14 2019 Marian Csontos <mcsontos@redhat.com> 0.9-7 | ||||
| - Reduce log level of "Could not load BootEntry" messages. | ||||
| - Raise more appropriate LookupError on unknown BLS keys. | ||||
| 
 | ||||
| * Tue Dec 18 2018 Marian Csontos <mcsontos@redhat.com> 0.9-6 | ||||
| - Disable GRUB2 plugin on RHEL-8. | ||||
| 
 | ||||
| * Mon Sep 17 2018 Tomas Orsava <torsava@redhat.com> - 0.9-5 | ||||
| - Require the Python interpreter directly instead of using the package name | ||||
| - Related: rhbz#1619153 | ||||
| 
 | ||||
| * 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
	
	Block a user