匹配神器存储库中的多个路径
因此,我尝试编写一个 search_spec.json 文件来排除路径为 */latest 或 */develop 的所有 docker 映像(在我的工件存储库中)。但是,我找不到从搜索结果中排除多个路径的解决方案。使用当前的解决方案,我从神器中得到了 400 。有什么想法吗?
{
"files":[
{
"aql":{
"items.find":{
"repo":{
"$eq":"my-docker-repo"
},
"path":{
"$nmatch":"**/latest*",
"$nmatch":"**/develop*"
},
"updated":{
"$before":"8w"
},
"stat.downloaded":{
"$before":"12w"
}
}
},
"recursive":"true",
"sortBy":[
"created"
],
"limit":10000
}
]
}
So I'm trying to write a search_spec.json file to exclude all docker images with path */latest or */develop im my artifactory repo. However I cannot find a solution to exclude multiple paths from the search results. With the current solution I'm getting a 400 from artifactory. Any ideas?
{
"files":[
{
"aql":{
"items.find":{
"repo":{
"$eq":"my-docker-repo"
},
"path":{
"$nmatch":"**/latest*",
"$nmatch":"**/develop*"
},
"updated":{
"$before":"8w"
},
"stat.downloaded":{
"$before":"12w"
}
}
},
"recursive":"true",
"sortBy":[
"created"
],
"limit":10000
}
]
}
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以使用复合标准,使用
$and
运算符。在您的示例中,将 - 更改
为 -
You can use compound criteria for that, using an
$and
operator.In your example, change -
to -