Browse Source

Prevent running bootstrap.sh as root

Casper 7 năm trước cách đây
mục cha
commit
8dfbaba288
1 tập tin đã thay đổi với 6 bổ sung0 xóa
  1. 6 0
      bootstrap.sh

+ 6 - 0
bootstrap.sh

@@ -1,5 +1,11 @@
 #!/bin/bash
 # Simple bootstrap script to build and run the daemon
+
+if [ "$EUID" -eq 0 ]
+  then echo "Please don't run bootstrap.sh as root."
+  exit
+fi
+
 set -e
 
 # Echo the rest so it's obvious