54 lines
2.0 KiB
Diff
54 lines
2.0 KiB
Diff
From f78b7e0b27da49e3465425e24eacf4e92594cba4 Mon Sep 17 00:00:00 2001
|
|
From: Will Woods <wwoods@redhat.com>
|
|
Date: Tue, 13 Nov 2012 01:33:16 -0500
|
|
Subject: [PATCH 3/6] build fedup upgrade.img
|
|
|
|
Use rebuild_initrds() with prefix='upgrade' to build upgrade.img with
|
|
the fedup "system-upgrade" module(s) inside.
|
|
---
|
|
share/runtime-install.tmpl | 3 +++
|
|
src/pylorax/__init__.py | 13 ++++++++++---
|
|
2 files changed, 13 insertions(+), 3 deletions(-)
|
|
|
|
diff --git a/share/runtime-install.tmpl b/share/runtime-install.tmpl
|
|
index 72fc34a..68a7545 100644
|
|
--- a/share/runtime-install.tmpl
|
|
+++ b/share/runtime-install.tmpl
|
|
@@ -48,6 +48,9 @@ installpkg plymouth
|
|
## extra dracut modules
|
|
installpkg dracut-network anaconda-dracut
|
|
|
|
+## fedup-dracut handles upgrades
|
|
+installpkg fedup-dracut fedup-dracut-plymouth *-fedup-dracut
|
|
+
|
|
## rpcbind or portmap needed by dracut nfs module
|
|
installpkg rpcbind
|
|
|
|
diff --git a/src/pylorax/__init__.py b/src/pylorax/__init__.py
|
|
index 6120dc3..20a84c3 100644
|
|
--- a/src/pylorax/__init__.py
|
|
+++ b/src/pylorax/__init__.py
|
|
@@ -278,9 +278,16 @@ class Lorax(BaseLoraxClass):
|
|
domacboot=domacboot, templatedir=templatedir)
|
|
|
|
logger.info("rebuilding initramfs images")
|
|
- dracut_args=["--xz", "--add", "anaconda pollcdrom",
|
|
- "--install", "/.buildstamp"]
|
|
- treebuilder.rebuild_initrds(add_args=dracut_args)
|
|
+ dracut_args = ["--xz", "--install", "/.buildstamp"]
|
|
+
|
|
+ anaconda_args = dracut_args + ["--add", "anaconda pollcdrom"]
|
|
+ treebuilder.rebuild_initrds(add_args=anaconda_args)
|
|
+
|
|
+ # Build upgrade.img. It'd be nice if these could coexist in the same
|
|
+ # image, but that would increase the size of the anaconda initramfs,
|
|
+ # which worries some people (esp. PPC tftpboot). So they're separate.
|
|
+ upgrade_args = dracut_args + ["--add", "system-upgrade"]
|
|
+ treebuilder.rebuild_initrds(add_args=upgrade_args, prefix="upgrade")
|
|
|
|
logger.info("populating output tree and building boot images")
|
|
treebuilder.build()
|
|
--
|
|
1.8.0
|
|
|