二进制安装docker

1.下载安装

bash 复制代码
[root@openEuler-node1 ~]# wget -c https://download.docker.com/linux/static/stable/x86_64/docker-25.0.3.tgz
[root@openEuler-node1 ~]# wget -c https://download.docker.com/linux/static/stable/x86_64/docker-rootless-extras-25.0.3.tgz

2.解压到指定目录

bash 复制代码
[root@openEuler-node1 ~]# tar xf docker-25.0.3.tgz -C /usr/local/

3.写配置文件

bash 复制代码
[root@openEuler-node1 docker]# vi /usr/lib/systemd/system/docker.service
[Unit]
Description=Docker Application Container Engine
Documentation=https://docs.docker.com
After=network-online.target firewalld.service
Wants=network-online.target

[Service]
Type=notify
EnvironmentFile=-/etc/sysconfig/docker
EnvironmentFile=-/etc/sysconfig/docker-storage
EnvironmentFile=-/etc/sysconfig/docker-network
Environment=GOTRACEBACK=crash

ExecStart=/usr/bin/dockerd $OPTIONS \
                           $DOCKER_STORAGE_OPTIONS \
                           $DOCKER_NETWORK_OPTIONS \
                           $INSECURE_REGISTRY
ExecReload=/bin/kill -s HUP $MAINPID
LimitNOFILE=1048576
LimitNPROC=1048576
LimitCORE=infinity
# set delegate yes so that systemd does not reset the cgroups of docker containers
Delegate=yes
# kill only the docker process, not all processes in the cgroup
KillMode=process

[Install]
WantedBy=multi-user.target

4.启动

bash 复制代码
[root@openEuler-node1 docker]# cp /usr/local/docker/* /usr/bin/
[root@openEuler-node1 docker]# systemctl daemon-reload 
[root@openEuler-node1 docker]# systemctl start docker.service 
相关推荐
Lsetea16 分钟前
OpenSSL的checkhost显示不匹配却退出0:名称检查与证书验收
linux·https·shell·ssl证书·openssl
张文君28 分钟前
Ubuntu iSCSI CHAP认证与Win11挂载
linux·运维·ubuntu
一直C31 分钟前
嵌入式 Linux 驱动开发学习笔记:中断、等待队列与工作队列
linux·驱动开发·嵌入式硬件·学习·imx6ull
程序员-Benothing37 分钟前
Linux防火墙配置教程:iptables、firewalld、nftables、ufw
linux·运维·服务器
齐鲁大虾1 小时前
如何通过 CUPS Web 界面(http://localhost:631)安装打印机驱动
linux
木雷坞1 小时前
Docker Compose端口映射排查:用port和inspect定位网页访问失败
运维·docker·容器
yunwei371 小时前
eBPF 实例教程:使用内核跟踪点监控 GPU 驱动活动
linux·后端·性能优化
AlfredZhao2 小时前
用脚本按顺序执行初始化 DB 的 SQL 文件
linux
瑞克-桑切斯3 小时前
企业生产环境:https部署+nginx高可用(业务不中断)
linux·服务器·数据库
浩浩测试一下10 小时前
Linux 底层知识点 1
linux·运维·服务器