Harbor私有仓库搭建

Posted Joeyxx7000

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Harbor私有仓库搭建相关的知识,希望对你有一定的参考价值。

简介

安装方式

1、Harbor离线安装包,github地址为: https://github.com/goharbor/harbor/releases/tag/v2.0.6 可选择适合自己项目需求的版本,建议选择离线安装包。

2、将其下载好的安装包,解压后会发现。打开common.sh脚本文件,可查看当前harbor版本安装环境条件。及其所需的安装软件以及版本号

#!/bin/bash
#docker version: 17.06.0+
#docker-compose version: 1.18.0+
#golang version: 1.12.0+

3、Harbor所需环境搭建好后,修改配置文件harbor.yml.tmpl,将其重命名为harbor.yml
需要修改配置文件的地方为,现在以Http访问方式作为例子

# Harbor域名运行环境,不能通过localhost与127.0.0.1来作为Harbor来使用
hostname: 210.210.210.20

# http 访问设置 
http:
  # port for http, default is 80. If https enabled, this port will redirect to https port
  port: 8081

# https 访问设置,需要配置访问证书
# https:
#   # https port for harbor, default is 443
#   port: 443
#   # The path of cert and key files for nginx
#   certificate: /your/certificate/path
#   private_key: /your/private/key/path

# Harbor 应用默认账号admin的账号密码
# Remember Change the admin password from UI after launching Harbor.
harbor_admin_password: Harbor12345

4、将其上述软件安装成功后,在其终端服务器上执行命令

# Harbor安装环境预处理
[root@localhost harbor]# ./prepare 
# 在就是安装Harbor应用
[root@localhost harbor]# sh install.sh

以上是关于Harbor私有仓库搭建的主要内容,如果未能解决你的问题,请参考以下文章

Docker------搭建本地私有仓库及Horbor私有仓库

搭建本地Docker私有仓库 与 Harbor私有仓库的部署与管理

使用Harbor搭建企业级私有docker仓库

Harbor私有仓库搭建

私有仓库 Harbor 的搭建

Docker私有仓库