[refactor] Move variables to their own file

This commit is contained in:
William Wernert
2020-04-18 18:41:19 -04:00
parent 63fd274106
commit ce59019967
2 changed files with 36 additions and 10 deletions

View File

@@ -32,16 +32,6 @@ fi
# Allow execution of SO tools during setup
export PATH=$PATH:../salt/common/tools/sbin
# Global Variables
HOSTNAME=$(cat /etc/hostname)
TOTAL_MEM=$(grep MemTotal /proc/meminfo | awk '{print $2}' | sed -r 's/.{3}$//')
NICS=$(ip link | awk -F: '$0 !~ "lo|vir|veth|br|docker|wl|^[^0-9]"{print $2 " \"" "Interface" "\"" " OFF"}')
CPUCORES=$(grep -c "processor" /proc/cpuinfo | grep -cv KVM)
LISTCORES=$(grep "processor" /proc/cpuinfo | awk '{print $3 " \"" "core" "\""}')
RANDOMUID=$(</dev/urandom tr -dc 'a-zA-Z0-9' | fold -w 16 | head -n 1)
NODE_ES_PORT="9200"
SETUPLOG="/root/sosetup.log"
# End Global Variables
# Reset the Install Log
date -u > $SETUPLOG 2>&1