将工件存储库连接到 Nexus

发布于 2024-12-20 08:10:48 字数 292 浏览 0 评论 0原文

我所在的组织同时存在多项开发工作。我的项目正在使用 Nexus 来管理我们的 Maven 存储库,还有另一个小组使用 Artifactory 来满足他们的 Maven 需求。我正在尝试设置一个指向快照存储库的代理,但遇到了问题。当我尝试配置代理时,状态显示为“远程自动阻止且不可用”。

我在使用其他代理时没有遇到任何问题,因此我认为我的 Nexus 设置基本上没问题。有谁知道指向 Artifactory 存储库需要额外的 Nexus 配置吗?相反,是否需要进行一些 Artifactory 调整才能允许 Nexus 使用它?

预先感谢!

I'm in an organization with multiple development efforts existing in parallel. My project is using Nexus to manage our Maven repository, and there's another group using Artifactory for their Maven needs. I'm trying to set up a proxy that points to their repository for snapshots, and am running into problems. When I try to configure the proxy, the status comes up as "Remote Automatically Blocked and Unavailable."

I'm not having troubles with any of the other proxies, so I think that my Nexus setup is basically okay. Does anyone know of additional Nexus configuration needed to point to an Artifactory repository? Conversely, is there some Artifactory tweaking needed to allow its use by Nexus?

Thank in advance!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

小ぇ时光︴ 2024-12-27 08:10:48

Artifactory URL 很可能不正确。 Artifactory 使用 200 应答 HEAD 请求。
如果存储库 URL 中没有尾部斜杠,Artifactory 将使用 302 进行应答,重定向到以斜杠结尾的 URL(可能 Nexus 不遵循这一点)。因此,最简单的方法是在代理配置中使用斜杠结尾的 URL。

顺便说一句,两端都拥有 Artifactory 允许您使用复制在远程工件可用时立即将其获取到缓存中。

Most likely the Artifactory URL is incorrect. Artifactory answers a HEAD request with 200.
If you do not have a trailing slash in the repo URL Artifactory will answer with a 302 that redirects to the slash-ending URL (probably Nexus doesn't follow this). So the easiest way is to use a slash-ending URL in the proxy configuration.

BTW, having Artifactory at both ends allows you to use replication to eagerly fetch remote artifacts to your caches as they become available.

冷情 2024-12-27 08:10:48

我最终通过将身份验证选项(用户名和密码)设置为 Artifactory 存储库识别的值来使代理正常工作。 Artifactory URL 还存在一些繁琐的细节,需要经过几次迭代才能解决。感谢您的回复;他们引发了一些想法 - 特别是 Artifactory URL 出现问题的可能性。

I finally got the proxy working by setting the Authentication options (username and password) to values that the Artifactory repository recognized). There were also some fussy details with the Artifactory URL that took a couple of iterations to sort out. Thanks for the responses; they sparked some ideas - particularly the likelihood of a problem with the Artifactory URL.

缺⑴份安定 2024-12-27 08:10:48

Nexus 通过对远程存储库的根执行 HEAD 请求来检查存储库可用性。出于某种原因,Artifactory 似乎没有返回 200(也许他们不支持)。您可以关闭此存储库的代理设置检查,这样就不会发生这种情况。或者您可以说服他们使用 Nexus ;-)

Nexus is checking for repo availability by doing a HEAD request against the root of the remote repository. It seems that Artifactory isn't returning a 200 to this for some reason (maybe they don't support it). You can turn off the checking in the proxy settings for this repository so this won't happen. Or you could convince them to use Nexus ;-)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文