From cc13a49d360dbdf9e731b1bbb2562709d402d23b Mon Sep 17 00:00:00 2001 From: Chase Wright Date: Sat, 1 Sep 2018 09:38:30 -0500 Subject: [PATCH] Add root/sudo check --- guac-upgrade.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/guac-upgrade.sh b/guac-upgrade.sh index a690894..63734aa 100644 --- a/guac-upgrade.sh +++ b/guac-upgrade.sh @@ -1,5 +1,8 @@ #!/bin/bash +# Check if user is root or sudo +if ! [ $(id -u) = 0 ]; then echo "Please run this script as sudo or root"; exit 1 ; fi + # Version number of Guacamole to install GUACVERSION="0.9.14"