[DEPRECATION WARNING]: Invoking "pip" only once while using a loop via squash_actions is deprecated. Instead of using a loop to supply
multiple items and specifying `name: "{{ item }}"`, please use `name: '{{ pip_pkgs }}'` and remove the loop. This feature will be
removed in version 2.11. Deprecation warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
I was trying to install the Python Packages suing the with_items with Ansible-2.8 version, but as per the above this feature will be deprecatated from Ansible-2.11.
- name: "Ansible PIP {{ state }}: {{ pip_pkgs }}"
become: yes
pip:
name: "{{ item }}"
state: "{{ state }}"
with_items: "{{ pip_pkgs }}"
later, I have updated the code like below and after the changes "DEPRECATION WARNING" not showed in execution.
- name: "Ansible PIP {{ state }}: {{ pip_pkgs }}"
become: yes
pip:
name: "{{ pip_pkgs }}"
state: "{{ state }}"
multiple items and specifying `name: "{{ item }}"`, please use `name: '{{ pip_pkgs }}'` and remove the loop. This feature will be
removed in version 2.11. Deprecation warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
I was trying to install the Python Packages suing the with_items with Ansible-2.8 version, but as per the above this feature will be deprecatated from Ansible-2.11.
- name: "Ansible PIP {{ state }}: {{ pip_pkgs }}"
become: yes
pip:
name: "{{ item }}"
state: "{{ state }}"
with_items: "{{ pip_pkgs }}"
later, I have updated the code like below and after the changes "DEPRECATION WARNING" not showed in execution.
- name: "Ansible PIP {{ state }}: {{ pip_pkgs }}"
become: yes
pip:
name: "{{ pip_pkgs }}"
state: "{{ state }}"
No comments:
Post a Comment