forked from mohamedaymenkarmous/Multi-CTFd-Docker-Deploy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path1-setup-docker.sh
executable file
·35 lines (32 loc) · 1.18 KB
/
1-setup-docker.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
#!/bin/bash
echo ""
read -p "Before you run, check the latest compose version at: https://docs.docker.com/compose/install/"
sudo apt-get remove docker docker-engine docker.io containerd runc
sudo apt-get update -y
sudo apt-get install \
apt-transport-https \
ca-certificates \
curl \
gnupg-agent \
software-properties-common -y
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo apt-key fingerprint 0EBFCD88
echo ""
echo "The fingerprint above should match:"
echo "pub rsa4096 2017-02-22 [SCEA]"
echo " 9DC8 5822 9FC7 DD38 854A E2D8 8D81 803C 0EBF CD88"
echo "uid [ unknown] Docker Release (CE deb) <[email protected]>"
echo "sub rsa4096 2017-02-22 [S]"
echo ""
read -p ""
echo ""
sudo add-apt-repository \
"deb [arch=amd64] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) \
stable"
sudo apt-get update -y
sudo apt-get install docker-ce docker-ce-cli containerd.io -y
sudo usermod -aG docker ubuntu
sudo curl -L "https://github.com/docker/compose/releases/download/1.25.4/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
docker-compose --version