Switched to ELRepo for Centos (#59)

* Switched to ELRepo for Centos (#50)
- added switch to differentiate setup of Centos7/8
- replaced old repository by officialy recomended
- added step to remove old dkms wireguard package
- switched to install KMOD wireguard package

* Updated CHANGELOG after switching to ELRepo for Centos

* Update CHANGELOG.md

Co-authored-by: Robert Wimmer <2039811+githubixx@users.noreply.github.com>

* Updted CHANGELOG: added notice about old wireguard Centos repository removal

Co-authored-by: Robert Wimmer <2039811+githubixx@users.noreply.github.com>
master 7.0.0
Roman Danko 4 years ago committed by GitHub
parent d5b81cb75e
commit c1f413f966
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1,6 +1,14 @@
Changelog
---------
**7.0.0**
- Switched to install from ELRepo KMOD package for CentOS (see https://www.wireguard.com/install/). This change may break installation for systems with custom kernels. The role previously supported custom kernel implicitly because it was using DKMS package (contribution by @elcomtik)
Role removes DKMS wireguard package, however it doesn't remove jdoss-wireguard-epel-7 repository. If you don't need this repository, do cleanup by:
* remove `/etc/yum.repos.d/wireguard.repo`
**6.3.1**
- Support Openstack Debian images (contribution by @pallinger)

@ -2,7 +2,13 @@
- name: Gather instance facts
setup:
- include_tasks: "setup-{{ ansible_distribution|lower }}.yml"
- include_tasks: "{{ item }}"
with_first_found:
- "setup-{{ ansible_distribution|lower }}-{{ ansible_distribution_major_version }}.yml"
- "setup-{{ ansible_distribution|lower }}-{{ ansible_distribution_version }}.yml"
- "setup-{{ ansible_distribution|lower }}-{{ ansible_distribution_release }}.yml"
- "setup-{{ ansible_distribution|lower }}.yml"
- "setup-{{ ansible_os_family|lower }}.yml"
- name: Enable WireGuard kernel module
modprobe:

@ -0,0 +1,29 @@
---
- name: (CentOS 7) Install EPEL & ELRepo repository
yum:
name:
- epel-release
- https://www.elrepo.org/elrepo-release-7.el7.elrepo.noarch.rpm
update_cache: yes
- name: (CentOS 7) Install yum-plugin-elrepo
yum:
name: yum-plugin-elrepo
update_cache: yes
- name: (CentOS 7) Ensure wireguard DKMS package is removed
yum:
name:
- "wireguard-dkms"
state: absent
tags:
- wg-install
- name: (CentOS 7) Install wireguard packages
yum:
name:
- "kmod-wireguard"
- "wireguard-tools"
state: present
tags:
- wg-install

@ -0,0 +1,24 @@
---
- name: (CentOS 8) Install EPEL & ELRepo repository
yum:
name:
- epel-release
- elrepo-release
update_cache: yes
- name: (CentOS 8) Ensure wireguard DKMS package is removed
yum:
name:
- "wireguard-dkms"
state: absent
tags:
- wg-install
- name: (CentOS 8) Install wireguard packages
yum:
name:
- "kmod-wireguard"
- "wireguard-tools"
state: present
tags:
- wg-install

@ -1,19 +0,0 @@
---
- name: (CentOS) Add WireGuard repository
get_url:
url: https://copr.fedorainfracloud.org/coprs/jdoss/wireguard/repo/epel-7/jdoss-wireguard-epel-7.repo
dest: /etc/yum.repos.d/wireguard.repo
- name: (CentOS) Install EPEL repository
yum:
name: epel-release
update_cache: yes
- name: (CentOS) Install wireguard packages
yum:
name:
- "wireguard-dkms"
- "wireguard-tools"
state: present
tags:
- wg-install
Loading…
Cancel
Save