Centos init

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
yum update -y && yum upgrade -y
yum install wget unzip git util-linux-user net-tools iputils util-linux-user zsh ncurses -y
curl -s curl -s https://mirror.ghproxy.com/https://gist.githubusercontent.com/Ran-Xing/0e47c9b793887d201bab9de2a07a740c/raw/3a63ca4fe9b775c5a8e141f05ddb35cc1ea09334/zsh_init.sh | bash -
source ~/.zshrc
sudo yum install -y yum-utils
sudo yum remove docker \
docker-client \
docker-client-latest \
docker-common \
docker-latest \
docker-latest-logrotate \
docker-logrotate \
docker-engine
sudo yum-config-manager \
--add-repo \
https://download.docker.com/linux/centos/docker-ce.repo
sudo yum install docker-ce docker-ce-cli containerd.io -y
sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
sudo ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose
systemctl enable docker.service
systemctl start docker.service

XRSec has the right to modify and interpret this article. If you want to reprint or disseminate this article, you must ensure the integrity of this article, including all contents such as copyright notice. Without the permission of the author, the content of this article shall not be modified or increased or decreased arbitrarily, and it shall not be used for commercial purposes in any way