Use apt_repository update_cache feature
With ansible 2.2, apt_repository update_cache feature has been fixed. When a new repo will be added, apt-get update will be run after the addition if update_cache is set to yes. This combined with the apt module now properly checking the cache validity, we can now have proper updating of the cache with registering variables. Change-Id: Ic9788156a88223dc0d27fafa2a798f396135f990
This commit is contained in:
parent
ff9002ba36
commit
03c48e2357
@ -53,6 +53,7 @@
|
||||
apt_repository:
|
||||
repo: "deb https://packagecloud.io/grafana/stable/debian/ wheezy main"
|
||||
state: "present"
|
||||
update_cache: yes
|
||||
- name: Install grafana
|
||||
apt:
|
||||
pkg: "grafana"
|
||||
|
@ -34,6 +34,7 @@
|
||||
apt_repository:
|
||||
repo: "deb https://repos.influxdata.com/{{ ansible_distribution | lower }} {{ ansible_distribution_release }} stable"
|
||||
state: "present"
|
||||
update_cache: yes
|
||||
- name: Install influxdb
|
||||
apt:
|
||||
pkg: "influxdb"
|
||||
|
@ -26,6 +26,7 @@
|
||||
apt_repository:
|
||||
repo: "deb https://repos.influxdata.com/{{ ansible_distribution | lower }} {{ ansible_distribution_release }} stable"
|
||||
state: "present"
|
||||
update_cache: yes
|
||||
- name: Install telegraf
|
||||
apt:
|
||||
pkg: "telegraf"
|
||||
|
@ -22,6 +22,7 @@
|
||||
apt_repository:
|
||||
repo: "deb https://repos.influxdata.com/{{ ansible_distribution | lower }} {{ ansible_distribution_release }} stable"
|
||||
state: "present"
|
||||
update_cache: yes
|
||||
- name: Install kapacitor
|
||||
apt:
|
||||
pkg: "kapacitor"
|
||||
|
Loading…
Reference in New Issue
Block a user