From 073104b00feef71e4ed5564773b0cbd6d69a834d Mon Sep 17 00:00:00 2001 From: Robin Sonnabend <robin@fsmpi.rwth-aachen.de> Date: Sun, 19 Mar 2017 22:43:36 +0100 Subject: [PATCH] Use zabbix from debian in stretch --- zabbix-repo/tasks/main.yml | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/zabbix-repo/tasks/main.yml b/zabbix-repo/tasks/main.yml index 127db4b..cd2e6fc 100644 --- a/zabbix-repo/tasks/main.yml +++ b/zabbix-repo/tasks/main.yml @@ -4,7 +4,7 @@ # TODO place file # see: https://repo.zabbix.com/zabbix-official-repo.key - name: ensure apt got the key to verify the zabbix repo - apt_key: data="{{ lookup('file', 'zabbix.gpg') }}" state=present + apt_key: data="{{lookup('file', 'zabbix.gpg')}}" state=present notify: - update apt cache tags: @@ -15,8 +15,21 @@ - name: ensure apt knows about the zabbix repo apt_repository: repo={{ item }} state=present with_items: - - 'deb http://repo.zabbix.com/zabbix/3.0/debian {{debian_version}} main' - - 'deb-src http://repo.zabbix.com/zabbix/3.0/debian {{debian_version}} main' + - 'deb http://repo.zabbix.com/zabbix/3.0/debian jessie main' + - 'deb-src http://repo.zabbix.com/zabbix/3.0/debian jessie main' + when: debian_version == "jessie" + notify: + - update apt cache + tags: + - packages + - repos + - zabbix + +- name: ensure we use zabbix from debian + file: + name: /etc/apt/sources.list.d/repo_zabbix_com_zabbix_3_0_debian.list + state: absent + when: debian_version == "stretch" notify: - update apt cache tags: @@ -27,7 +40,7 @@ - meta: flush_handlers - name: ensure chr's key is present - apt_key: data="{{ lookup('file', 'chr.gpg') }}" state=present + apt_key: data="{{lookup('file', 'chr.gpg')}}" state=present tags: - packages - repos -- GitLab