aboutsummaryrefslogtreecommitdiff
path: root/tools/setup_RedHat.sh
blob: aca0ec9229541d6ef6063ee4d93c9fd3cb8bdae0 (plain)
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
#!/bin/bash

set -o xtrace
set -o errexit

# (SamYaple)TODO: Remove the path overriding
export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"

sudo tee /etc/yum.repos.d/docker-ce-stable.repo << EOF
[docker-ce-stable]
baseurl=$DOCKER_REPOS_MIRROR_URL/centos/7/\$basearch/stable
enabled=1
gpgcheck=1
gpgkey=$DOCKER_REPOS_MIRROR_URL/centos/gpg
EOF

sudo yum -y install docker-ce

# Disable SELinux
setenforce 0

sudo systemctl start docker
sudo docker info

echo "Completed $0."