We have the storage configurations from Tools>Communities>Storage Configuration, which is stored under /etc/socialconfig/srpc/defaultconfiguration, in our code in order to be able to simply deploy it on an AEM instance without the need to configure it manually via the UI on every instance.
The challenge is now that we need different configurations for different environments like author, publish, DEV, QA, PROD ...
Is there a way to achieve that, just like it can be done with the OSGI configurations?
One possible solution could be to configure those values in environment variables, commit the file (/etc/socialconfig/srpc/defaultconfiguration) with environment variable names in it and update your build scripts to inject the variable values in that file at build time and package post that.
It would be similar to envInject in Jenkins: https://plugins.jenkins.io/envinject/
I hope this helps.