From 27fe69cfa038d2607b138f13da28e2c5f71127b5 Mon Sep 17 00:00:00 2001 From: Matej Focko Date: Tue, 30 Jul 2024 15:11:16 +0200 Subject: [PATCH] fix(os/el): enable Google repo and RPMfusion Signed-off-by: Matej Focko --- roles/os/el/files/google-chrome.repo | 6 ++++++ roles/os/el/tasks/main.yml | 20 +++++++++++++++++++- 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 roles/os/el/files/google-chrome.repo diff --git a/roles/os/el/files/google-chrome.repo b/roles/os/el/files/google-chrome.repo new file mode 100644 index 0000000..beaccad --- /dev/null +++ b/roles/os/el/files/google-chrome.repo @@ -0,0 +1,6 @@ +[google-chrome] +name=google-chrome +baseurl=http://dl.google.com/linux/chrome/rpm/stable/x86_64 +enabled=1 +gpgcheck=1 +gpgkey=https://dl.google.com/linux/linux_signing_key.pub diff --git a/roles/os/el/tasks/main.yml b/roles/os/el/tasks/main.yml index e9d0478..5d1a826 100644 --- a/roles/os/el/tasks/main.yml +++ b/roles/os/el/tasks/main.yml @@ -29,5 +29,23 @@ community.general.copr: name: mfocko/mfocko state: enabled - chroot: "epel-9-{{ ansible_architecture }}" + chroot: "epel-{{ ansible_distribution_major_version }}-{{ ansible_architecture }}" become: true + +- name: Install RPMFusion RPMs with GPG keys + ansible.builtin.dnf: + name: + - "https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-{{ ansible_distribution_major_version }}.noarch.rpm" + - "https://mirrors.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-{{ ansible_distribution_major_version }}.noarch.rpm" + disable_gpg_check: true + state: present + tags: os-el-rpmfusion + +- name: Install Google Chrome repository + ansible.builtin.copy: + src: files/google-chrome.repo + dest: /etc/yum.repos.d/google-chrome.repo + mode: 0640 + owner: root + group: root + tags: os-el-chrome