Fixes in scripts for fedora

This commit is contained in:
absurdo 2022-10-26 12:57:06 +02:00
parent d54f94379b
commit 4914a1f0e7
8 changed files with 77 additions and 17 deletions

View file

@ -22,3 +22,7 @@ elif linux_distro=='debian':
if call('sudo DEBIAN_FRONTEND="noninteractive" apt-get install -y git', shell=True) > 0:
print('Error, cannot install git...')
exit(1)
elif linux_distro=='rocky' or linux_distro=='fedora':
if call("sudo dnf install -y git", shell=True) > 0:
print('Error, cannot install git...')
exit(1)

View file

@ -19,6 +19,16 @@ elif [[ $DISTRO =~ ^NAME=\"Arch ]]; then
sudo pacman -Syu --noconfirm python python-pip
elif [[ $DISTRO =~ ^NAME=\"Rocky ]]; then
sudo dnf install -y python python-pip
#Install EPEL
dnf config-manager --set-enabled crb
sudo dnf install -y \
https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
sudo dnf upgrade -y
else
echo "Sorry, Linux distro not supported"

View file

@ -30,3 +30,9 @@ elif linux_distro=='debian':
if call(update_command, shell=True) > 0:
print('Error, cannot upgrade server...')
exit(1)
elif linux_distro=='rocky' or linux_distro=='fedora':
if call("sudo dnf upgrade -y", shell=True) > 0:
print('Error, cannot upgrade server...')
exit(1)