diff --git a/0030-fix-subprocess-check_output-method-for-backup-service-configuration.patch b/0030-fix-subprocess-check_output-method-for-backup-service-configuration.patch new file mode 100644 index 0000000000000000000000000000000000000000..4e150311db4fc728fba067653e8ee0e996065c09 --- /dev/null +++ b/0030-fix-subprocess-check_output-method-for-backup-service-configuration.patch @@ -0,0 +1,27 @@ +From 719baceb14cb08659fee61249b0be6b9f96f4b65 Mon Sep 17 00:00:00 2001 +From: wangcichen +Date: Tue, 11 Oct 2022 08:34:37 +0800 +Subject: [PATCH] + 0030-fix-subprocess-check_output-method-for-backup-service-configuration + +Signed-off-by: wangcichen +--- + .../el7toel8/actors/serviceconfigurationsynchronizer/actor.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/repos/system_upgrade/el7toel8/actors/serviceconfigurationsynchronizer/actor.py b/repos/system_upgrade/el7toel8/actors/serviceconfigurationsynchronizer/actor.py +index 7856bea..9b45d31 100644 +--- a/repos/system_upgrade/el7toel8/actors/serviceconfigurationsynchronizer/actor.py ++++ b/repos/system_upgrade/el7toel8/actors/serviceconfigurationsynchronizer/actor.py +@@ -19,7 +19,7 @@ class ServiceConfigurationSynchronizer(Actor): + def service_configuration_backup(self): + try: + self.log.info("backing up service configurations after migration.") +- services_config_raw = str(subprocess.check_output("systemctl list-unit-files | egrep 'enabled |disabled ' | awk '{print $1,$2}'")).strip() ++ services_config_raw = str(subprocess.check_output("systemctl list-unit-files | egrep 'enabled |disabled ' | awk '{print $1,$2}'", shell=True)).strip() + services_config = { + line.strip().split()[0]: line.strip().split()[1][:-1] + for line in services_config_raw.split('\n') +-- +2.22.0 + diff --git a/leapp-repository.spec b/leapp-repository.spec index a1cbe4b39732208dbe6480f00c1dbe06936cc088..b0e58985497ff6c6e1a2857d62321180b48037b5 100644 --- a/leapp-repository.spec +++ b/leapp-repository.spec @@ -55,6 +55,7 @@ Patch26: 0026-Add-checkbaota-actor.patch Patch27: 0027-upgrade-write-efi-vars-for-ecs-firmware.patch Patch28: 0028-add-disablerepo-option-to-upgrade-kernel-to-RHCK.patch Patch29: 0029-Service-configuration-remains-after-migration.patch +Patch30: 0030-fix-subprocess-check_output-method-for-backup-service-configuration.patch BuildArch: noarch BuildRequires: python-devel