From f0803cb1b11ac5f4c8bd30d0dea8ceccb7a72602 Mon Sep 17 00:00:00 2001 From: Trygve Laugstøl Date: Wed, 18 Aug 2021 19:25:20 +0200 Subject: apt-repos --- ansible/roles/apt-repos/tasks/main.yml | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'ansible/roles/apt-repos/tasks/main.yml') diff --git a/ansible/roles/apt-repos/tasks/main.yml b/ansible/roles/apt-repos/tasks/main.yml index 2789073..96ffd7d 100644 --- a/ansible/roles/apt-repos/tasks/main.yml +++ b/ansible/roles/apt-repos/tasks/main.yml @@ -1,3 +1,16 @@ +- with_dict: "{{ apt_repos if apt_repos is defined else {} }}" + name: apt-key adv --recv-keys + shell: apt-key adv --recv-keys {{ item.value.key_id|default("") }} + become: yes +# debug: +# msg: apt-key adv --recv-keys {{ item.value.key_id|default("") }} + vars: + state: "{{ item.value.state | default('present') }}" + when: + - apt_repos_refresh_keys | default(false) + - item.value.key_id + ignore_errors: true + - with_dict: "{{ apt_repos if apt_repos is defined else {} }}" include_tasks: repo.yml vars: -- cgit v1.2.3