我们正在将人工制品6.0.3作为容器(以及nginx和postgresql)在容器上运行,如将人工制品作为docker实例运行中所述。
我已经设置了基本的“ docker”实例。
与工件容器在同一台机器上本地
# docker login localhost:8081
Username: test
Password:
Login Succeeded
但是,使用nginx端口:
# export DOCKER_OPTS=" --insecure-registry docker-local.artifactory.company.com"
# docker login -u test --password-stdin artifactory.company.com
Error response from daemon: Get https://artifactory.company.com/v2/: unknown: Unsupported docker repository request for 'v2'
我还尝试将〜/ .docker / config.json与身份验证信息(base64)一起使用,但是它仍然给我同样的错误。
artifactory.log显示:
2018-06-21 13:25:48,088 [http-nio-8081-exec-3] [ERROR] (o.a.a.d.r.DockerResource:425) - Unsupported docker repository request for 'v2'
access.log显示:
2018-06-21 13:25:48,089 [DENIED LOGIN] for test/172.19.0.4
request.log显示:
20180625075813|1|REQUEST|172.19.0.2|_internal|GET|/api/system/configuration/reverseProxy/nginx|HTTP/1.1|404|0
20180625075823|1|REQUEST|172.19.0.2|_internal|GET|/api/system/configuration/reverseProxy/nginx|HTTP/1.1|404|0
20180625075823|1|REQUEST|10.15.9.4|non_authenticated_user|GET|/api/docker//v2/|HTTP/1.0|401|0
20180625075823|2|REQUEST|10.15.9.4|non_authenticated_user|GET|/api/docker/v2/token|HTTP/1.0|400|0
[请注意,对verseProxy行的_internal请求每10秒重复一次,所有404 ==我已经确认“ Http设置”设置为“存储库路径”和“内部Tomcat”。]
编辑2:
从nginx添加access.log:
ip = 10.15.53.21 user = "-" local_time = "27/Jun/2018:11:28:36 +0000" host = artifactory.company.com request = "GET /v2/ HTTP/1.1" status = 401 bytes = 87 upstream = "172.19.0.3:8081" upstream_time = 0.001 request_time = 0.001 referer = "-" UA = "docker/18.03.1-ce go/go1.9.5 git-commit/9ee9f40 kernel/3.10.0-862.3.3.el7.x86_64 os/linux arch/amd64 UpstreamClient(Docker-Client/18.03.1-ce \x5C(linux\x5C))"
ip = 10.15.53.121 user = "test" local_time = "27/Jun/2018:11:28:36 +0000" host = artifactory.company.com request = "GET /artifactory/api/docker//v2/token?account=test&client_id=docker&offline_token=true&service=artifactory.company.com%3A443 HTTP/1.1" status = 400 bytes = 122 upstream = "172.19.0.3:8081" upstream_time = 0.001 request_time = 0.001 referer = "-" UA = "docker/18.03.1-ce go/go1.9.5 git-commit/9ee9f40 kernel/3.10.0-862.3.3.el7.x86_64 os/linux arch/amd64 UpstreamClient(Docker-Client/18.03.1-ce \x5C(linux\x5C))"
答案 0 :(得分:0)
答案是来自@mcgurksean的github上的自定义代理配置。
https://github.com/jfrog/artifactory-docker-examples/issues/86#issuecomment-421031928
此外,您还必须阻止Artifactory重新生成nginx配置文件,请从github上的@ jainishshah17答复。
https://github.com/jfrog/artifactory-docker-examples/issues/86#issuecomment-422849718