如何防止以前部署的工件被覆盖? [英] How can I prevent previously deployed artifacts from being overwritten?

查看:69
本文介绍了如何防止以前部署的工件被覆盖?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们将Artifactory用于我们公司的Maven存储库.有没有一种方法可以设置它(或设置Maven),以便在存在相同版本号的工件时不能将其部署到存储库中?

We use Artifactory for our company's Maven repository. Is there a way to set it up (or set Maven up) so that an artifact can't be deployed to the repository if there is a pre-existing artifact with the same version number?

这样做的原因是要确保有效的发行版本不会意外被覆盖.如果确实需要重新部署工件,那么我们的开发人员之一可以使用Artifactory Web界面将其删除.然后他们可以部署新副本.

The reasoning for this is to make sure that valid releases don't accidentally get overwritten. If an artifact really does need to be re-deployed, one of our developers can use the Artifactory web interface to delete it. Then they can deploy the new copy.

谢谢!

推荐答案

这很容易通过从目标存储库上的部署用户\组中撤消删除"权限来实现.删除工件和重新部署工件都需要具有删除权限.

This is easily achieved by revoking the "Delete" permission from the deploying users\groups on the target repository; the delete permission is required for both artifact removal and artifact re-deployment.

所有用户\组权限都可以在用户界面的 Admin-> Security-> Permissions 中进行编辑.
另请参见管理权限

All user\group permissions are editable within the UI at Admin->Security->Permissions.
Also see Managing Permissions

这篇关于如何防止以前部署的工件被覆盖?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