From 388c9a082697d1c736ad74d983671a85699c133d Mon Sep 17 00:00:00 2001
From: wangdi <wangdi@kylinos.cn>
Date: Tue, 14 Mar 2023 10:12:57 +0800
Subject: [PATCH] fix host installation failure

---
 .../project/roles/ovirt-host-deploy-facts/tasks/host-os.yml    | 2 +-
 .../plugins/ovirt-engine-setup/ovirt-engine/apache/runner.py   | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/packaging/ansible-runner-service-project/project/roles/ovirt-host-deploy-facts/tasks/host-os.yml b/packaging/ansible-runner-service-project/project/roles/ovirt-host-deploy-facts/tasks/host-os.yml
index ef92743..f45415a 100644
--- a/packaging/ansible-runner-service-project/project/roles/ovirt-host-deploy-facts/tasks/host-os.yml
+++ b/packaging/ansible-runner-service-project/project/roles/ovirt-host-deploy-facts/tasks/host-os.yml
@@ -10,7 +10,7 @@
 
 - name: Check if system is OpenEuler
   set_fact:
-    ansible_python_interpreter: "{{ 'usr/bin/python3' }}"
+    ansible_python_interpreter: "{{ '/usr/bin/python3' }}"
   when:
     ansible_distribution == 'openEuler'
 
diff --git a/packaging/setup/plugins/ovirt-engine-setup/ovirt-engine/apache/runner.py b/packaging/setup/plugins/ovirt-engine-setup/ovirt-engine/apache/runner.py
index 8a8be55..2b3c3a1 100644
--- a/packaging/setup/plugins/ovirt-engine-setup/ovirt-engine/apache/runner.py
+++ b/packaging/setup/plugins/ovirt-engine-setup/ovirt-engine/apache/runner.py
@@ -82,10 +82,11 @@ class Plugin(plugin.PluginBase):
                 ),
                 content=textwrap.dedent('''
                 Listen {port}
+                WSGIRestrictEmbedded On
                 <VirtualHost _default_:{port}>
                   WSGIDaemonProcess runner user={user} group={group} threads=4
                   WSGIProcessGroup runner
-                  WSGIScriptAlias / {runner_wsgi_file}
+                  WSGIScriptAlias / {runner_wsgi_file} process-group=runner application-group=%{{GLOBAL}}
                 </VirtualHost>
                 ''').format(
                     runner_wsgi_file=runner_wsgi_file,
-- 
2.39.1

