Ansible Role python
This role installs Python 2 or Python 3 on the system, optionally with additional modules.
Optional Role Variables
Variable |
Description |
Default Value |
---|---|---|
|
List of dictionaries containing additional Python modules that should be installed via the OS package manager on Linux, or via pip on Windows. Subkeys:
For the usage in host_vars / group_vars (can only be used in one group at a time). |
|
|
The Python version to install. Possible options for Linux: |
|
Example:
# optional
python__modules__host_var:
- name: 'python3-psutil'
state: 'absent'
- name: 'python3-requests'
state: 'present'
python__modules__group_var: []
python__version: 3