Docker:企业级私有仓库harbor[十六]
一、安装配置
1、下载安装包
链接:https://pan.baidu.com/s/1Z9I7zYXSt-8ve3lFT2YCeg
提取码:iuqj
2、安装docker和docker-compose
curl -o /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-7.repo
yum install -y python2-pip
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple docker-compose
3、上传harbor-offline-installer-v1.5.1.tgz安装包到/opt,并解压
[root@luoahong opt]# pwd
/opt
[root@luoahong opt]# ll
total 844664
drwx--x--x 4 root root 28 Jan 17 18:03 containerd
drwxr-xr-x 4 root root 229 Jan 18 18:51 harbor
-rw-r--r-- 1 root root 864933610 Jan 18 18:40 harbor-offline-installer-v1.5.1.tgz
4、修改harbor.cfg配置文件
hostname = 192.168.228.135
harbor_admin_password = 12345
5、执行install.sh
[root@luoahong harbor]# ./install.sh [Step 0]: checking installation environment ... Note: docker version: 18.09.1 Note: docker-compose version: 1.23.2 [Step 1]: loading Harbor images ...
52ef9064d2e4: Loading layer [==================================================>] 135.9MB/135.9MB
4a6862dbadda: Loading layer [==================================================>] 23.25MB/23.25MB
...........
[Step 2]: preparing environment ...
Generated and saved secret to file: /data/secretkey
Generated configuration file: ./common/config/nginx/nginx.conf
Generated configuration file: ./common/config/adminserver/env
Generated configuration file: ./common/config/ui/env
Generated configuration file: ./common/config/registry/config.yml
Generated configuration file: ./common/config/db/env
Generated configuration file: ./common/config/jobservice/env
Generated configuration file: ./common/config/jobservice/config.yml
Generated configuration file: ./common/config/log/logrotate.conf
Generated configuration file: ./common/config/jobservice/config.yml
Generated configuration file: ./common/config/ui/app.conf
Generated certificate, key file: ./common/config/ui/private_key.pem, cert file: ./common/config/registry/root.crt
The configuration files are ready, please use docker-compose to start the service. [Step 3]: checking existing instance of Harbor ... [Step 4]: starting Harbor ...
Creating network "harbor_harbor" with the default driver
Creating harbor-log ... done
Creating harbor-db ... done
Creating harbor-adminserver ... done
Creating redis ... done
Creating registry ... done
Creating harbor-ui ... done
Creating harbor-jobservice ... done
Creating nginx ... done ✔ ----Harbor has been installed and started successfully.---- Now you should be able to visit the admin portal at http://192.168.228.135.
For more details, please visit https://github.com/vmware/harbor .
6、web界面测试截图

二、推送文件
1、推送报错
[root@luoahong1 ~]# docker push 192.168.228.135/library/busybox:latest
The push refers to repository [192.168.228.135/library/busybox]
Get https://192.168.228.135/v2/: dial tcp 192.168.228.135:443: connect: connection refused
[root@luoahong1 ~]# systemctl restart docker
[root@luoahong1 ~]# docker push 192.168.228.135/library/busybox:latest
The push refers to repository [192.168.228.135/library/busybox]
683f499823be: Preparing
denied: requested access to the resource is denied
修改/etc/docker/daemon.json文件
[root@luoahong1 ~]# vim /etc/docker/daemon.json
"insecure-registries": ["192.168.228.135"]
2、推送成功
[root@luoahong1 ~]# docker login
Login with your Docker ID to push and pull images from Docker Hub. If you don't have a Docker ID, head over to https://hub.docker.com to create one.
Username: admin
Password:
Error: Password Required
[root@luoahong1 ~]# docker login 192.168.228.135
Username: admin
Password:
WARNING! Your password will be stored unencrypted in /root/.docker/config.json.
Configure a credential helper to remove this warning. See
https://docs.docker.com/engine/reference/commandline/login/#credentials-store Login Succeeded
[root@luoahong1 ~]# docker push 192.168.228.135/library/busybox:latest
The push refers to repository [192.168.228.135/library/busybox]
683f499823be: Pushed
latest: digest: sha256:bbb143159af9eabdf45511fd5aab4fd2475d4c0e7fd4a5e154b98e838488e510 size: 527
3、web界面截图

三、其他功能
1、两台hub同步

2、下载数量统计

3、下载加密

