ansible/roles/dhcpd/tasks/main.yml

15 lines
330 B
YAML
Raw Normal View History

2017-01-21 17:55:08 +01:00
---
- name: Install dhcp server
apt: name=isc-dhcp-server
2017-01-21 17:55:08 +01:00
- name: Configure dhcp server
template: src={{ item }}.j2 dest=/etc/{{ item }}
2017-01-21 17:55:08 +01:00
with_items:
- default/isc-dhcp-server
2017-01-21 17:55:08 +01:00
- dhcp/dhcpd.conf
notify: Restart isc-dhcp-server
2017-01-21 17:55:08 +01:00
- name: Start the dhcp server
service: name=isc-dhcp-server state=started enabled=yes