You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there a way to copy file specific permissions and/or include unique site permissions when using Get-PnPSiteTemplate? I've tried including the siteSecurity handler but it only includes permissions on site level and it didn't unique permissions. I've also edited the XML file and added the Security element inside the File element and specified only the owner group as seen in the code below, but it didn't work. After applying the template to the target site, Members have Edit permission on the file, and Visitors have Read permission, as is default on Team sites. <pnp:File Src="Shared Documents/forms.office.com.url" Folder="Shared Documents" Overwrite="true" Level="Published"> <pnp:Security> <pnp:BreakRoleInheritance CopyRoleAssignments="true" ClearSubscopes="false"> <pnp:RoleAssignment Principal="{associatedownergroupid}" RoleDefinition="Full Control" /> </pnp:BreakRoleInheritance> </pnp:Security> </pnp:File>
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Is there a way to copy file specific permissions and/or include unique site permissions when using Get-PnPSiteTemplate? I've tried including the siteSecurity handler but it only includes permissions on site level and it didn't unique permissions. I've also edited the XML file and added the Security element inside the File element and specified only the owner group as seen in the code below, but it didn't work. After applying the template to the target site, Members have Edit permission on the file, and Visitors have Read permission, as is default on Team sites.
<pnp:File Src="Shared Documents/forms.office.com.url" Folder="Shared Documents" Overwrite="true" Level="Published"> <pnp:Security> <pnp:BreakRoleInheritance CopyRoleAssignments="true" ClearSubscopes="false"> <pnp:RoleAssignment Principal="{associatedownergroupid}" RoleDefinition="Full Control" /> </pnp:BreakRoleInheritance> </pnp:Security> </pnp:File>
Beta Was this translation helpful? Give feedback.
All reactions