Check if running as root
- Added a check to see if the script is running as root to some of the scripts.
User will be prompted to confirm if they want to continue running as root.
Change-Id: If535945002f0e2fb58417388036373c0d5f69dfd
diff --git a/setup-ramcloud.sh b/setup-ramcloud.sh
index bc35e16..08e91d2 100755
--- a/setup-ramcloud.sh
+++ b/setup-ramcloud.sh
@@ -8,6 +8,10 @@
export ONOS_HOME=${ONOS_HOME:-$(cd `dirname $0`; pwd)}
export RAMCLOUD_HOME=${RAMCLOUD_HOME:-~/ramcloud}
+source ${ONOS_HOME}/scripts/common/utils.sh
+
+confirm-if-root
+
if [ -d ${RAMCLOUD_HOME} ]; then
echo "${RAMCLOUD_HOME} already exist, please rename or remove them."
exit 1