We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
制品库是承接CI构建后的产出制品的仓库, 具有版本管理,历史管理,权限校验等功能。
在这里,我们选用 Nexus3 作为制品库。
docker pull sonatype/nexus3
创建nexus文件夹,用来存放 nexus 相关数据
nexus
mkdir /home/nexus && chown -R 200 /home/nexus
启动容器
docker run -d -p 8081:8081 -p 8082:8082 \ --name nexus \ -v /home/nexus:/nexus-data \ --restart always \ sonatype/nexus3
Nexus 的主服务端口是8081,但 Nexus Docker 制品库还需要分配一个新的端口作为服务端口。 这里没有演示分配哪个端口,想分配自己加 -p 参数即可。在这里我使用8082作为 docker 服务端口
firewall-cmd --zone=public --add-port=8081/tcp --permanent firewall-cmd --zone=public --add-port=8082/tcp --permanent
我们通过8081打开nexus页面之后,需要登录,默认账号是admin,密码这样获取
admin
cat /home/nexus/admin.password
我们的私有制品库制作完成之后,我们需要连接登录一下
vim /etc/docker/daemon.json
添加insecure-registries字段
insecure-registries
{ "insecure-registries" : [ "xxxxx:8082" ], }
保存退出,重启 Docker
systemctl restart docker
接着使用 docker login 命令尝试登录:
docker login
docker login 服务IP:端口
这里有个小坑,需要nexus配置一下,不然连接不上
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Nexus 制品库的介绍与安装
介绍
制品库是承接CI构建后的产出制品的仓库, 具有版本管理,历史管理,权限校验等功能。
在这里,我们选用 Nexus3 作为制品库。
安装
拉取 Neuxs 镜像
启动 Nexus 容器
创建
nexus
文件夹,用来存放nexus
相关数据启动容器
Nexus 的主服务端口是8081,但 Nexus Docker 制品库还需要分配一个新的端口作为服务端口。 这里没有演示分配哪个端口,想分配自己加 -p 参数即可。在这里我使用8082作为 docker 服务端口
添加防火墙
配置 Nexus
我们通过8081打开
nexus
页面之后,需要登录,默认账号是admin
,密码这样获取登录制品库
我们的私有制品库制作完成之后,我们需要连接登录一下
添加
insecure-registries
字段保存退出,重启 Docker
接着使用
docker login
命令尝试登录:这里有个小坑,需要nexus配置一下,不然连接不上
The text was updated successfully, but these errors were encountered: