65598582f5
OBS-URL: https://build.opensuse.org/package/show/systemsmanagement:saltstack/salt?expand=0&rev=179
33 lines
1.2 KiB
Diff
33 lines
1.2 KiB
Diff
From a6e490d8cede6e66bb5f22f314e1ec4e898dfa3c Mon Sep 17 00:00:00 2001
|
|
From: Can Bulut Bayburt <1103552+cbbayburt@users.noreply.github.com>
|
|
Date: Wed, 4 Dec 2019 15:59:46 +0100
|
|
Subject: [PATCH] Let salt-ssh use 'platform-python' binary in RHEL8
|
|
(#191)
|
|
|
|
RHEL/CentOS 8 has an internal Python interpreter called 'platform-python'
|
|
included in the base setup.
|
|
|
|
Add this binary to the list of Python executables to look for when
|
|
creating the sh shim.
|
|
---
|
|
salt/client/ssh/__init__.py | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/salt/client/ssh/__init__.py b/salt/client/ssh/__init__.py
|
|
index 287d0b8c4c..ef9eb0c07e 100644
|
|
--- a/salt/client/ssh/__init__.py
|
|
+++ b/salt/client/ssh/__init__.py
|
|
@@ -147,7 +147,7 @@ elif [ "$SUDO" ] && [ -n "$SUDO_USER" ]
|
|
then SUDO="sudo "
|
|
fi
|
|
EX_PYTHON_INVALID={EX_THIN_PYTHON_INVALID}
|
|
-PYTHON_CMDS="python3 python27 python2.7 python26 python2.6 python2 python"
|
|
+PYTHON_CMDS="python3 /usr/libexec/platform-python python27 python2.7 python26 python2.6 python2 python"
|
|
for py_cmd in $PYTHON_CMDS
|
|
do
|
|
if command -v "$py_cmd" >/dev/null 2>&1 && "$py_cmd" -c "import sys; sys.exit(not (sys.version_info >= (2, 6)));"
|
|
--
|
|
2.29.2
|
|
|
|
|