Manage Publication only to preview server | Community
Skip to main content
Level 2
January 18, 2023
Solved

Manage Publication only to preview server

  • January 18, 2023
  • 3 replies
  • 1129 views

In AEMaaCS, is there a way we can restrict authors to publish only to preview server instead of the publish instance?

 

We have enabled preview instance for our client so under the "Manage Publication" screen, the authors are able to (un)publish to both "Preview" and "Publish" instance. We dont want to authors to accidentally publish to "Publish" instance before publishing to "Preview" instance

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by SRK_1D

This depends on the access rights that are available for your author group. If your author group doesnt have access to replicate contents, you will have to write a custom workflow step where in a system user with replication access will publish the contents to preview on the author's behalf. 

 

If the author group has the necessary replication access, then you can simply customize the manage publication wizard to trigger the OOTB activation process. 

 

https://experienceleague.adobe.com/docs/experience-manager-64/developing/extending-aem/customizing-page-authoring-touch.html?lang=en#customizing-the-request-for-activation-workflow

3 replies

B_Sravan
Community Advisor
Community Advisor
January 19, 2023

I would suggest triggering a workflow whenever an attempt is made to publish instances so as to avoid any accidental pushes.


SRK_1D
SRK_1DAccepted solution
Level 2
January 23, 2023

This depends on the access rights that are available for your author group. If your author group doesnt have access to replicate contents, you will have to write a custom workflow step where in a system user with replication access will publish the contents to preview on the author's behalf. 

 

If the author group has the necessary replication access, then you can simply customize the manage publication wizard to trigger the OOTB activation process. 

 

https://experienceleague.adobe.com/docs/experience-manager-64/developing/extending-aem/customizing-page-authoring-touch.html?lang=en#customizing-the-request-for-activation-workflow

fmateen
Level 2
November 26, 2023

The simple solution will be to create a custom workflow "Publish to Preview". Advise the authors to always use that workflow instead of OOTB publish/unpublish functionality. 

Also you will have to remove the "replicate" permission of the content authors so that they shall not be able to publish directly. 

 

The more advance solution is to implement custom code to catch replication events and display a confirmation  dialog for the users to ask whether they want to publish to preview or want to publish to external publisher.