Use apt Ansible module instead of apt-get to update cache

Ansible recommends to use apt module instead of apt-get.
This patch fixes install.yml and pre-install.yml accordingly.

Change-Id: I3241ce332e7cf522786e78280643440a30a23875
Closes-Bug: #1747436
This commit is contained in:
David Rabel 2018-02-05 15:38:17 +01:00
parent 70a5099376
commit 12e0c5ae8e
2 changed files with 4 additions and 2 deletions

View File

@ -1,6 +1,7 @@
--- ---
- name: Update apt cache - name: Update apt cache
command: apt-get update apt:
update_cache: yes
become: True become: True
when: ansible_os_family == 'Debian' when: ansible_os_family == 'Debian'

View File

@ -73,7 +73,8 @@
when: create_kolla_user | bool when: create_kolla_user | bool
- name: Install apt packages - name: Install apt packages
command: apt-get update apt:
update_cache: yes
become: True become: True
when: ansible_os_family == 'Debian' when: ansible_os_family == 'Debian'