-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.sh
More file actions
35 lines (28 loc) · 874 Bytes
/
Copy pathsetup.sh
File metadata and controls
35 lines (28 loc) · 874 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/bash
# =====================================================
# This script used to setup ndt
# Part of https://github.com/wildyverando/ndt.git
# =====================================================
if ! [[ $(whoami) == "root" ]]; then
echo "This script required sudoer"
exit
fi
if ! command -V iptables > /dev/null 2>&1; then
echo "iptables not installed, please install and try again !"
exit
fi
if ! command -V ebtables > /dev/null 2>&1; then
echo "ebtables not installed, please install and try again !"
exit
fi
wget -q -O /usr/bin/ndt 'https://raw.githubusercontent.com/wildyverando/ndt/main/ndt.sh'
chmod 700 /usr/bin/ndt
rm -rf setup.sh
if ! [[ $(echo -e '7' | /usr/bin/ndt | grep -w 'Existed.') ]]; then
echo "Installation failed, please try again !"
exit
else
echo "Installation success,"
echo "NDT Has been installed"
exit
fi