diff --git a/20001-Revert-Remove-kickstart-btrfs-support.patch b/20001-Revert-Remove-kickstart-btrfs-support.patch new file mode 100644 index 0000000..b7d7293 --- /dev/null +++ b/20001-Revert-Remove-kickstart-btrfs-support.patch @@ -0,0 +1,67 @@ +From 883db1972480ccb349ae884a5b1845dfde2651e6 Mon Sep 17 00:00:00 2001 +From: Neal Gompa +Date: Mon, 28 Jun 2021 23:18:46 -0400 +Subject: [PATCH 20001/20005] Revert "Remove kickstart btrfs support" + +Restore Btrfs support for Kickstart so system installations can +use Btrfs and images can be built using Lorax with Btrfs as the +filesystem. + +This reverts commit 7e1667fbdc289d62f1dc92411a1d263c22e4be52. +--- + pyanaconda/core/kickstart/commands.py | 10 +++++----- + pyanaconda/modules/storage/kickstart.py | 1 - + 2 files changed, 5 insertions(+), 6 deletions(-) + +diff --git a/pyanaconda/core/kickstart/commands.py b/pyanaconda/core/kickstart/commands.py +index 181045f..2074699 100644 +--- a/pyanaconda/core/kickstart/commands.py ++++ b/pyanaconda/core/kickstart/commands.py +@@ -24,10 +24,10 @@ + # Supported kickstart commands. + from pykickstart.commands.authconfig import F28_Authconfig as Authconfig + from pykickstart.commands.authselect import F28_Authselect as Authselect +-from pykickstart.commands.autopart import RHEL9_AutoPart as AutoPart ++from pykickstart.commands.autopart import F29_AutoPart as AutoPart + from pykickstart.commands.autostep import F34_AutoStep as AutoStep + from pykickstart.commands.bootloader import RHEL9_Bootloader as Bootloader +-from pykickstart.commands.btrfs import RHEL9_BTRFS as BTRFS ++from pykickstart.commands.btrfs import F23_BTRFS as BTRFS + from pykickstart.commands.cdrom import FC3_Cdrom as Cdrom + from pykickstart.commands.clearpart import F28_ClearPart as ClearPart + from pykickstart.commands.displaymode import F26_DisplayMode as DisplayMode +@@ -47,7 +47,7 @@ from pykickstart.commands.keyboard import F18_Keyboard as Keyboard + from pykickstart.commands.lang import F19_Lang as Lang + from pykickstart.commands.liveimg import F19_Liveimg as Liveimg + from pykickstart.commands.logging import F34_Logging as Logging +-from pykickstart.commands.logvol import RHEL9_LogVol as LogVol ++from pykickstart.commands.logvol import F29_LogVol as LogVol + from pykickstart.commands.mediacheck import FC4_MediaCheck as MediaCheck + from pykickstart.commands.method import F34_Method as Method + from pykickstart.commands.mount import F27_Mount as Mount +@@ -56,8 +56,8 @@ from pykickstart.commands.nfs import FC6_NFS as NFS + from pykickstart.commands.nvdimm import F28_Nvdimm as Nvdimm + from pykickstart.commands.ostreesetup import RHEL9_OSTreeSetup as OSTreeSetup + from pykickstart.commands.ostreecontainer import RHEL9_OSTreeContainer as OSTreeContainer +-from pykickstart.commands.partition import RHEL9_Partition as Partition +-from pykickstart.commands.raid import RHEL9_Raid as Raid ++from pykickstart.commands.partition import F34_Partition as Partition ++from pykickstart.commands.raid import F29_Raid as Raid + from pykickstart.commands.realm import F19_Realm as Realm + from pykickstart.commands.reboot import F23_Reboot as Reboot + from pykickstart.commands.repo import F33_Repo as Repo +diff --git a/pyanaconda/modules/storage/kickstart.py b/pyanaconda/modules/storage/kickstart.py +index f9cbbcb..0f33377 100644 +--- a/pyanaconda/modules/storage/kickstart.py ++++ b/pyanaconda/modules/storage/kickstart.py +@@ -105,7 +105,6 @@ class BTRFS(COMMANDS.BTRFS): + + def parse(self, args): + """Parse the command.""" +- # pylint: disable=assignment-from-no-return + retval = super().parse(args) + + # Check the file system type. +-- +2.43.0 + diff --git a/20002-Add-product-configuration-for-CentOS-Stream-Hypersc.patch b/20002-Add-product-configuration-for-CentOS-Stream-Hypersc.patch new file mode 100644 index 0000000..9c486c3 --- /dev/null +++ b/20002-Add-product-configuration-for-CentOS-Stream-Hypersc.patch @@ -0,0 +1,52 @@ +From 29c66e3f8b19ac8d6f4cc32a5a1a5a12e7c3c1fe Mon Sep 17 00:00:00 2001 +From: Neal Gompa +Date: Sat, 26 Jun 2021 08:21:49 -0400 +Subject: [PATCH 20002/20005] Add product configuration for CentOS Stream + Hyperscale variant + +This is a minimal product configuration layered on top of the +CentOS Stream Hyperscale product configuration that configures +Anaconda to use Btrfs by default. +--- + data/product.d/centos-stream-hyperscale.conf | 29 ++++++++++++++++++++ + 1 file changed, 29 insertions(+) + create mode 100644 data/product.d/centos-stream-hyperscale.conf + +diff --git a/data/product.d/centos-stream-hyperscale.conf b/data/product.d/centos-stream-hyperscale.conf +new file mode 100644 +index 0000000..88979ad +--- /dev/null ++++ b/data/product.d/centos-stream-hyperscale.conf +@@ -0,0 +1,29 @@ ++# Anaconda configuration file for CentOS Stream Hyperscale ++ ++[Product] ++product_name = CentOS Stream ++variant_name = Hyperscale ++ ++[Base Product] ++product_name = CentOS Stream ++ ++[Storage] ++default_scheme = BTRFS ++ ++[Payload] ++# RHEL removes btrfs-progs, but we want it back ++ignored_packages = ++ ntfsprogs ++ dmraid ++ ++default_rpm_gpg_keys = ++ /etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial ++ /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-HyperScale ++ /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-$releasever ++ ++updates_repositories = ++ centos-hyperscale ++ centos-hyperscale-spin ++ epel ++ epel-next ++ powertools +-- +2.43.0 + diff --git a/20003-Add-support-for-detecting-the-Hyperscale-variant-in.patch b/20003-Add-support-for-detecting-the-Hyperscale-variant-in.patch new file mode 100644 index 0000000..6df048a --- /dev/null +++ b/20003-Add-support-for-detecting-the-Hyperscale-variant-in.patch @@ -0,0 +1,39 @@ +From 887a288bb2b021571033148b5468042ce7b5b75e Mon Sep 17 00:00:00 2001 +From: Neal Gompa +Date: Sun, 27 Jun 2021 21:01:07 -0400 +Subject: [PATCH 20003/20005] Add support for detecting the Hyperscale variant + in liveinst + +Anaconda does not rely on os-release(5) data directly to determine +which product data to load, but instead needs either a /.buildstamp +file or logic to populate environment variables to have Anaconda +select the right configuration. + +This change adds logic to set the ANACONDA_PRODUCTVARIANT variable +when the Hyperscale variant is detected on the system. +--- + data/liveinst/liveinst | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/data/liveinst/liveinst b/data/liveinst/liveinst +index 5cf32ec..cc5872c 100755 +--- a/data/liveinst/liveinst ++++ b/data/liveinst/liveinst +@@ -46,6 +46,14 @@ if [ -f /etc/system-release ]; then + export ANACONDA_PRODUCTVERSION=$( cat /etc/system-release | sed -r -e 's/^.* ([0-9\.]+).*$/\1/' ) + fi + ++# set PRODUCTVARIANT if this is a CentOS Stream Hyperscale live image ++if [ -f /etc/os-release ]; then ++ variantid=$( grep VARIANT_ID /etc/os-release | tail -1 | cut -d= -f2) ++ if [ "$variantid" = "hyperscale" ]; then ++ export ANACONDA_PRODUCTVARIANT="Hyperscale" ++ fi ++fi ++ + # set PRODUCTVARIANT if this is a Fedora Workstation live image + # FIXME really, livemedia-creator should include .buildstamp in live + # images, if it did, we could remove this: +-- +2.43.0 + diff --git a/20004-Change-fedora-welcome-to-centos-welcome.patch b/20004-Change-fedora-welcome-to-centos-welcome.patch new file mode 100644 index 0000000..d50b81a --- /dev/null +++ b/20004-Change-fedora-welcome-to-centos-welcome.patch @@ -0,0 +1,132 @@ +From 869891298702227d9e6641f490dca331d193f75d Mon Sep 17 00:00:00 2001 +From: Neal Gompa +Date: Mon, 28 Jun 2021 23:26:59 -0400 +Subject: [PATCH 20004/20005] Change fedora-welcome to centos-welcome + +This is being used for CentOS Stream rather than Fedora Linux, +so adjust accordingly. +--- + data/liveinst/gnome/Makefile.am | 16 ++++++++-------- + ...ra-welcome.desktop => centos-welcome.desktop} | 4 ++-- + .../{fedora-welcome.js => centos-welcome.js} | 12 ++++++------ + 3 files changed, 16 insertions(+), 16 deletions(-) + rename data/liveinst/gnome/{fedora-welcome.desktop => centos-welcome.desktop} (59%) + rename data/liveinst/gnome/{fedora-welcome.js => centos-welcome.js} (93%) + +diff --git a/data/liveinst/gnome/Makefile.am b/data/liveinst/gnome/Makefile.am +index 4f2f90b..f7bd07a 100644 +--- a/data/liveinst/gnome/Makefile.am ++++ b/data/liveinst/gnome/Makefile.am +@@ -16,24 +16,24 @@ + # along with this program. If not, see . + + welcomedir = $(datadir)/$(PACKAGE_NAME)/gnome +-dist_welcome_DATA = fedora-welcome.desktop +-dist_welcome_SCRIPTS = fedora-welcome.js ++dist_welcome_DATA = centos-welcome.desktop ++dist_welcome_SCRIPTS = centos-welcome.js + + MAINTAINERCLEANFILES = Makefile.in + + # Merge the translations into the desktop file + # Use the merged translations in $(builddir). If no merged translations exist, + # just exit. +-# Rename fedora-welcome.js to just fedora-welcome ++# Rename centos-welcome.js to just centos-welcome + install-data-hook: + for p in $(top_builddir)/po/*.mpo ; do \ + [ -e $$p ] || exit 0 ; \ +- $(MSGFMT) --desktop --template=$(DESTDIR)$(welcomedir)/fedora-welcome.desktop \ ++ $(MSGFMT) --desktop --template=$(DESTDIR)$(welcomedir)/centos-welcome.desktop \ + --locale=$$(basename $$p .mpo) \ +- -o $(DESTDIR)$(welcomedir)/fedora-welcome.desktop.new $$p || exit 1 ; \ +- mv $(DESTDIR)$(welcomedir)/fedora-welcome.desktop.new $(DESTDIR)$(welcomedir)/fedora-welcome.desktop || exit 1 ; \ ++ -o $(DESTDIR)$(welcomedir)/centos-welcome.desktop.new $$p || exit 1 ; \ ++ mv $(DESTDIR)$(welcomedir)/centos-welcome.desktop.new $(DESTDIR)$(welcomedir)/centos-welcome.desktop || exit 1 ; \ + done +- cd $(DESTDIR)$(welcomedir) && mv fedora-welcome.js fedora-welcome ++ cd $(DESTDIR)$(welcomedir) && mv centos-welcome.js centos-welcome + + uninstall-hook: +- -cd $(DESTDIR)$(welcomedir) && rm -f fedora-welcome ++ -cd $(DESTDIR)$(welcomedir) && rm -f centos-welcome +diff --git a/data/liveinst/gnome/fedora-welcome.desktop b/data/liveinst/gnome/centos-welcome.desktop +similarity index 59% +rename from data/liveinst/gnome/fedora-welcome.desktop +rename to data/liveinst/gnome/centos-welcome.desktop +index 60e5c38..ce68d92 100644 +--- a/data/liveinst/gnome/fedora-welcome.desktop ++++ b/data/liveinst/gnome/centos-welcome.desktop +@@ -1,6 +1,6 @@ + [Desktop Entry] +-Name=Welcome to Fedora +-Exec=/usr/share/anaconda/gnome/fedora-welcome ++Name=Welcome to CentOS Stream ++Exec=/usr/share/anaconda/gnome/centos-welcome + Terminal=false + Type=Application + StartupNotify=true +diff --git a/data/liveinst/gnome/fedora-welcome.js b/data/liveinst/gnome/centos-welcome.js +similarity index 93% +rename from data/liveinst/gnome/fedora-welcome.js +rename to data/liveinst/gnome/centos-welcome.js +index 0520557..6b04106 100755 +--- a/data/liveinst/gnome/fedora-welcome.js ++++ b/data/liveinst/gnome/centos-welcome.js +@@ -62,7 +62,7 @@ const WelcomeWindow = new Lang.Class({ + default_width: 600, + default_height: 550, + skip_taskbar_hint: true, +- title: _("Welcome to Fedora"), ++ title: _("Welcome to CentOS Stream"), + window_position: Gtk.WindowPosition.CENTER }); + this.window.connect('key-press-event', Lang.bind(this, + function(w, event) { +@@ -91,7 +91,7 @@ const WelcomeWindow = new Lang.Class({ + spacing: 16 }); + tryContent.add(new Gtk.Image({ icon_name: 'media-optical', + pixel_size: 256 })); +- tryContent.add(makeLabel(_("Try Fedora"), true)); ++ tryContent.add(makeLabel(_("Try CentOS"), true)); + + let tryButton = new Gtk.Button({ child: tryContent }); + buttonBox.add(tryButton); +@@ -99,7 +99,7 @@ const WelcomeWindow = new Lang.Class({ + let installContent = new Gtk.Box({ orientation: Gtk.Orientation.VERTICAL, + spacing: 16 }); + +- // provided by the 'fedora-logos' package ++ // provided by the 'centos-logos' package + installContent.add(new Gtk.Image({ icon_name: 'org.fedoraproject.AnacondaInstaller', + pixel_size: 256 })); + installContent.add(makeLabel(anacondaApp.get_name(), true)); +@@ -107,7 +107,7 @@ const WelcomeWindow = new Lang.Class({ + let installButton = new Gtk.Button({ child: installContent }); + buttonBox.add(installButton); + +- this._label = makeLabel(_("You are currently running Fedora from live media.\nYou can install Fedora now, or choose \"Install to Hard Drive\" in the Activities Overview at any later time."), false); ++ this._label = makeLabel(_("You are currently running CentOS Stream from live media.\nYou can install CentOS Stream now, or choose \"Install to Hard Drive\" in the Activities Overview at any later time."), false); + mainGrid.add(this._label); + + installButton.connect('clicked', Lang.bind(this, +@@ -121,7 +121,7 @@ const WelcomeWindow = new Lang.Class({ + buttonBox.destroy(); + this._label.destroy(); + +- // provided by the 'fedora-logos' package ++ // provided by the 'centos-logos' package + let image = new Gtk.Image({ icon_name: 'org.fedoraproject.AnacondaInstaller', + pixel_size: 256, + halign: Gtk.Align.CENTER }); +@@ -148,7 +148,7 @@ const WelcomeWindow = new Lang.Class({ + Gettext.bindtextdomain('anaconda', LOCALE_DIR); + Gettext.textdomain('anaconda'); + +-GLib.set_prgname('fedora-welcome'); ++GLib.set_prgname('centos-welcome'); + Gtk.init(null, null); + Gtk.Settings.get_default().gtk_application_prefer_dark_theme = true; + +-- +2.43.0 + diff --git a/20005-data-product.d-centos-stream-hyperscale-Enable-expe.patch b/20005-data-product.d-centos-stream-hyperscale-Enable-expe.patch new file mode 100644 index 0000000..05025e7 --- /dev/null +++ b/20005-data-product.d-centos-stream-hyperscale-Enable-expe.patch @@ -0,0 +1,27 @@ +From 8a40396e6d9a3b4105b5a0f2a48894bf6cf9d9e8 Mon Sep 17 00:00:00 2001 +From: Neal Gompa +Date: Fri, 26 Jan 2024 14:29:10 -0500 +Subject: [PATCH 20005/20005] data/product.d/centos-stream-hyperscale: Enable + -experimental repo + +Until we have a kernel that we can ship in the main repository, +we will need the experimental repository to be considered too. +--- + data/product.d/centos-stream-hyperscale.conf | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/data/product.d/centos-stream-hyperscale.conf b/data/product.d/centos-stream-hyperscale.conf +index 88979ad..854dedc 100644 +--- a/data/product.d/centos-stream-hyperscale.conf ++++ b/data/product.d/centos-stream-hyperscale.conf +@@ -23,6 +23,7 @@ default_rpm_gpg_keys = + + updates_repositories = + centos-hyperscale ++ centos-hyperscale-experimental + centos-hyperscale-spin + epel + epel-next +-- +2.43.0 + diff --git a/anaconda.spec b/anaconda.spec index 3413cc5..794317a 100644 --- a/anaconda.spec +++ b/anaconda.spec @@ -1,7 +1,7 @@ Summary: Graphical system installer Name: anaconda Version: 34.25.4.3 -Release: 1%{?dist} +Release: 1.1%{?dist} License: GPLv2+ and MIT URL: http://fedoraproject.org/wiki/Anaconda @@ -12,6 +12,13 @@ URL: http://fedoraproject.org/wiki/Anaconda # make dist Source0: %{name}-%{version}.tar.bz2 +## Hyperscale changes +Patch20001: 20001-Revert-Remove-kickstart-btrfs-support.patch +Patch20002: 20002-Add-product-configuration-for-CentOS-Stream-Hypersc.patch +Patch20003: 20003-Add-support-for-detecting-the-Hyperscale-variant-in.patch +Patch20004: 20004-Change-fedora-welcome-to-centos-welcome.patch +Patch20005: 20005-data-product.d-centos-stream-hyperscale-Enable-expe.patch + # Versions of required components (done so we make sure the buildrequires # match the requires versions of things). @@ -44,6 +51,12 @@ Source0: %{name}-%{version}.tar.bz2 %define utillinuxver 2.15.1 %define rpmostreever 2023.2 +# Because of Patch20004, we need to regenerate autofoo +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: git-core +BuildRequires: libtool + BuildRequires: audit-libs-devel BuildRequires: libtool BuildRequires: gettext-devel >= %{gettextver} @@ -307,9 +320,15 @@ options. This includes driver disks, kickstarts, and finding the anaconda runtime on NFS/HTTP/FTP servers or local disks. %prep -%autosetup -p 1 +%autosetup -S git_am %build +# Regenerate autofoo for patches +autoreconf -fiv +pushd widgets +autoreconf -fiv +popd + # use actual build-time release number, not tarball creation time release number %configure ANACONDA_RELEASE=%{release} %{__make} %{?_smp_mflags} @@ -417,6 +436,13 @@ desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{buildroot}%{_d %{_prefix}/libexec/anaconda/dd_* %changelog +* Fri Jan 26 2024 Neal Gompa - 34.25.4.3-1.1 +- Add changes for CentOS Hyperscale spin + + Re-enable Btrfs support + + Add CentOS Stream Hyperscale config + + Debrand the liveinst welcome widget + + Add support for Hyperscale variant in liveinst + * Wed Jan 24 2024 Martin Kolman - 34.25.4.3-1 - Fix missing emit of zfcp kickstart statements (maier) Related: RHEL-11384