这个问题通常会出现在使用Artifactory时,由于缺少“eventual”二进制提供商而导致。解决这个问题的步骤包括:
curl -X POST -u admin:password "http://localhost:8081/artifactory/api/plugins/execute/createBinaryProvider?params=repoKey=eventual-binary-provider&providerName=eventual"
curl -u admin:password "http://localhost:8081/artifactory/api/plugins/execute/getBinaryProviders"
应该会返回一个JSON对象,其中包含一个名为“eventual-binary-provider”的项目。
在Artifactory用户界面中导航到“Admin”->“Repositories”->“Repositories”,然后选择你想要在其中添加“eventual”二进制提供商的存储库。在存储库属性中找到“Binary Providers”下的“Provider Name”,并从下拉菜单中选择“eventual”。
如果你想要在构建中使用“eventual”二进制提供商,你需要将它作为构建工具的一部分添加到你的构建脚本中。例如,如果你正在使用Gradle构建:
buildscript {
repositories {
maven {
url 'http://localhost:8081/artifactory/eventual-binary-provider'
credentials {
username = "${artifactory_user}"
password = "${artifactory_password}"
}
}
}
}
在构建脚本的其余部分中,你应该能够使用“eventual”二进制提供商来下载任何你需要的依赖项。