Altering external configuration file location after a war has been created?
I have a requirement to allow users to specify the location of their own external configuration file for a war file to look for.
Looking through the documentation and several sources I haven't seen a way to this. All the examples I have seen have a number of values hardcoded in config.groovy for the application to look for configuration files in.
Is there any method avaiable for changing these locations? I wouldn't expect that their is as these locations are specified before the war is built.
So as far as I can see I have a number of options :
1) Create a new war every time a customer wants the location of their configuration file to change (Definitely not ideal)
2) Hard code a number of location values and have the user put their configuration there. I wonder is this reasonable? Have people on other projects taken this approach?
3) Have a build script that the customer uses when they deploy the war that copies their configuration file to somewhere in the web-app that has its location hard coded (I'm not sure if this would work but I can't see why it wouldn't)
I'd be interested to hear how other people have addressed this issue in the past?