forked from CCCHH/ansible-infra
34 lines
868 B
YAML
34 lines
868 B
YAML
- name: Apply jool_nat64 role
|
|
tags: [ jool_nat64, jool, nat64 ]
|
|
block:
|
|
|
|
- name: Install jool
|
|
become: true
|
|
ansible.builtin.apt:
|
|
name: [ linux-headers-amd64, jool-dkms, jool-tools ]
|
|
|
|
- name: Create jool configuration directory
|
|
become: true
|
|
ansible.builtin.file:
|
|
path: /etc/jool
|
|
state: directory
|
|
owner: root
|
|
group: root
|
|
mode: u=rwx,g=rx,o=rx
|
|
|
|
- name: Configure jool
|
|
become: true
|
|
notify: "restart jool"
|
|
ansible.builtin.copy:
|
|
content: "{{ jool_nat64__settings | to_json }}"
|
|
dest: "/etc/jool/jool.conf"
|
|
owner: root
|
|
group: root
|
|
mode: u=rw,g=r,o=r
|
|
|
|
- name: Ensure jool is running and enabled
|
|
become: true
|
|
ansible.builtin.systemd_service:
|
|
name: "jool.service"
|
|
state: "started"
|
|
enabled: true
|