mirror of
https://github.com/GNS3/gns3-server
synced 2025-03-03 17:56:05 +00:00
fix: check if remote-install.sh is being run as root
This commit is contained in:
parent
185cd01e19
commit
f3e46227d8
@ -38,6 +38,13 @@ function log {
|
|||||||
}
|
}
|
||||||
|
|
||||||
lsb_release -d | grep "LTS" > /dev/null
|
lsb_release -d | grep "LTS" > /dev/null
|
||||||
|
|
||||||
|
if [ "$EUID" -ne 0 ]
|
||||||
|
then
|
||||||
|
echo "This script must be run as root"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
if [ $? != 0 ]
|
if [ $? != 0 ]
|
||||||
then
|
then
|
||||||
echo "This script can only be run on a Linux Ubuntu LTS release"
|
echo "This script can only be run on a Linux Ubuntu LTS release"
|
||||||
|
Loading…
Reference in New Issue
Block a user