Skip to content
Snippets Groups Projects
Verified Commit bbdbf7be authored by David Beniamine's avatar David Beniamine
Browse files

Check if systems requires a reboot

parent be730a43
Branches
No related tags found
No related merge requests found
......@@ -81,3 +81,10 @@ then
else
awk '/^[ \t]*(server_name|server_alias)/{gsub(/;$/, "", $2); print "https://"$2}' /etc/nginx/*-enabled/* | sort -u
fi
# Check if reeboot is requird
last_kernel="$(dpkg -l | awk '/linux-image-[0-9]/{print $2}' | sort -rn | head -n 1)"
running_kernel="linux-image-$(uname -r)"
if [ "$last_kernel" != "$running_kernel" ]
then
echo "Running on an old kernel, reboot required"
fi
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment