Harbor在v1.6版本开始支持Helm Chart仓库功能,- 从v2.6.0 开始弃用Chartmuseum,并在v2.8.0中开始删除。更多详情,请参阅讨论:https://github.com/goharbor/harbor/discussions/15057 从 v2.6.0 开始弃用 Notary(签名者和服务器),并在 v2.8.0 中开始删除。更多详情,请参阅讨论:https://github.com/goharbor/harbor/discussions/16612
安装Chartmuseum组件
修改配置文件
在absolute_url参使用ChartMuseum组件时,客户端获取到的Chart的index.yaml中包含的URL是否为绝对路径。在不配置该项时,ChartMuseum组件会返回相对路径,默认为disabled。
$ vim harbor.yml
chart:
# Change the value of absolute_url to enabled can enable absolute url in chart
absolute_url: enabled
enabled表示使用绝对路径!
停止Harbor
$ docker-compose stop
注入配置
执行./prepare将新的配置注入到各个组件中。
$ ./prepare
安装chartmuseum
在执行install.sh安装时,通过--with-chartmuseum参数安装chart插件,安装完后会自动启动Harbor。
$ ./install.sh --with-notary --with-trivy --with-chartmuseum
✔ ----Harbor has been installed and started successfully.---- #输出该信息则表示安装成功
查看组件服务状态
通过docker-compose ps命令可以看到harbor的组件中多了个chartmuseum的容器。
$ docker-compose ps
验证是否安装了chartmuseum组件
登录Harbor UI管理界面:【项目】==>【library】==> 【Helm Charts】
References
- Helm基于Harbor中存储的chart快速发布服务
- [ Chartmuseum component deprecation proposal - effective 2.6.0 or 2.7.0 (see below for full proposed timeline) - feedback welcome #15057 ](https://github.com/goharbor/harbor/discussions/15057