We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cdd64d1 commit a7e7976Copy full SHA for a7e7976
linux/docker-debain.sh
@@ -0,0 +1,20 @@
1
+echo "删除旧版docker"
2
+apt-get remove docker docker-engine docker.io
3
+echo "更新docker镜像并下载docker"
4
+apt-get install apt-transport-https ca-certificates curl gnupg2 software-properties-common
5
+curl -fsSL https://repo.huaweicloud.com/docker-ce/linux/debian/gpg | apt-key add -
6
+add-apt-repository "deb [arch=amd64] https://repo.huaweicloud.com/docker-ce/linux/debian $(lsb_release -cs) stable"
7
+apt-get update -y
8
+apt-get install -y docker-ce
9
+echo "配置docker国内镜像源"
10
+mkdir -p /etc/docker
11
+tee /etc/docker/daemon.json <<-'EOF'
12
+{
13
+ "registry-mirrors": [
14
+ "https://hub-mirror.c.163.com",
15
+ "https://mirror.baidubce.com"
16
+ ]
17
+}
18
+EOF
19
+systemctl daemon-reload
20
+systemctl restart docker
0 commit comments