Expand my Community achievements bar.

SOLVED

What is the best way to re-sync AEM with latest content from production?

Avatar

Level 7

We have production, staging, qa, and dev cloud environments. We want to re-sync all the content from production to staging, qa, and dev. What is the best way for us to do this in an automated way?

1 Accepted Solution

Avatar

Correct answer by
Level 2

Hi @AEMWizard  since you are asking automated way.One suggestion i can provide is to use the crx2oak tool from server shell script and schedule it using cron job to sync between repositories

https://experienceleague.adobe.com/docs/experience-manager-65/deploying/upgrading/using-crx2oak.html...

 

Example:

Create script.sh file using java - Crx2oak script and schedule that script in crontab

 

 

crontab -e

add an entry

0 10 * * * sh your_script.sh > your_log_fi 

 

View solution in original post

3 Replies

Avatar

Correct answer by
Level 2

Hi @AEMWizard  since you are asking automated way.One suggestion i can provide is to use the crx2oak tool from server shell script and schedule it using cron job to sync between repositories

https://experienceleague.adobe.com/docs/experience-manager-65/deploying/upgrading/using-crx2oak.html...

 

Example:

Create script.sh file using java - Crx2oak script and schedule that script in crontab

 

 

crontab -e

add an entry

0 10 * * * sh your_script.sh > your_log_fi 

 

Avatar

Employee Advisor

There are different ways to do it based on

1. how frequent you need the re-sync

2. how big is your repository

3. How is your infrastructure deployment 

 

There is a decision making diagram published in a white paper by Adobe and is referenced at https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/aem-author-to-author-conte... on which is the best way to sync it. 

Once you are clear on what and how you want to sync, then we can choose how to automate it. As mentioned in other answers, crx2oak tool provides a way to migrate data between two repositories. If you are on a cloud infrastructure, it might be easier with a backup process in the cloud setup, eg. snapshots in AWS and control the specifics using env configurations while start up. 
If you are a datacenter hosted on-prem solution and if you are okay with offline clone, it might be as simple as zipping the crx-quickstart folder and copying over with a script. 
If the content sync is incremental on a daily basis, you can select package based replication and make use of https://adobe-consulting-services.github.io/acs-aem-commons/features/automatic-package-replicator/in...
There are many open source wrapper tools which can provide you better interface, resilience and performance for online sync eg https://github.com/TWCable/grabbit 
As a disclaimer, a full sync of an online instance with a huge repo always has a risk of corruption, so select your sync strategy based on your needs and then automate it.