mirror of
https://github.com/hwdsl2/openvpn-install.git
synced 2026-01-11 02:46:16 +00:00
Use EUID to check root
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
# universal as possible.
|
||||
|
||||
|
||||
if [[ "$USER" != 'root' ]]; then
|
||||
if [[ "$EUID" -ne 0 ]]; then
|
||||
echo "Sorry, you need to run this as root"
|
||||
exit
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user