forked from ISTI-ansible-roles/ansible-roles
python-env role: Add a task that permits to install specific versions of pip packages.
This commit is contained in:
parent
b6e4b89965
commit
9a779358c4
|
@ -12,20 +12,6 @@
|
|||
apt: name={{ item }} state={{ py_env_pkgs_state }} update_cache=yes cache_valid_time=600
|
||||
with_items: '{{ py_pip_deps | default([]) }}'
|
||||
|
||||
- name: Fix the ssl warnings installing some ssl libraries
|
||||
pip: name={{ item }}
|
||||
with_items: '{{ py_env_pip_fix_ssl_warnings | default ([]) }}'
|
||||
when:
|
||||
- not py_env_trusty_workaround
|
||||
- is_trusty
|
||||
|
||||
- name: Install a list of pip packages
|
||||
pip: name={{ item }}
|
||||
with_items: '{{ py_env_pip_pkgs | default ([]) }}'
|
||||
when:
|
||||
- not py_env_trusty_workaround
|
||||
- is_trusty
|
||||
|
||||
when: py_env_install
|
||||
tags: [ "python", "py_env" ]
|
||||
|
||||
|
@ -51,6 +37,13 @@
|
|||
- name: Install setuptools version 33.1.1
|
||||
pip: name=setuptools version=33.1.1 state=present
|
||||
|
||||
when:
|
||||
- py_env_trusty_workaround
|
||||
- py_env_install
|
||||
- is_trusty
|
||||
tags: [ "python", "py_env" ]
|
||||
|
||||
- block:
|
||||
- name: Fix the ssl warnings installing some ssl libraries
|
||||
pip: name={{ item }}
|
||||
with_items: '{{ py_env_pip_fix_ssl_warnings | default ([]) }}'
|
||||
|
@ -59,8 +52,9 @@
|
|||
pip: name={{ item }}
|
||||
with_items: '{{ py_env_pip_pkgs | default ([]) }}'
|
||||
|
||||
when:
|
||||
- py_env_trusty_workaround
|
||||
- py_env_install
|
||||
- is_trusty
|
||||
tags: [ "python", "py_env" ]
|
||||
- name: Install a list of versioned pip packages
|
||||
pip: name={{ item.pkg }} version={{ item.version }}
|
||||
with_items: '{{ py_env_versioned_pip_pkgs | default ([]) }}'
|
||||
|
||||
when: py_env_install
|
||||
tags: [ "python", "py_env", "py_env_pkgs" ]
|
||||
|
|
Loading…
Reference in New Issue