install_pip role – Install additional python packages to /usr/local

Note

This role is part of the ufrmath.computer_labs collection (version 1.0.0).

To install it use: ansible-galaxy collection install git+https://github.com/guillod/computer_labs.

To use it in a playbook, specify: ufrmath.computer_labs.install_pip.

Entry point main – Install additional python packages to /usr/local

Synopsis

  • Install pip through apt;

  • List and purge all Python packages installed in /usr/local (except pip) if purge is yes;

  • Upgrade pip if upgrade is yes;

  • Install all packages listed in packages in /usr/local with pip, with option --upgrade --ignore-installed if upgrade is yes;

  • Run additional hooks if a tasks file pkg.yml exists and pkg is listed in packages.

Parameters

Parameter

Comments

packages

list / elements=string / required

list of packages to install (use pip version specification)

purge

boolean

purge all packages installed in /usr/local

Choices:

  • false ← (default)

  • true

upgrade

boolean

upgrade listed packages if already installed

Choices:

  • false ← (default)

  • true