deploy-base/roles/bootstrap/tasks/dnf.yml

29 lines
732 B
YAML
Raw Normal View History

---
- name: raise max_parallel_downloads to 20
lineinfile:
path: /etc/dnf/dnf.conf
regexp: "^max_parallel_downloads.="
line: "max_parallel_downloads=20"
- name: install dnf-automatic
package:
name: dnf-automatic
state: present
- name: configure dnf-automatic
lineinfile:
path: /etc/dnf/automatic.conf
state: present
regexp: "{{ item.regexp }}"
line: "{{ item.line }}"
with_items:
- { regexp: '^upgrade_type.=', line: 'upgrade_type = security' }
- { regexp: '^emit_via.=', line: 'emit_via = stdio' }
- { regexp: '^apply_updates.=', line: 'apply_updates = yes' }
- name: enable dnf-automatic timer
systemd:
name: dnf-automatic.timer
state: started
enabled: yes