[anaconda][rhel7-branch/master/f23-branch][PATCH] Run systemctl only once for Initial setup services (#1252444)

Martin Kolman mkolman at redhat.com
Thu Sep 3 14:55:28 UTC 2015


We already call systemctl with a list of all installed Initial Setup services,
so there is no need to call it multiple times.

Related: rhbz#1252444
Signed-off-by: Martin Kolman <mkolman at redhat.com>
---
 pyanaconda/kickstart.py | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/pyanaconda/kickstart.py b/pyanaconda/kickstart.py
index e21242f..13dc93a 100644
--- a/pyanaconda/kickstart.py
+++ b/pyanaconda/kickstart.py
@@ -708,9 +708,8 @@ class Firstboot(commands.firstboot.FC3_Firstboot):
         if self.firstboot == FIRSTBOOT_SKIP:
             action = "disable"
 
-        for service in services:
-            # enable/disable all installed Initial Setup services
-            iutil.execInSysroot("systemctl", [action] + services)
+        # enable/disable all installed Initial Setup services
+        iutil.execInSysroot("systemctl", [action] + services)
 
 class Group(commands.group.F12_Group):
     def execute(self, storage, ksdata, instClass, users):
-- 
2.4.3



More information about the anaconda-patches mailing list