update to a single task

This commit is contained in:
Michael Porter 2018-09-10 09:32:42 -05:00
parent 4dcb2b5ecf
commit cffcf33bd2
No known key found for this signature in database
GPG Key ID: 5471D27291D993FA

View File

@ -10,19 +10,8 @@
version: "{{ item.version | default(omit) }}"
virtualenv: "{{ item.virtualenv | default(omit) }}"
state: "{{ item.state | default(omit) }}"
executable: {{ 'pip3' if pip_package == "python3-pip" else 'pip' }}
with_items: "{{ pip_install_packages }}"
when: pip_package != "python3-pip"
- name: Ensure pip_install_packages are installed.
pip:
name: "{{ item.name | default(item) }}"
version: "{{ item.version | default(omit) }}"
virtualenv: "{{ item.virtualenv | default(omit) }}"
state: "{{ item.state | default(omit) }}"
executable: pip3
with_items: "{{ pip_install_packages }}"
when: pip_package == "python3-pip"