Docker:企业级私有仓库harbor[十六]的更多相关文章
- Kubernetes-5:搭建企业级私有仓库Harbor
搭建企业级私有仓库Harbor 安装需求 python版本 >= 2.7 Docker引擎版本 >= 1.10 docker-compose版本 >= 1.6.0 安装环境 一.Py ...
- 菜鸟系列docker——搭建私有仓库harbor(6)
docker 搭建私有仓库harbor 1. 准备条件 安装docker sudo yum update sudo yum install -y yum-utils device-mapper-per ...
- Docker: 企业级镜像仓库Harbor的使用
上一节,演示了Harbor的安装部署 这次我们来讲解 Harbor的使用. 我们需要了解到: 1. 如何推镜像到镜像仓库 2. 如何从镜像仓库拉取镜像 3. 如何运行从私有仓库拉取的镜像 # 查看 h ...
- Docker 企业级镜像仓库 Harbor 的搭建与维护
目录 一.什么是 Harbor 二.Harbor 安装 2.1.Harbor 安装环境 2.2.Harbor安装 2.3 配置HTTPS 三.Harbor 的使用 3.1.登录Harbor并使用 3. ...
- Docker: 企业级镜像仓库Harbor部署(http)
Harbor离线安装包下载地址:https://github.com/goharbor/harbor Docker compose(安装harbor需要用到docker compose)下载地址:ht ...
- docker企业级镜像仓库Harbor管理
Harbor概述 Harbor是由VMWare公司开源的容器镜像仓库.事实上,Harbor是在Docker Registry上进行了相应的企业级扩展,从而获得了更加广泛的应用,这些新的企业级特性包括: ...
- docker 搭建私有仓库 harbor
前提 已安装好 docker 和 docker-compose 环境:CentOS Linux release 7.5 docker 版本:18.09.05 1.安装harbor wget -P / ...
- docker企业级镜像仓库harbor
第一步:安装docker和docker-compose 第二步:下载harbor-offine-installer-v1.5.1.tgz 第三步:上传到/opt,并解压 第四步:修改harbor.cf ...
- Docker企业级镜像仓库harbor(vmware 中国团队)
第一步:安装docker和docker-compose 第二步:下载harbor-offline-installer-v1.3.0.tgz 第三步:上传到/opt,并解压 第四步:修改harbor.c ...
随机推荐
- c/c++ 重载运算符 关系,下标,递增减,成员访问的重载
重载运算符 关系,下标,递增减,成员访问的重载 为了演示关系,下标,递增减,成员访问的重载,创建了下面2个类. 1,类StrBlob重载了关系,下标运算符 2,类StrBlobPtr重载了递增,抵减, ...
- MFC打印
映射模式是MFC甚至SDK界面编程第1个难点.打印则是第2个难点.这2个都是历史遗留的设计缺陷.这些缺陷还不至于到bug程度,但却很难用,不易理解. MFC提供2个类来实现打印(预览),具体有CPri ...
- LeetCode算法题-Average of Levels in Binary Tree(Java实现)
这是悦乐书的第277次更新,第293篇原创 01 看题和准备 今天介绍的是LeetCode算法题中Easy级别的第145题(顺位题号是637).给定一个非空二叉树,以数组的形式返回每一层节点值之和的平 ...
- LeetCode算法题-Shortest Unsorted Continuous Subarray(Java实现)
这是悦乐书的第267次更新,第281篇原创 01 看题和准备 今天介绍的是LeetCode算法题中Easy级别的第134题(顺位题号是581).给定一个整数数组,找到一个连续的子数组,按升序对该子数组 ...
- equals方法相关总结
先说一下Object类吧: 这是一个号称为祖宗类的东西,是所有类的父类,也是唯一一个没有父类的类. 接口不继承object类 并且Object类存在于java的lang包中,我们都知道存在于lang包 ...
- 二 Struts2 接收数据
struts2绑定页面参数三种方式1.普通属性:在action中写与页面参数相同的属性名,然后set方法2.用对象来接收:在action中写一个对象,表单元素名改为:对象名.属性名3.用实现Model ...
- CF1012B Chemical table
$CF1012B Chemical table 给你一个 \(n\times m\) 的矩形,一开始有 \(q\) 个格子上被标记.对于任意两行两列,如果交汇的四个格子中有三个被标记,那么第 \(4\ ...
- 使用html2canvas.js实现页面截图并显示或上传
最近写项目有用到html2canvas.js,可以实现页面的截图功能,但遭遇了许多的坑,特此写一篇随笔记录一下. 在使用html2canvas时可能会遇到诸如只能截取可视化界面.截图没有背景色.svg ...
- Vue-移动端项目真机测试
一.查看ip地址 在控制台输入 ifconfig 查看ip地址 二.修改webpack-dev-server配置项 webpack-dev-server 默认不支持ip地址访问,需要修改配置项 三.测 ...
- Centos6.6安装docker
今天在虚拟机上体验一下docker, 操作系统:Centos6.6 内核版本:2.6 1. https://download.csdn.net/download/dujiaoyang000/10872 ...