ansible-ffibk/roles/service-bird/tasks/main.yml
2018-09-18 14:27:58 +02:00

59 lines
1.1 KiB
YAML

---
- name: install bird packages
package:
name: "{{ item }}"
state: present
loop:
- bird-bgp
- bird-doc
- name: set directory permissions for /etc/bird
file:
path: /etc/bird
state: directory
mode: 0755
- name: write bird.conf
template:
src: bird.conf.j2
dest: /etc/bird/bird.conf
mode: 0640
owner: bird
group: bird
notify: reload systemd unit bird
- name: write bird6.conf
template:
src: bird6.conf.j2
dest: /etc/bird/bird6.conf
mode: 0640
owner: bird
group: bird
notify: reload systemd unit bird6
- name: write mwu_ipv4_peers.conf
template:
src: mwu_ipv4_peers.conf.j2
dest: /etc/bird/mwu_ipv4_peers.conf
mode: 0640
owner: bird
group: bird
notify: reload systemd unit bird
- name: write mwu_ipv6_peers.conf
template:
src: mwu_ipv6_peers.conf.j2
dest: /etc/bird/mwu_ipv6_peers.conf
mode: 0640
owner: bird
group: bird
notify: reload systemd unit bird6
- name: enable + start systemd units bird + bird6
systemd:
name: bird{{ item }}
enabled: yes
state: started
loop:
- ""
- 6