Hi Team,
We have developed custom widgets in ArcGIS Experience Builder Developer Edition. Each widget has its own settings widget. We are deploying through pipeline and used below command in pipeline.
node -e "require('./server/src/middlewares/dev/apps/app-download.js').zipApp('0', 'app.zip', 'my_client_id');"
All the widgets and app at 0 index is configured and saved in builder for one environment for eg., Dev. How can we automate changing all these configurations to move to other environments such as SIT, UAT, Prod.
Do we need to manually configure widgets and use those app ids in pipeline based on environment? or any best/better way, please suggest.
Thanks in advance!
With Regards.
Hi, the zipApp() supports "configModifier" param, you can use it to modify your config for different environments, please see https://developers.arcgis.com/experience-builder/guide/deployment-topics/#automated-deployments
There are some samples in your download package at server/download-app.js file.
Thanks for the response @JunshanLiu .
I did not identify how to update every widgets configs in this approach. Could you please provide me more insights. I have gone through server/download-app.js file, but did not get idea on how to update configs of every widget at deployment time for different environments.
Thanks in advance
The "configModifier" can be a function, which receives the appConfig param, then you get all widgets by "appConfig.widgets", then you can modify your widgets and return the modified appConfig.
Hi @JunshanLiu ,
Thanks for the response. In my settings widgets, I have multiple "DataSourceSelector" settings in each widget not just simple datatype. So, Could you please give me some sample how to update this "DataSourceSelector" for different environments for deployment through pipeline.
Thanks in advance!