如何通过Maven部署rep:policy文件? [英] How to deploy rep:policy files via maven?
问题描述
我为/home/groups和/home/users添加了一些额外的ACL,方法是为每个文件添加_rep_policy.xml文件,但似乎无法部署它们.我在保险库文件filter.xml中添加了以下几行
I've added some extra ACLs to /home/groups and /home/users by adding _rep_policy.xml files for each, but can't seem to get them to deploy. I added the following lines to my vault filter.xml
<filter root="/home/users/rep:policy" mode="replace"/>
<filter root="/home/groups/rep:policy" mode="replace"/>
两者都具有这样的内容:
Both have contents like this:
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:rep="internal"
jcr:primaryType="rep:ACL">
<allow
jcr:primaryType="rep:GrantACE"
rep:principalName="everyone"
rep:privileges="{Name}[jcr:read]"/>
</jcr:root>
但是当我运行maven时,我可以看到它们周围的所有东西都已部署,但是没有这两个.如果我尝试直接通过程序包管理器安装程序包,则仅当我将访问控制处理设置为替换"时,它才有效.我不知道如何在Maven中配置它.
But when I run maven, I can see everything around them get deployed, but not these two. If I try to install the package directly through package manager, it works only if I set Access Control Handling to "Replace". I don't know how to configure this in maven.
推荐答案
软件包属性是在POM中的Vault插件的配置部分中配置的.要在软件包中启用ACL导入,请将以下配置添加到POM
The package properties are configured in the configuration section of vault plugin in POM. To enable ACL import in the package add the below configurations to the POM
<configuration>
<properties>
<acHandling>Overwrite</acHandling>
</properties>
</configuration>
Vault插件的文档位于 http://docs.adobe.com/docs/en/cq/5-6-1/core/how_to/how_to_use_the_vlttool/vlt-mavenplugin.html
The documentation for the vault plugin is at http://docs.adobe.com/docs/en/cq/5-6-1/core/how_to/how_to_use_the_vlttool/vlt-mavenplugin.html
这篇关于如何通过Maven部署rep:policy文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!