22 lines
336 B
Bash
22 lines
336 B
Bash
#!/bin/bash
|
|
set -euo pipefail
|
|
|
|
|
|
yum install -y docker-ce-20.10/*.rpm
|
|
|
|
sudo mkdir /etc/docker
|
|
cat <<EOF | sudo tee /etc/docker/daemon.json
|
|
{
|
|
"exec-opts": ["native.cgroupdriver=systemd"],
|
|
"log-driver": "json-file",
|
|
"log-opts": {
|
|
"max-size": "100m"
|
|
},
|
|
"storage-driver": "overlay2"
|
|
}
|
|
EOF
|
|
|
|
sudo systemctl enable docker --now
|
|
|
|
|