-
Notifications
You must be signed in to change notification settings - Fork 37
/
Copy pathdocker_tools.sh
41 lines (36 loc) · 1.06 KB
/
docker_tools.sh
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
36
37
38
39
40
41
if type "brew" > /dev/null 2>&1; then
echo "brew already installed"
else
echo "We couldn't find brew in your system. Can I install it?"
echo "yes/no"
read inputs
if [-z $input]; then
echo "Input not recognized"
elif [ $input = 'yes' ] || [ $input = 'YES' ] || [ $input = 'y' ] ; then
echo "Install brew"
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
elif [ $input = 'no' ] || [ $input = 'NO' ] || [ $input = 'n' ] ; then
echo "OK, finish script"
exit 1
else
echo "Input yes or no"
ConfirmExecution
fi
fi
if type "docker" > /dev/null 2>&1; then
echo "docker already installed"
else
brew install docker
brew install --cask docker
fi
if type "socat" > /dev/null 2>&1; then
echo "socat already installed"
else
brew install socat
fi
if type "xterm" > /dev/null 2>&1; then
echo "xterm already installed"
else
brew install --cask xquartz
fi
echo "All tools are successfully installed! Don't forget to reboot your laptop!"