[stable-2.7] Use virtualenv in pip test to remove distribute.
(cherry picked from commit 6f29eafef4
)
Co-authored-by: Matt Clay <matt@mystile.com>
This commit is contained in:
parent
cee7642188
commit
f1b6f5d204
1 changed files with 12 additions and 0 deletions
|
@ -501,10 +501,22 @@
|
||||||
state: absent
|
state: absent
|
||||||
|
|
||||||
# https://github.com/ansible/ansible/issues/47198
|
# https://github.com/ansible/ansible/issues/47198
|
||||||
|
- name: make sure the virtualenv does not exist
|
||||||
|
file:
|
||||||
|
state: absent
|
||||||
|
name: "{{ output_dir }}/pipenv"
|
||||||
|
|
||||||
|
- name: install distribute in the virtualenv
|
||||||
|
pip:
|
||||||
|
name: distribute
|
||||||
|
virtualenv: "{{ output_dir }}/pipenv"
|
||||||
|
state: present
|
||||||
|
|
||||||
- name: try to remove distribute
|
- name: try to remove distribute
|
||||||
pip:
|
pip:
|
||||||
state: "absent"
|
state: "absent"
|
||||||
name: "distribute"
|
name: "distribute"
|
||||||
|
virtualenv: "{{ output_dir }}/pipenv"
|
||||||
ignore_errors: yes
|
ignore_errors: yes
|
||||||
register: remove_distribute
|
register: remove_distribute
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue