added root check

main
alex 2023-09-16 11:36:34 +02:00
parent c9b50db0d1
commit b2bf49719d
2 changed files with 12 additions and 0 deletions

View File

@ -1,3 +1,9 @@
# only allow to run this script as root
if [ "$EUID" -ne 0 ]
then echo "Please run as root"
exit
fi
#docker compose down #docker compose down
# rm images # rm images

View File

@ -1,3 +1,9 @@
# only allow to run this script as root
if [ "$EUID" -ne 0 ]
then echo "Please run as root"
exit
fi
ORANGE='\033[0;33m' # Orange ORANGE='\033[0;33m' # Orange
GREEN='\033[0;32m' # Green GREEN='\033[0;32m' # Green
NC='\033[0m' # No color (reseting) NC='\033[0m' # No color (reseting)