Update cache only once

This commit is contained in:
Alex 2020-05-31 11:52:38 +02:00
parent 9c31de8561
commit 0d63d9c45f
Signed by: caskd
GPG Key ID: F92BA85F61F4C173

View File

@ -13,13 +13,16 @@
tags:
- apt
when: (apt.repos| default([])) | length
- name: Update cache
apt:
update_cache: true
tags: apt
- name: Install packages
loop: "{{ apt.packages }}"
apt:
install_recommends: no
name: "{{ item.package }}"
state: "{{ item.state }}"
cache_valid_time: 3600
tags:
- packages
- apt