-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathEnable-RpmFusion.bash
executable file
·31 lines (26 loc) · 1.25 KB
/
Enable-RpmFusion.bash
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/bin/bash
# Importing function run_as_root and get_os_type
source RunAsRoot.bash
source OsInfo.bash
# Running as root
run_as_root
# Enabling Fedora Epel
bash Enable-FedoraEpel.bash
# Installing RPM Fusion
if [ "$(get_os_type)" == "rhel" ] || [ "$(get_os_type)" == "centos" ] || [ "$(get_os_type)" == "almalinux" ] || [ "$(get_os_type)" == "ol" ]; then
dnf install --assumeyes --nogpgcheck "https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-$(rpm -E %rhel).noarch.rpm"
dnf install --assumeyes --nogpgcheck "https://mirrors.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-$(rpm -E %rhel).noarch.rpm"
elif [ "$(get_os_type)" == "fedora" ]; then
dnf install --assumeyes "https://mirrors.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm"
dnf install --assumeyes "https://mirrors.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm"
fi
dnf install --assumeyes rpmfusion-free-release-tainted
dnf install --assumeyes rpmfusion-nonfree-release-tainted
# Using openh264 library
if [ "$(get_os_type)" == "fedora" ]; then
if [ "$(command -v dnf4)" ]; then
dnf4 config-manager --enable --assumeyes fedora-cisco-openh264
else
dnf config-manager --enable --assumeyes fedora-cisco-openh264
fi
fi