Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

What is the best way to export and import OSGI configurations from one environment to other?

KotiSyamala1
Level 2
Level 2

Hi Team,

 

I'm not sure we are not storing OSGI configurations in node structure it's always saves under launchpad

can you please help me is there a better way to export selected OSGI Configuration from one AEM instance to other?

 

Thanks,

Koti.

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution
Ankur_Khare
Correct answer by
Community Advisor
Community Advisor

Best way to store environment specific configuration in config folders specific to an environment like below-

 

/apps/project/config

/apps/project/dev.author.config

/apps/project/dev.publish.config

 

Environment runmodes needs to be used to create environment specific folders.

In this way your environment specific config will move automatically.

View solution in original post

9 Replies
Ankur_Khare
Correct answer by
Community Advisor
Community Advisor

Best way to store environment specific configuration in config folders specific to an environment like below-

 

/apps/project/config

/apps/project/dev.author.config

/apps/project/dev.publish.config

 

Environment runmodes needs to be used to create environment specific folders.

In this way your environment specific config will move automatically.

View solution in original post

KotiSyamala1
Level 2
Level 2
Thanks for quick answer @Ankur_Khare, but we the configurations are not saved under /apps/project/config all the configurations updated using the OSGI console are saved under launch pad not under config
Arun_Patidar
Community Advisor
Community Advisor
it is stores under /apps/system/config or /apps/sling/config
Veena_Vikram
Community Advisor
Community Advisor

Always make sure to have a custom config node for your configurations under your apps. For now the existing one , can you package it ? 

KotiSyamala1
Level 2
Level 2
Hi @Veena_Vikram, The challenge is that if we update OSGI configurations in the filix console it's not reflecting on node of config, we end up taking old config package
Veena_Vikram
Community Advisor
Community Advisor
So you have a custom config node, but when you update it via felix console , it is not getting saved under your config ?
Veena_Vikram
Community Advisor
Community Advisor

I am exactly not sure exactly how you are modifying the configurations, because as per my understanding, if you have a config under your apps config folder, then when you modify it via system console, it shud get saved under the same path or else if no specific path is mentioned, it will get saved under system folder. But might be this https://stackoverflow.com/a/42340483 reply might help you in solving your issue .

 

Also here is the official documentation https://docs.adobe.com/content/help/en/experience-manager-65/deploying/configuring/configuring-osgi.... and it clearly says 

 

"

You must never edit the folders or files under:
/crx-quickstart/launchpad/config
"
Theo_Pendle
Community Advisor
Community Advisor

Hi @KotiSyamala1,

As you mentioned in a comment to @Veena_Vikram, if you update a configuration it is not automatically appearing in your application config.

This is because by default, configurations are saved under /apps/system/config.

Here is an example. My config on a (relatively) fresh AEM 6.5 instance:

theop76211228_0-1588963934128.png

 

And now I if I modify the com.adobe.granite.ui.clientlibs.impl.HtmlLibraryManagerImpl config as so (enabling code minification):

Selection_142.png

Now my configs under /apps/system/config are updated:

Selection_141.png

It's up to you at this point to add the file to your project (under /apps/yoursite/config) and deploy it to AEM.

Hope this helps 🙂

Jörg_Hoh
Employee
Employee

A general guideline: It has always been best practice to maintain all OSGI configurations (the ones deviating from the default configuration) in a version control system, typically along side to your code. Because this does prevent situations like yours where you struggle with knowing what you have actually changed in that environment.