diff options
Diffstat (limited to 'roles')
-rw-r--r-- | roles/fedora/defaults/main.yml | 2 | ||||
-rw-r--r-- | roles/fedora/tasks/dnf.yml | 11 |
2 files changed, 13 insertions, 0 deletions
diff --git a/roles/fedora/defaults/main.yml b/roles/fedora/defaults/main.yml index 41944d9..d12cc0d 100644 --- a/roles/fedora/defaults/main.yml +++ b/roles/fedora/defaults/main.yml @@ -13,6 +13,8 @@ logind_conf: {} resolved_conf: {} timesyncd_conf: {} +dnf_makecache: false + dnf_packages: 'glibc-langpack-en': present 'initscripts': present diff --git a/roles/fedora/tasks/dnf.yml b/roles/fedora/tasks/dnf.yml index 6b3ad74..4a3e623 100644 --- a/roles/fedora/tasks/dnf.yml +++ b/roles/fedora/tasks/dnf.yml @@ -32,4 +32,15 @@ tags: - packages +- name: Configure dnf-makecache timer + systemd: + name: dnf-makecache.timer + enabled: "{{ dnf_makecache|ternary('yes','no') }}" + masked: no + state: "{{ dnf_makecache|ternary('started','stopped') }}" + when: not chroot +- name: '- when in chroot' + command: 'systemctl {{ dnf_makecache|ternary("enable","disable") }} dnf-makecache.timer' + when: chroot + # vim: set ts=2 sw=2 et: |