Last Updated: February 25, 2016
·
918
· tinche

Add a Yum repo

If the Yum repository you want to use has a repository RPM (like EPEL and PostgreSQL), this simple task can be used to ensure the repository is installed:

name: Add the EPEL yum repo.
command: /bin/rpm -U http://fedora.cu.be/epel/6/i386/epel-release-6-8.noarch.rpm
creates=/etc/yum.repos.d/epel.repo

(example for CentOS 6 + EPEL)