mirror of
https://gitea.0xace.cc/ansible-galaxy/wireguard-ui.git
synced 2024-11-25 07:57:26 +00:00
31 lines
714 B
YAML
31 lines
714 B
YAML
- name: Install wireguard for RHEL 8
|
|
when: ansible_facts['distribution_major_version'] == '8'
|
|
block:
|
|
- name: Install repos
|
|
dnf:
|
|
name:
|
|
- elrepo-release
|
|
- epel-release
|
|
state: present
|
|
|
|
- name: Install kmod wireguard
|
|
dnf:
|
|
name:
|
|
- kmod-wireguard
|
|
- wireguard-tools
|
|
|
|
- name: Install wireguard for RHEL 9
|
|
when: ansible_facts['distribution_major_version'] == '9'
|
|
block:
|
|
- name: Install repos
|
|
dnf:
|
|
name:
|
|
- wireguard-tools
|
|
state: present
|
|
|
|
- name: Enable wg-quick systemd unit
|
|
systemd:
|
|
name: wg-quick@{{ wireguard_ui_env['WGUI_CONFIG_FILE_PATH'] | basename | split('.') | first }}
|
|
enabled: yes
|
|
daemon_reload: yes
|