ansible-ffibk/roles/service-dhcpd/tasks/main.yml

25 lines
503 B
YAML
Raw Normal View History

---
- name: install dhcp packages
package:
name: "{{ item }}"
state: present
with_items: "{{ kea_packages }}"
- name: configure kea dhcp server
template:
src: kea_dhcp4.conf.j2
dest: /etc/kea/kea-dhcp4.conf
notify: restart kea-dhcp4-server
- name: remove kea init file if present
file:
path: /etc/init.d/kea-dhcp4-server
state: absent
notify: reload systemd
2017-10-26 22:35:55 +02:00
- name: enable systemd unit kea
2017-10-26 22:35:55 +02:00
systemd:
name: kea-dhcp4-server
2017-10-26 22:35:55 +02:00
enabled: yes
state: started