Files
2025-06-30 11:05:13 +02:00

15 lines
276 B
Bash

#!/bin/bash
cVer=`rpm -E %{rhel}`
if [ -z "$cVer" ]; then
echo "Error: Unable to determine CentOS version."
exit 0
fi
if [ "$cVer" -gt 7 ]; then
echo "--- Executing: $0 $@"
echo 'Updating OS. This will take a around 10 minutes'
dnf -y --quiet update
fi