I'm using MSDeploy to change the web.config of my service at deployment time. This works great except that now I'm developing a Lightswitch app which generates its own parameters.xml file. So while I can configure the Lightswitch specific parameters at deploy time I haven't figured out a way to inject my own parameters. I can of course modify the parameters.xml after publishing. Is there a more straight forward way to tell Lightswitch to include my parameters?
In a standard ASP.NET web application project you can simply add a parameters.xml file to your project and it will be used instead of the generated file. I would expect LightSwitch to support this as well but the following blog post from 2011 suggests it doesn't work.
http://blog.pragmaswitch.com/?p=120
Maybe this has been fixed in more recent versions of VS/MSBuild. I would try this first.
The previous blog suggests modifying the parameters.xml file in the package as a workaround.
You could also add parameters using the MSDeploy.exe settings declareParamFile or declareParam
http://technet.microsoft.com/en-us/library/dd569084(v=ws.10).aspx
Hope this helps!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With