Closed filiy closed 3 years ago
A co-worker found the fix for running this playbook on RHEL7.
pip install six requests
'pywin32; sys_platform == "win32"'
line.python2 setup.py install
For some reason python3-dnf is not available on RHEL7, so it fallbacks to python 2.7 to install.
When the running the
static_ips_ova.yml
playbook on a RHEL 7.9 vm using Ansible 2.9 & python2 this error.Looking at https://pypi.org/project/pyvmomi/ I can see python2 is deprecated.
So from the RHEL 7.9 VM python3 is installed. And
yum remove ansible
is run. Then ansible is installed with python3pip3 install ansible
.ansible_python_interpreter: /usr/bin/python3
is added to the inventory file and thestatic_ips_ova.yml
playbook is run again. Things get further but I'm stuck at this error.Seems like something with the ansible
vmware_guest
module and thecustomvalues
options. https://github.com/RedHatOfficial/ocp4-vsphere-upi-automation/blob/master/roles/static_ips_ova/tasks/main.yml#L71If we run the same playbook with the same variables on a RHEL 8.4 VM things work fine.
I'm thinking something to do with pyvmomi and python modules.
Any idea what could be the issue? Should this be working from RHEL 7.9? Maybe call out in the README if this is only tested or known to be working on RHEL 8?
Thanks!