Opened 4 weeks ago

Last modified 4 weeks ago

#13491 accepted Bug Report - General

Ansible patch for enabling rpmfusion for CentOS 8

Reported by: Gary Buhrmaster Owned by: Stuart Auchterlonie
Priority: minor Milestone: 31.0
Component: Ansible Version: Master Head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

Ansible patch to enable rpmfusion for CentOS 8

Note: This should be considered just a preparatory patch. There are still a number of packages which are not yet available in CentOS 8, and it is highly likely additional ansible patches will be necessary.

(Lightly) tested on a CentOS 8 test mule.

Depends on previous ticket #13490 being applied.

diff --git a/roles/mythtv-dnf/tasks/main.yml b/roles/mythtv-dnf/tasks/main.yml
index 3fe6e18..fa26145 100644
--- a/roles/mythtv-dnf/tasks/main.yml
+++ b/roles/mythtv-dnf/tasks/main.yml
@@ -4,7 +4,7 @@
   when:    ansible_distribution == "CentOS"
 
 - include: setup-rpmfusion.yml
-  when:    ansible_distribution == "Fedora"
+  when:    ansible_distribution == "Fedora" or ansible_distribution == "CentOS"
 
 - name: create dnf compilers and build essentials list
   set_fact:
diff --git a/roles/mythtv-dnf/tasks/setup-rpmfusion.yml b/roles/mythtv-dnf/tasks/setup-rpmfusion.yml
index 818934b..527f786 100644
--- a/roles/mythtv-dnf/tasks/setup-rpmfusion.yml
+++ b/roles/mythtv-dnf/tasks/setup-rpmfusion.yml
@@ -13,3 +13,7 @@
 - name: setup RPMfusion repository (Fedora release versions)
   command: dnf install -y --nogpgcheck {{ rpmfusion_rpm }}
   when: ansible_distribution == "Fedora" and rpmfusion.stdout == "missing" and not rawhide.stdout == "rawhide"
+
+- name: setup RPMFusion repository (CentOS release versions)
+  command: dnf install -y --nogpgcheck {{ rpmfusion_el_rpm }}
+  when: ansible_distribution == "CentOS" and rpmfusion.stdout == "missing"
diff --git a/roles/mythtv-dnf/vars/main.yml b/roles/mythtv-dnf/vars/main.yml
index db8ec2c..e025e15 100644
--- a/roles/mythtv-dnf/vars/main.yml
+++ b/roles/mythtv-dnf/vars/main.yml
@@ -4,6 +4,7 @@ epel_rpm: "https://dl.fedoraproject.org/pub/epel/epel-release-latest-{{ ansible_
 
 rpmfusion_rpm: "http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-{{ ansible_distribution_major_version }}.noarch.rpm"
 rpmfusion_rawhide_rpm: "http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-rawhide.noarch.rpm"
+rpmfusion_el_rpm: "https://download1.rpmfusion.org/free/el/rpmfusion-free-release-{{ ansible_distribution_major_version }}.noarch.rpm"
 
 lame_src: " http://download1.rpmfusion.org/free/el/updates/6/SRPMS/lame-3.99.5-1.el6.src.rpm"
 lame_rpm: "~/rpmbuild/RPMS/{{ansible_architecture}}/lame-3.99.5-1.el7.centos.{{ansible_architecture}}.rpm" 

Change History (1)

comment:1 Changed 4 weeks ago by Stuart Auchterlonie

Component: MythTV - GeneralAnsible
Milestone: needs_triage31.0
Owner: set to Stuart Auchterlonie
Status: newaccepted
Note: See TracTickets for help on using tickets.