我为公证人设置了以下基础设施:
- 公证服务器
- 公证人
- 使用 docker-compose 的“公证服务器”和“公证签名者”的 mariadb 数据库。
我想使用我的私有 docker 注册表(nexus),它部署在不同的机器上,并带有我已经启动并运行的公证基础设施。
你能告诉我一步一步的过程吗?
我正在扩展我的发现:
我正在尝试使用此链接https://github.com/theupdateframework/notary中提供的说明设置我自己的公证服务
我做了什么:
git clone https://github.com/theupdateframework/notary.git
cd notary
3 )$ docker-compose build
$ docker-compose up -d
执行上述步骤后,我在我的 docker 主机上启动并运行了 3 个容器(在本地笔记本电脑上运行 -Ubuntu16.04)
- 公证服务器
- notary_signer
- 玛丽亚数据库:10.1.28
现在,为了将我的本地公证服务与私有注册表关联(作为容器托管在其他机器上)一起使用,我已经完成了以下步骤:
/etc/hosts entry
127.0.0.1 notary-server
mkdir -p ~/.notary && cp cmd/notary/config.json cmd/notary/root-ca.crt ~/.notary
在此之后,我使用以下命令测试了连接并成功。
openssl s_client -connect :4443 -CAfile fixtures/root-ca.crt -no_ssl3 -no_ssl2
现在为了签署图像并将其推送到私有注册表,我设置了以下环境变量。
DOCKER_CONTENT_TRUST_SERVER=https://notary-server:4443
DOCKER_CONTENT_TRUST=1
问题:当我发出如下所示的 docker push 命令时
sudo docker push nexus.xyz.com:5000/nginx:latest (我之前做过适当的标记)
它不经过签名,它直接将图像推送到私有注册表
但是当我使用
sudo docker push --disable-content-trust=false nexus.xyz.com:5000/nginx:latest
它签署了图像并推送,但在我使用时不显示任何受信任的内容
notary list nexus.xyz.com:5000/nginx:latest
问题:我需要做任何其他配置才能使用我自己的公证服务吗?
任何帮助将非常感激。