Support Ubuntu 20.04 (#52)
* update Ansible Galaxy meta info (added Ubunut Focal Fossa / Debian Buster) * update CHANGELOG (Ubuntu 20.04 support) * move OS package installation to OS specific subtasks * update README * update CHANGELOG Co-authored-by: githubixx <home@tauceti.net>unmanaged-hosts 6.2.0
parent
97f566ad85
commit
9f76b8baf5
@ -1,11 +1,19 @@
|
|||||||
---
|
---
|
||||||
|
- name: (CentOS) Add WireGuard repository
|
||||||
- name: Add WireGuard repository
|
|
||||||
get_url:
|
get_url:
|
||||||
url: https://copr.fedorainfracloud.org/coprs/jdoss/wireguard/repo/epel-7/jdoss-wireguard-epel-7.repo
|
url: https://copr.fedorainfracloud.org/coprs/jdoss/wireguard/repo/epel-7/jdoss-wireguard-epel-7.repo
|
||||||
dest: /etc/yum.repos.d/wireguard.repo
|
dest: /etc/yum.repos.d/wireguard.repo
|
||||||
|
|
||||||
- name: Install EPEL repository
|
- name: (CentOS) Install EPEL repository
|
||||||
yum:
|
yum:
|
||||||
name: epel-release
|
name: epel-release
|
||||||
update_cache: yes
|
update_cache: yes
|
||||||
|
|
||||||
|
- name: (CentOS) Install wireguard packages
|
||||||
|
yum:
|
||||||
|
name:
|
||||||
|
- "wireguard-dkms"
|
||||||
|
- "wireguard-tools"
|
||||||
|
state: present
|
||||||
|
tags:
|
||||||
|
- wg-install
|
||||||
|
@ -1,8 +1,17 @@
|
|||||||
---
|
---
|
||||||
- name: Add wireguard COPR
|
- name: (Fedora) Add wireguard COPR
|
||||||
yum_repository:
|
yum_repository:
|
||||||
name: "jdoss-wireguard"
|
name: "jdoss-wireguard"
|
||||||
description: "Copr repo for wireguard owned by jdoss"
|
description: "Copr repo for wireguard owned by jdoss"
|
||||||
baseurl: "https://copr-be.cloud.fedoraproject.org/results/jdoss/wireguard/fedora-$releasever-$basearch/"
|
baseurl: "https://copr-be.cloud.fedoraproject.org/results/jdoss/wireguard/fedora-$releasever-$basearch/"
|
||||||
gpgkey: "https://copr-be.cloud.fedoraproject.org/results/jdoss/wireguard/pubkey.gpg"
|
gpgkey: "https://copr-be.cloud.fedoraproject.org/results/jdoss/wireguard/pubkey.gpg"
|
||||||
gpgcheck: yes
|
gpgcheck: yes
|
||||||
|
|
||||||
|
- name: (Fedora) Install wireguard packages
|
||||||
|
yum:
|
||||||
|
name:
|
||||||
|
- "wireguard-dkms"
|
||||||
|
- "wireguard-tools"
|
||||||
|
state: present
|
||||||
|
tags:
|
||||||
|
- wg-install
|
||||||
|
@ -1,26 +1,48 @@
|
|||||||
---
|
---
|
||||||
- name: Update APT package cache
|
- name: (Ubuntu) Update APT package cache
|
||||||
apt:
|
apt:
|
||||||
update_cache: true
|
update_cache: "{{ wireguard_ubuntu_update_cache }}"
|
||||||
cache_valid_time: 3600
|
cache_valid_time: "{{ wireguard_ubuntu_cache_valid_time }}"
|
||||||
tags:
|
tags:
|
||||||
- wg-install
|
- wg-install
|
||||||
|
|
||||||
- name: Install required packages
|
- block:
|
||||||
package:
|
- name: (Ubuntu) Install support packages needed for Wireguard (for Ubuntu < 19.10)
|
||||||
name: "{{ packages }}"
|
package:
|
||||||
state: present
|
name: "{{ packages }}"
|
||||||
vars:
|
state: present
|
||||||
packages:
|
vars:
|
||||||
- software-properties-common
|
packages:
|
||||||
- linux-headers-{{ ansible_kernel }}
|
- software-properties-common
|
||||||
tags:
|
- linux-headers-{{ ansible_kernel }}
|
||||||
- wg-install
|
tags:
|
||||||
|
- wg-install
|
||||||
|
|
||||||
- name: Add WireGuard repository
|
- name: (Ubuntu) Add WireGuard repository (for Ubuntu < 19.10)
|
||||||
apt_repository:
|
apt_repository:
|
||||||
repo: "ppa:wireguard/wireguard"
|
repo: "ppa:wireguard/wireguard"
|
||||||
state: present
|
state: present
|
||||||
update_cache: yes
|
update_cache: yes
|
||||||
tags:
|
tags:
|
||||||
- wg-install
|
- wg-install
|
||||||
|
|
||||||
|
- name: (Ubuntu) Install wireguard packages (for Ubuntu < 19.10)
|
||||||
|
apt:
|
||||||
|
name:
|
||||||
|
- "wireguard-dkms"
|
||||||
|
- "wireguard-tools"
|
||||||
|
state: present
|
||||||
|
tags:
|
||||||
|
- wg-install
|
||||||
|
when:
|
||||||
|
- ansible_lsb.major_release is version('19.10', '<')
|
||||||
|
|
||||||
|
- block:
|
||||||
|
- name: (Ubuntu) Install wireguard-tools package (for Ubuntu > 19.04)
|
||||||
|
apt:
|
||||||
|
name: "wireguard-tools"
|
||||||
|
state: present
|
||||||
|
tags:
|
||||||
|
- wg-install
|
||||||
|
when:
|
||||||
|
- ansible_lsb.major_release is version('19.04', '>')
|
||||||
|
@ -1,2 +0,0 @@
|
|||||||
packages:
|
|
||||||
- wireguard-tools
|
|
@ -1,3 +0,0 @@
|
|||||||
packages:
|
|
||||||
- wireguard-dkms
|
|
||||||
- wireguard-tools
|
|
Loading…
Reference in New Issue