From 3d2d8bcf5cff165980b8267928de59a04c1de52a Mon Sep 17 00:00:00 2001 From: Thierry Parmentelat Date: Fri, 25 May 2018 12:30:19 +0200 Subject: [PATCH] when start/stopping services on f>=14, need a patch that was originally available for f14 only --- system/TestPlc.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/system/TestPlc.py b/system/TestPlc.py index 4e90d13..b6f211f 100644 --- a/system/TestPlc.py +++ b/system/TestPlc.py @@ -798,8 +798,13 @@ class TestPlc: return self.start_stop_service(service, 'stop') def start_stop_service(self, service, start_or_stop): - "utility to start/stop a service with the special trick for f14" - if self.options.fcdistro != 'f14': + "utility to start/stop a service with the special trick starting with f14" + has_systemctl = False + if self.options.fcdistro[0] == 'f': + number = int(self.options.fcdistro[1:]) + if number >= 14: + has_systemctl = True + if not has_systemctl: return self.run_in_guest("service {} {}".format(service, start_or_stop)) == 0 else: # patch /sbin/service so it does not reset environment -- 2.43.0