The Ionic CLI currently supports the --configuration parameter on ionic cordova prepare.
https://ionicframework.com/docs/cli/commands/cordova-prepare#advanced-options
It looks like there was already a PR to include this, but it was never merged:
#51
Is there any plans to merge this?