The use case is to include a custom user as part of a content package. The user abc ('/home/users/system/abc/‘) which is under a group ‘everyone’ has all permissions only on ‘/content/projects’ node. I don’t want to include '/content/projects/rep:policy’ as part of the package as there might be some other permissions already present on the ‘projects’ node. Is there any other way to include this user in the content package?
Thanks
Dipti
Check ACL packager.
Link:- https://adobe-consulting-services.github.io/acs-aem-commons/features/acl-packager.html
//
Purpose
Frequently, access control entries need to be copied from one environment to another without copying the actual content itself, just the access control entries. This user interface allows you to define and build packages containing access control entries for particular paths and/or particular principals.
Reference articles:-
I hope this would help you.
~kautuk
Views
Replies
Total Likes
I tried it out , it does grab all the user permissions but I have a specific use case : If the user has permissions in /content i.e there is node "allow2" of jcr:primaryType "rep:GrantAce" , so using ACS ACL packager will build the /content/rep:policy node in the content package.
What if the new instance in which I want to install my package already has a "allow2" node under /content/rep:policy (containing permissions for some other user ), in this use case I would get an error "Error: org.apache.jackrabbit.vault.packaging.PackageException: javax.jcr.nodetype.ConstraintViolationException: Item is protected."
while installing the package.
Is there any other way to grab permissions so that it does not collide with other permission when I install my package
Views
Replies
Total Likes
Views
Replies
Total Likes
No I haven't.
Nupur
Views
Replies
Total Likes
HI,
@Kutuk pointed out. ACL tool to grab all the permissions of al the users. That is the recommended approach.
Regards,
Jitendra
Views
Replies
Total Likes
Views
Replies
Total Likes
Try adding a user to you package and ensure you have .content.xml and _rep_policy.xml with
<?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:all]"/>
</jcr:root>
Hi Dipti,
While installing the package use merge option .
Thanks,
diptinarang nupurjain Check the comments from MC Stuff.
// While installing use merge option.
~kautuk
Views
Replies
Total Likes