2

I'm trying to install a few packages on CentOS 8 via cloud-init, like this:

package_upgrade: true

packages:
  - firewalld
  - htop

One of them one of them requires epel-release repo to be installed first:

No match for argument: htop
2019-10-21 15:50:35,444 - util.py[WARNING]: Failed to install packages: ['firewalld', 'htop']

How can I install epel-release first and then install packages?

1
  • Have you tried adding epel-release to packages? Or you can probably just add it as yum_repos in cloud-init?
    – MichelZ
    Oct 24, 2019 at 7:29

1 Answer 1

3

Add this to your cloud init script:

yum_repos:
    epel-release:
        baseurl: http://download.fedoraproject.org/pub/epel/7/$basearch
        enabled: true
        failovermethod: priority
        gpgcheck: true
        gpgkey: http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-7
        name: Extra Packages for Enterprise Linux 7 - Release
1
  • This is for Centos 7... Sep 2, 2020 at 10:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .