国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 系統(tǒng) > CentOS > 正文

在CentOS、Fedora系統(tǒng)中使用Docker的方法

2020-06-21 12:41:08
字體:
供稿:網(wǎng)友

一、從docker官方y(tǒng)um源進行安裝

1、添加docker官方源

cat >/etc/yum.repos.d/docker.repo <<-EOF[dockerrepo]name=Docker Repositorybaseurl=https://yum.dockerproject.org/repo/main/centos/7enabled=1gpgcheck=1gpgkey=https://yum.dockerproject.org/gpgEOF

2、安裝和啟動

#安裝sudo yum install docker-engine#啟動sudo systemctl enable docker.service#開機啟動systemctl enable docker.service#驗證安裝sudo docker run hello-world

二、用腳本的方式安裝

curl -sSL https://get.docker.com/ | sh

三、非特權(quán)用戶運行 docker 命令

在 CentOS 或 Fedora 上安裝完成 Docker 后,為了能以非 root 用戶運行 docker,你需要把你自己添加進 docker 用戶組,使用如下命令:

sudo usermod -a -G docker $USER

登出,然后再登入,以使組改變生效。
這個時候,你應該可以以一個非特權(quán)用戶運行 docker 命令了。

四、使用國內(nèi)源

1、安裝dao

curl -sSL https://get.daocloud.io/daomonit/install.sh | sh -s 6d3f36d42ae3f3d4237943c65c8f3e5446e49a71

2、使用dao命令

dao pull ubuntu

看起來像這樣:

?  ~  dao pull ubuntuDao from DaoCloudInitializing, Please wait a minuteUsing default tag: latestPulling repository daocloud.io/daocloud/daocloud-toolsetaa5dc2eecd4a: Download completeStatus: Image is up to date for daocloud.io/daocloud/daocloud-toolset:latestdaocloud.io/daocloud/daocloud-toolset: this image was pulled from a legacy registry.  Important: This registry version will not be supported in future versions of docker.Inital Success# ----------------------------------------------------------------------------# DaoCloud ToolBox for Docker## DaoCloud, Inc. (c) 2015## Fastest way to pull image from Docker Registry# ----------------------------------------------------------------------------Pulling repository ubuntuPulling ubuntu image metadataPulling ubuntu:latest tag metadata0105f98ced6d: Load layer complete66395c31eb82: Load layer complete002fa881df8a: Load layer completea005e6b7dd01: Load layer completeLoading image to docker ...** Pull ubuntu success. **You can find it with 'docker images ubuntu'

其他的可以參考VEVB武林網(wǎng)之前發(fā)布的文章


發(fā)表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發(fā)表
主站蜘蛛池模板: 铜山县| 岑巩县| 容城县| 北安市| 芦山县| 岳阳市| 揭阳市| 抚远县| 祁东县| 鲁山县| 遂昌县| 西宁市| 云安县| 青冈县| 阿巴嘎旗| 田阳县| 杭锦旗| 加查县| 武义县| 益阳市| 陇川县| 阿拉善右旗| 菏泽市| 屏南县| 曲沃县| 赤水市| 阜新| 江安县| 普安县| 沂源县| 虹口区| 积石山| 遵义市| 元江| 七台河市| 扶绥县| 永善县| 宜宾县| 铜鼓县| 崇阳县| 灌南县|