infrastructure/ansible/roles/zfs/tasks/main.yml

18 lines
363 B
YAML

- name: Calculate ZFS ARC size
set_fact:
zfs_arc_size: "{{ (ansible_memtotal_mb * 1024 * 1024) * 0.15 }}"
- name: Enable zfs module
modprobe:
name: zfs
state: present
params: zfs_arc_max={{ zfs_arc_size }}
- name: ZFS Scrub
cron:
name: zfs scrub
special_time: weekly
job: zpool scrub tank
- name: Sanoid
include: sanoid.yml