kdump-anaconda-addon/replace-getSysroot.patch
2021-08-07 10:31:04 +08:00

31 lines
1.2 KiB
Diff

From 758589858d45f8c81c37cf484ba6e3f606257fd9 Mon Sep 17 00:00:00 2001
From: Vendula Poncova <vponcova@redhat.com>
Date: Thu, 11 Jul 2019 17:43:10 +0200
Subject: [PATCH] Replace getSysroot
Use conf.target.system_root instead of the function getSysroot to
get the path to the system root. The function getSysroot will be
removed.
---
com_redhat_kdump/ks/kdump.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/com_redhat_kdump/ks/kdump.py b/com_redhat_kdump/ks/kdump.py
index 53878b9..0adb5e5 100644
--- a/com_redhat_kdump/ks/kdump.py
+++ b/com_redhat_kdump/ks/kdump.py
@@ -22,6 +22,7 @@
import os.path
from pyanaconda.addons import AddonData
from pyanaconda.core import util
+from pyanaconda.core.configuration.anaconda import conf
from pyanaconda.flags import flags
from pyanaconda.modules.common.constants.services import STORAGE
from pyanaconda.modules.common.constants.objects import BOOTLOADER
@@ -143,4 +144,4 @@ def execute(self, storage, ksdata, users, payload):
action = "enable"
- util.execWithRedirect("systemctl", [action, "kdump.service"], root=util.getSysroot())
+ util.execWithRedirect("systemctl", [action, "kdump.service"], root=conf.target.system_root)