コミュニティアチーブメントバーを展開する。

Submissions are now open for the 2026 Adobe Experience Maker Awards.

Mark Solution

この会話は、活動がないためロックされています。新しい投稿を作成してください。

解決済み

Custom cloud config in aemaacs

Avatar

Level 1

We're migrating to aemaacs from AEM 6.5. We have a custom cloud configuration in place for datalayer. We followed this guide - https://experienceleague.adobe.com/docs/experience-manager-64/developing/extending-aem/extending-clo... in initial setup. 
Is there any such guide for aemaacs? We're not able to get the existing config work for cloud publisher. While running repoinit script to set ACL for anonymous user we're facing PathNotFoundException for /etc/cloudservices/*.

Any help appreciated.
Thanks!

1 受け入れられたソリューション

Avatar

正解者
Community Advisor

hello @vmanohar23 

 

repo-init scripts execute at the time of deployment on AEM Images. Thus, they are capable of setting permissions on both mutable and immutable paths.

 

The repo-init can set ACL only if a node already exists. Thus, if we receive PathNotFoundException, it means that /etc/cloudservices/* isn't available when repo-init is executing, during deployment

 

To resolve the same, create these paths with proper primaryType via repo-init. This would assure that the path is available, while setting ACLs. Example:

 

 

{
    "scripts": [
"create path /etc/cloudservices(sling:Folder)\n\n",
"create path /etc/cloudservices/aemdatalayer(cq:Page)\n create path /etc/cloudservices/aemdatalayer/jcr:content(cq:PageContent)\n\n",
"set ACL on /etc/cloudservices/aemdatalayer\n\tallow jcr:read for \"anonymous\"" ] }

 


Aanchal Sikka

元の投稿で解決策を見る

4 返信

Avatar

Community Advisor

Hi @vmanohar23 ,

Can you just pass script from init if possible?

Regards,

Santosh


Santosh Sai

AEM BlogsLinkedIn


Avatar

Level 1
{
    "scripts": [
        "set ACL on /etc/cloudservices/aemdatalayer\n\tallow jcr:read for \"anonymous\""
    ]
}

This is under config.publish by name org.apache.sling.jcr.repoinit.RepositoryInitializer~<project-name>.cfg.json

Avatar

Community Advisor

@vmanohar23 - 

The problem would be because the repo init statements mention mutable content in the documentation[0].

/apps and /libs are immutable at runtime and ACLs are stored under the respective nodes that need the permission in AEM. 

shivanigarg111_0-1618544020728.png

[0]: https://experienceleague.adobe.com/docs/experience-manager-learn/cloud-service/developing/basics/mut...

 


Santosh Sai

AEM BlogsLinkedIn


Avatar

正解者
Community Advisor

hello @vmanohar23 

 

repo-init scripts execute at the time of deployment on AEM Images. Thus, they are capable of setting permissions on both mutable and immutable paths.

 

The repo-init can set ACL only if a node already exists. Thus, if we receive PathNotFoundException, it means that /etc/cloudservices/* isn't available when repo-init is executing, during deployment

 

To resolve the same, create these paths with proper primaryType via repo-init. This would assure that the path is available, while setting ACLs. Example:

 

 

{
    "scripts": [
"create path /etc/cloudservices(sling:Folder)\n\n",
"create path /etc/cloudservices/aemdatalayer(cq:Page)\n create path /etc/cloudservices/aemdatalayer/jcr:content(cq:PageContent)\n\n",
"set ACL on /etc/cloudservices/aemdatalayer\n\tallow jcr:read for \"anonymous\"" ] }

 


Aanchal Sikka