From 03f73112ec29c6c1e5c898c38b57dae76992bbf9 Mon Sep 17 00:00:00 2001 From: Chris Lumens Date: Mon, 23 Sep 2013 13:13:11 -0400 Subject: [PATCH 15/20] Only fail on a missing firewalld command if the firewall is enabled. If the user gives firewall --disabled and their package set does not include the firewalld package, we should not raise an error. The firewall will be disabled on the target system due to the lack of firewalld. Resolves: rhbz#1113535 Port of rpmostreepayload patches from master commit a1f1d2248ca8e1b6c4e0437aeff9f7cc165e785e --- pyanaconda/kickstart.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pyanaconda/kickstart.py b/pyanaconda/kickstart.py index 92a406a..cb3de8b 100644 --- a/pyanaconda/kickstart.py +++ b/pyanaconda/kickstart.py @@ -582,8 +582,9 @@ class Firewall(commands.firewall.F20_Firewall): cmd = "/usr/bin/firewall-offline-cmd" if not os.path.exists(iutil.getSysroot()+cmd): - msg = _("%s is missing. Cannot setup firewall.") % (cmd,) - raise KickstartError(msg) + if self.enabled: + msg = _("%s is missing. Cannot setup firewall.") % (cmd,) + raise KickstartError(msg) else: iutil.execInSysroot(cmd, args) -- 1.9.3