按照官网 docker 进行安装
这里大概列一下命令,还是要看官网,有可能有更新
添加仓库
1 2 3 4 5 6 7 8 9 10 11 12
| sudo apt-get update sudo apt-get install ca-certificates curl sudo install -m 0755 -d /etc/apt/keyrings sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc sudo chmod a+r /etc/apt/keyrings/docker.asc
echo \ "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \ $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \ sudo tee /etc/apt/sources.list.d/docker.list > /dev/null sudo apt-get update
|
安装
1
| sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
|
激活,并开机自启
1
| systemctl enable --now docker
|
注意最新版没有 docker-compose
版本说明
当前测试版本为
1 2
| docker-ce/noble,now 5:26.1.1-1~ubuntu.24.04~noble amd64 docker-compose-plugin/noble,now 2.27.0-1~ubuntu.24.04~noble amd64
|
本文作者:yuhldr
本文地址: https://yuhldr.github.io/posts/f0d02c9.html
版权声明:转载请注明出处!