最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

Ubuntu 20.04 上安裝和使用 Docker的詳細(xì)過(guò)程(安裝包)

 更新時(shí)間:2022年03月03日 10:16:29   作者:久末丶  
這篇文章主要介紹了Ubuntu 20.04 上安裝和使用 Docker的詳細(xì)過(guò)程(安裝包),本文給大家介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋友可以參考下

安裝前將所有的軟件包上傳到系統(tǒng)的/opt路徑,所有的操作都在/opt目錄下

一、解壓文件

tar -xzvf docker-19.03.0.tgz

二、拷貝解壓后的文件到/usr/bin/下面

cp docker/* /usr/bin/

三、加入系統(tǒng)文件

cat >/etc/systemd/system/docker.service <<-EOF
[Unit]
Description=Docker Application Container Engine
After=network-online.target firewalld.service
Wants=network-online.target

[Service]
Type=notify
# the default is not to use systemd for cgroups because the delegate issues still
# exists and systemd currently does not support the cgroup feature set required
# for containers run by docker
ExecStart=/usr/bin/dockerd -H tcp://0.0.0.0:2375 -H unix://var/run/docker.sock
ExecReload=/bin/kill -s HUP $MAINPID
# Having non-zero Limit*s causes performance problems due to accounting overhead
# in the kernel. We recommend using cgroups to do container-local accounting.
LimitNOFILE=infinity
LimitNPROC=infinity
LimitCORE=infinity
# Uncomment TasksMax if your systemd version supports it.
# Only systemd 226 and above support this version.
#TasksMax=infinity
TimeoutStartSec=0
# 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
# restart the docker process if it exits prematurely
Restart=on-failure
StartLimitBurst=3
StartLimitInterval=60s

[Install]
WantedBy=multi-user.target
EOF

四、啟動(dòng)Docker

systemctl daemon-reload && systemctl start docker && systemctl enable docker.service

五、Docker配置文件

編輯daemon.json文件輸入以下內(nèi)容

vim /etc/docker/daemon.json
{
    "log-driver":"json-file",
    "log-opts":{
        "max-size" :"10m","max-file":"4"
    },
    "registry-mirrors": ["https://6kx4zyno.mirror.aliyuncs.com"]
}

六、重啟Docker

systemctl restart docker 

七、檢查Docker是否安裝成功

docker --version

八、總結(jié)

我們已經(jīng)向你展示如何在 Ubuntu 20.04 機(jī)器上安裝 Docker。

想要學(xué)習(xí)更多關(guān)于 Docker 的信息,查閱官方 Docker 文檔

到此這篇關(guān)于Ubuntu 20.04 上安裝和使用 Docker的詳細(xì)過(guò)程(安裝包)的文章就介紹到這了,更多相關(guān)Ubuntu 20.04使用 Docker內(nèi)容請(qǐng)搜索腳本之家以前的文章或繼續(xù)瀏覽下面的相關(guān)文章希望大家以后多多支持腳本之家!

相關(guān)文章

最新評(píng)論

天台县| 麻阳| 山东省| 龙里县| 资阳市| 全椒县| 东台市| 正宁县| 雷州市| 昌乐县| 沅江市| 额尔古纳市| 兴国县| 武乡县| 永寿县| 高青县| 永顺县| 桦甸市| 贵港市| 芜湖县| 习水县| 聂拉木县| 浦城县| 青河县| 浙江省| 双流县| 五原县| 昆明市| 平南县| 乌兰浩特市| 连平县| 当阳市| 尉氏县| 政和县| 西和县| 宁国市| 中阳县| 股票| 新兴县| 灵台县| 保靖县|