Hi fellows,
I tried my first steps with ansible folowing to this manual:
https://dokuwiki.nausch.org/doku.php/centos:ansible:first
When I try ro rn this: ansible rhel8 -m shell -a “/usr/bin/ls -alF /root/”
I get: File “/usr/bin/ansible”, line 60, in
import ansible.constants as C
File “/usr/lib/python3.6/site-packages/ansible/constants.py”, line 19, in
from ansible.config.manager import ConfigManager, ensure_type, get_ini_config_value
File “/usr/lib/python3.6/site-packages/ansible/config/manager.py”, line 34, in
from ansible.inventory.data import InventoryData
File “/usr/lib/python3.6/site-packages/ansible/inventory/data.py”, line 26, in
from ansible.inventory.group import Group
File “/usr/lib/python3.6/site-packages/ansible/inventory/group.py”, line 26, in
from ansible.utils.display import Display
File “/usr/lib/python3.6/site-packages/ansible/utils/display.py”, line 40, in
from ansible.utils.color import stringc
File “/usr/lib/python3.6/site-packages/ansible/utils/color.py”, line 26, in
if C.ANSIBLE_NOCOLOR:
AttributeError: module ‘ansible.constants’ has no attribute ‘ANSIBLE_NOCOLOR’
My host.yml and /etc/ansible/hosts you can see here**: https://pastebin.com/SqvMW4ca**
How can I fix this?
Many thanks in advance
Igor