Ansible_workstation/roles/collectd/tasks/main.yml

31 lines
510 B
YAML
Raw Normal View History

2022-03-30 19:23:16 +00:00
---
# tasks file for collectd
- name: Install collectd
apt:
name: collectd-core
state: present
- name: Make config dir
file:
path: "/etc/collectd/"
state: directory
- name: Copy dtypes.db
copy:
src: types.db
dest: /usr/share/collectd/types.db
- name: Feed config
template:
src: collectd.conf.j2
dest: /etc/collectd/collectd.conf
mode: 644
notify:
- Restart collectd
- name: Enable collectd service
systemd:
name: "collectd.service"
enabled: yes