安装docker-ce

下载docker-ce.repo:

wget -O /etc/yum.repos.d/docker-ce.repo https://download.docker.com/linux/centos/docker-ce.repo

编辑docker-ce.repo:

vim /etc/yum.repos.d/docker-ce.repo

:%s#download.docker.com#mirrors.tuna.tsinghua.edu.cn/docker-ce#g
:wq yum install docker-ce -y

启动docker:

systemctl start docker

安装docker-compose

wget -O /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-7.repo

yum install docker-compose -y

安装harbor

下载安装:

wget https://storage.googleapis.com/harbor-releases/release-1.9.0/harbor-offline-installer-v1.9.0.tgz
tar xf harbor-offline-installer-v1.9.0.tgz -C /usr/local
#编辑
vim harbor.yml
hostname: 192.168.1.5
./install.sh

访问harbor:

http://192.168.1.5

密码:admin/Harbor12345

在harbor文件下因为docker-compose.yml的存在,所以可以通过docker-compose命令来控制harbor的启动与关闭,下面docker-compose命令都可以在此文件夹下生效:

Commands:
build Build or rebuild services
bundle Generate a Docker bundle from the Compose file
config Validate and view the Compose file
create Create services
down Stop and remove containers, networks, images, and volumes
events Receive real time events from containers
exec Execute a command in a running container
help Get help on a command
images List images
kill Kill containers
logs View output from containers
pause Pause services
port Print the public port for a port binding
ps List containers
pull Pull service images
push Push service images
restart Restart services
rm Remove stopped containers
run Run a one-off command
scale Set number of containers for a service
start Start services
stop Stop services
top Display the running processes
unpause Unpause services
up Create and start containers
version Show the Docker-Compose version information

比如可以通过 docker-compoe start来启动harbor。

向仓库提交镜像

创建用户:

退出用新用户登录之后创建项目:

本地镜像打标记:

docker pull busybox

docker tag busybox 192.168.1.5/myproject/mybusybox:v0.1

编辑/etc/docker/daemon.json添加一行信任规则:

"insecure-registries": ["192.168.1.5"]

登录并推送:

docker login 192.168.1.5
docker push 192.168.1.5/myproject

然后在harbor上就可以看到我们推送的镜像了:

删除镜像并从harbor上拉取:

docker rmi 192.168.1.5/myproject/mybusybox:v0.1
docker pull 192.168.1.5/myproject/mybusybox:v0.1

docker images:

docker,docker-compose,harbor安装的更多相关文章

  1. Docker私服仓库Harbor安装

    Harbor安装那里还是很简单,就是在Docker Login那里掉坑里去了,搞半天,写博客的时候,又重新安装了一遍 1.准备两台服务器 centos7 harbor 10.19.46.15 clie ...

  2. docker 私有registry harbor安装

    一,harbor安装: 参考:Installation and Configuration Guide 1,安装docker 2,安装docker compose sudo curl -L " ...

  3. Docker镜像仓库Harbor安装

    export VERSION=18.06 && curl -fsSL http://rainbond-pkg.oss-cn-shanghai.aliyuncs.com/releases ...

  4. docker(三):Harbor 1.8.0 仓库的安装和使用

    回顾: docker(一):docker是什么? docker(二):CentOS安装docker docker(部署常见应用):docker部署mysql 安装的先决条件 硬件环境 1.CPU    ...

  5. Docker Compose 介绍安装

    Compose介绍 Compose是一个定义和管理多容器的工具,也是一种容器编排工具,前身是Pig,使用Python语言编写.使用Compose配置文件描述多个容器应用的架构,biubiu使用什么镜像 ...

  6. ubuntu 14.04 https 形式安装docker 私有库 harbor

    起始目录/root,root 登陆后,直接在该目录进行下面的命令 下载harbor 预编译包 0.4.5 准备通过域名 reg.server.com 来访问镜像库所以需要在/etc/hosts 文件中 ...

  7. docker 私有镜像管理工具harbor 安装

    因为各种原因,官方的离线安装包下载比较费事,经常不成功,所以通过分部安装解决问题 1. docker yum install libdevmapper* -y -H tcp://0.0.0.0:237 ...

  8. Docker - 容器编排工具 compose 之安装

    准备 首先,在使用和安装 docker compose之前,我们应该确保我们已经安装了 docker engine. 安装 官网上面有好多种安装方式,由于我们现在是在使用Docker, 个人感觉应该以 ...

  9. Ubuntu18.04安装docker、docker-compose、

    Ubuntu18.04下Docker CE安装 Docker版本分为两个:Docker Community Edition (CE)和 Docker Enterprise Edition (EE).D ...

  10. Ubuntu 安装docker CE以及harbor

    Docker CE安装 系统建议版本:Ubuntu 16.04 官方安装文档连接:https://docs.docker.com/install/linux/docker-ce/ubuntu/#pre ...

随机推荐

  1. BUAA_OO_第一单元

    BUAA_OO_2020_UNIT1 一.程序结构分析 第一次作业 UML & Mertrics ​ 由于数据处理简单,第一次作业中笔者发挥了面向过程的思想,将项转换成Biginteger, ...

  2. 如何使用yolov3训练自己的数据集

    博客主要结构 1. 如何在ubuntu18.04上安装yolo 2 .如何配置yolov3 3 .如何制作自己的训练集测试集 4 .如何在自己的数据集上运行yolov3 1. 在ubuntu18.04 ...

  3. kubernetes的架构

    kubernetes架构 k8s的物理结构是master/node模式,架构图如下所示 master一般是三个节点或者五个节点做高可用,根据集群规模来定,master高可用指的是对apiserver做 ...

  4. istio之envoy常见术语及状态码

    基本术语 Downstream(下游):下游主机连接到 Envoy,发送请求并接收响应,即发送请求的主机. Upstream(上游):上游主机接收来自 Envoy 的连接和请求,并返回响应,即接受请求 ...

  5. 5. Linux常用命令

    clear命令: 作用:清屏 快捷键:Ctrl + L pwd命令: 作用:用于显示当前的工作路径位置(当前工作文件夹) 示例: $ pwd /home/tarena Linux/Unix下的路径: ...

  6. TP5 验证-内置规则

    系统内置的验证规则如下: 格式验证类 require 验证某个字段必须,例如: 'name'=>'require' number 或者 integer 验证某个字段的值是否为数字(采用filte ...

  7. php 日志处理工具 SeasLog 的使用

    首先附上seaslog github地址: https://github.com/Neeke/SeasLog/blob/master/README_zh.md php官方文档地址: https://w ...

  8. SpringCloud之配置中心(config)的使用Git+数据库实现

    SpringCloud微服务实战系列教程 -------------------------目录------------------------------ 一.配置中心应用(Git) 二.配置中心的 ...

  9. Python中对序列数据的汇总(collections模块)

    目录 Counter most_common 对于序列如字符串str.列表list和tuple可以统计里面数据出现的次数.我们使用的是 collections 模块. collections模块的常用 ...

  10. POJ2337 欧拉路径字典序输出

    题意:       给一些单词,问是否可以每个单词只用一次,然后连接在一起(不一定要成环,能连接在一起就行). 思路:       这个题目的入手点比较好想,其实就是问欧拉路径,先说下解题步骤,然后在 ...