On Tue, 18 Feb 2020 01:25:18 -0800 (PST)
Donald Jones <[email protected]> wrote:

> Up until now I've been making a logic decision with my ansible roles based 
> upon the ansible_os_family, to run the appropriate module for yum 
> ('RedHat') or apt ('Debian').
> 
> With the introduction of CentOS 8, dnf has been brought in as a replacement 
> for yum. 
> So my question is, is there a prefered 'when' logic that I can use to 
> determine whether I should use the dnf or yum module in a playbook/role? 
> Ideally something that maximises future proof.

It's possible to use "package – Generic OS package manager". The selection of
the package manager is automatic by default.
https://docs.ansible.com/ansible/latest/modules/package_module.html

HTH,

        -vlado

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/20200218112959.1b44c6e6%40gmail.com.

Attachment: pgp6t53hXuSjV.pgp
Description: OpenPGP digital signature

Reply via email to