I am trying to get ansible 2.9 setup and configured on my Raspberry Pi 4 (Raspberry Pi OS 64bit) If I run ansible --version as a normal user, I get this:
ansible --version
ansible [core 2.11.4]
config file = /etc/ansible/ansible.cfg
configured module search path = ['/home/stan/.ansible/plugins/modules', /usr/share/ansible/plugins/modules']
ansible python module location = /home/stan/.local/lib/python3.7/site-packages/ansible
ansible collection location = /home/stan/.ansible/collections:/usr/share/ansible/collections
executable location = /usr/local/bin/ansible
python version = 3.7.3 (default, Jan 22 2021, 20:04:44) [GCC 8.3.0]
jinja version = 2.10
libyaml = True
But when I run the same command as root, I get this:
ansible --version
ansible 2.9.25.post0
config file = /etc/ansible/ansible.cfg
configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /usr/local/lib/python3.7/dist-packages/ansible
executable location = /usr/local/bin/ansible
python version = 3.7.3 (default, Jan 22 2021, 20:04:44) [GCC 8.3.0]
BTW: Stackoverflow forced be to format the above as code, but it is not code, it is command output.
Why do I get two different results depending on what user is running the command? The bigger questions which version is installed 2.9.25 (root) or 2.11.4 (user)?