Update/Upgrade ansible in semaphore
Hi guys i don't know if this was already ask because i can't managed to find any answer here. I tried to update ansible in the semaphore docker container. It works. I've these both cli commands:
apk add --update --no-cache ansible
python3 -m pip install --upgrade --user ansible
Ansible is now 2.13.
ansible [core 2.13.3]
config file = /etc/ansible/ansible.cfg
configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /root/.local/lib/python3.8/site-packages/ansible
ansible collection location = /root/.ansible/collections
executable location = /usr/bin/ansible
python version = 3.8.10 (default, May 6 2021, 00:05:59) [GCC 10.2.1 20201203]
jinja version = 3.1.2
libyaml = True
But for any reason semaphore and the TaskRunner takes the default version 2.10 and everything failed in my playbooks.
[WARNING]: Collection community.general does not support Ansible version 2.10.5
I haven't set any specific versions and doesn't force anything. What iam doing wrong? Any help?
I am not sure, but under what user are you executing the pip update? According to the output, I assume root:
ansible collection location = /root/.ansible/collections
Semaphore is running with user semaphore so you'd need to run the pip3 install under that user.
But anyhow, I am also waiting for Semaphore to support Ansible updates, as we develop our roles with later versions.
Thanks for the reply. Indeed i use root. This solves my problem. Thank you.