tweaks
This commit is contained in:
@@ -2,4 +2,4 @@ Server Setup Script
|
||||
=====================
|
||||
|
||||
#Use#
|
||||
wget -qO - https://code.totosearch.org/Sean/ServerSetup/setup.sh | sudo bash
|
||||
wget -qO - https://code.totosearch.org/Sean/ServerSetup/raw/branch/master/setup.sh | sudo bash
|
||||
|
||||
@@ -24,16 +24,12 @@ fi
|
||||
#calculate width and height of console
|
||||
width=`tput cols`
|
||||
height=`tput lines`
|
||||
|
||||
window=$((height - 5))
|
||||
# set line separator
|
||||
hold="$IFS"; IFS=$'\n'
|
||||
devices=""; for device in $(ls /dev/disk/by-id | grep -v part); do devices="$devices $device off"; done
|
||||
IFS="$hold"
|
||||
disks=`dialog --separate-output --no-cancel --no-items --title "Root devices" --checklist "Select boot drives" $height $width ${window}$devices 2>&1 1>/dev/tty`
|
||||
hostname=""; while [ -z "$hostname" ]; do hostname=`dialog --no-cancel --inputbox "Host name/Server name" 8 100 2>&1 >/dev/tty`; done
|
||||
IFS=$'\n'
|
||||
nicdevices=""; for nic in $(ip -o link show | awk -F': ' '{print $2}' | grep -v '^lo'); do nicdevices="$nicdevices $nic off"; done
|
||||
IFS="$hold"
|
||||
nics=`dialog --separate-output --no-cancel --no-items --title "Network devices for bridge" --checklist "Select the network devices to be bridged" $height $width ${window}$nicdevices 2>&1 1>/dev/tty`
|
||||
|
||||
for disk in "$disks"; do
|
||||
|
||||
Reference in New Issue
Block a user