Skip to content

Commit 8a5fbd6

Browse files
committed
Do OS-Update for Redhat family - add CentOS7 yum
1 parent 8b949e7 commit 8a5fbd6

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

server/mods-available/remoteaction_core_module.inc.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -180,9 +180,7 @@ private function _doOsUpdate($action) {
180180
if(file_exists('/etc/gentoo-release')) {
181181
exec("glsa-check -f --nocolor affected");
182182
} elseif(file_exists('/etc/redhat-release')) {
183-
exec("dnf -y update");
184-
} elseif(file_exists('/etc/redhat-release')) {
185-
exec("dnf -y update");
183+
exec("which dnf &> /dev/null && dnf -y update || yum -y update");
186184
} else {
187185
exec("apt-get update");
188186
exec("apt-get -y upgrade");

0 commit comments

Comments
 (0)