Problem:
Salt is deprecating Python 2.7 in less than 6 months. They are offering a version running on Python 3.
Installing salt-master with the Python 3 however breaks foreman-node
Expected outcome:
Calling foreman-node work
Foreman and Proxy versions:
foreman-proxy: 1.22.0-1.el7
salt-master: 2019.2.0-1.el7
rubygem-smart_proxy_salt: 2.1.9-1.el7
Foreman and Proxy plugin versions:
Other relevant data:
The following error is printed in the log.
[ERROR ][5036] Command '['/usr/bin/foreman-node', 'pminion1.example.com']' failed with return code: 1
[ERROR ][5036] stdout: Could not get grains: No grains received from Salt master
[ERROR ][5036] retcode: 1
[ERROR ][5036] Command '/usr/bin/foreman-node pminion1.example.com' failed with return code: 1
[ERROR ][5036] output: Could not get grains: No grains received from Salt master
[CRITICAL][5036] YAML data from /usr/bin/foreman-node failed to parse
foreman-node calls /usr/share/gems/gems/smart_proxy_salt-2.1.9/bin/foreman-node which itself call python by piping a script. Calling that script outputs this error:
Traceback (most recent call last):
File "t.py", line 6, in <module>
import salt.config
ImportError: No module named salt.config
Reverting back to the Python 2.7 installation, the setup work anew.