This ansible role is created and maintained by Media Pop, a software consultancy. Hire us to resolve your DevOps challenges.
Install other versions of python and set them as the default.
python_alternative_version: "3.6"
python_pip_version: "20.2.2"
- hosts: webservers
roles:
- role: mediapop.python
You can't use these alternative pythons with ansible always because it uses a package provided by python3-apt
. Set the ansible runtime python with ansible_python_interpreter: /usr/bin/python3.5
in the inventory or the playbook.