From e0169f8915e6a39f7c865eacd238295da2eeaa28 Mon Sep 17 00:00:00 2001 From: Salt Date: Tue, 16 Jun 2020 08:58:38 -0500 Subject: [PATCH] Add Zerotier to the list of things to do for desktops --- roles/desktop/tasks/main.yml | 2 ++ roles/desktop/tasks/mopidy.yml | 1 + roles/desktop/tasks/zerotier.yml | 23 +++++++++++++++++++++++ 3 files changed, 26 insertions(+) create mode 100644 roles/desktop/tasks/zerotier.yml diff --git a/roles/desktop/tasks/main.yml b/roles/desktop/tasks/main.yml index f0aa537..7597dd7 100644 --- a/roles/desktop/tasks/main.yml +++ b/roles/desktop/tasks/main.yml @@ -40,6 +40,8 @@ include_tasks: packages.yml - name: Configure Mopidy include_tasks: mopidy.yml + - name: Configure Zerotier + include_tasks: zerotier.yml - name: Stop services systemd: name: "{{ item }}" diff --git a/roles/desktop/tasks/mopidy.yml b/roles/desktop/tasks/mopidy.yml index c90cc60..b45973f 100644 --- a/roles/desktop/tasks/mopidy.yml +++ b/roles/desktop/tasks/mopidy.yml @@ -16,6 +16,7 @@ - name: Update APT cache apt: update_cache: yes + cache_valid_time: 86400 - name: Install packages apt: name: diff --git a/roles/desktop/tasks/zerotier.yml b/roles/desktop/tasks/zerotier.yml new file mode 100644 index 0000000..7cd4321 --- /dev/null +++ b/roles/desktop/tasks/zerotier.yml @@ -0,0 +1,23 @@ +#!/usr/bin/ansible-playbook +# vim:ft=ansible: +--- +- name: Configure system packages + block: + - name: Add zerotier repo key + apt_key: + url: "https://raw.githubusercontent.com/zerotier/ZeroTierOne/master/doc/contact%40zerotier.com.gpg" + - name: Add repos + apt_repository: + repo: "{{ item }}" + loop: + # These repos work for Buster and >=19.10 + - "deb http://download.zerotier.com/debian/buster buster main" + - name: Update APT cache + apt: + update_cache: yes + cache_valid_time: 86400 + - name: Install packages + apt: + name: + - zerotier-one + become: yes