How do you configure an application distributed via ClickOnce technology to treat different environments (e.g. integration, QA, staging, production) as different “versions” and not override each other? In other words, does ClickOnce technology support side-by-side environment?
The answer is quite simple – you need to use a different certificate for each environment and use a different name so you get a different menu item for each environment.
For example, if you use the mage utility, your manifest and deployment file commands would look something like this:
mage.exe -New Application -ToFile .\WindowsApplication1_1_0_0_6\windowsapplication1.exe.manifest -Name "QA TEST" -Version 184.108.40.206 -FromDirectory .\WindowsApplication1_1_0_0_6
mage -sign WindowsApplication1_1_0_0_6\windowsapplication1.exe.manifest -certfile cert_qa.pfx -password "your_password"
mage.exe -New Deployment -ToFile windowsapplication1.application -Name "QA TEST" -Version 220.127.116.11 -AppManifest WindowsApplication1_1_0_0_6\windowsapplication1.exe.manifest -providerUrl "file:\\yourserver\publishqa\windowsapplication1.application"
mage -sign windowsapplication1.application -certfile cert_qa.pfx -password "your_password "
Just change the name and certificate file (in bold) for each environment and live happily thereafter with multiple version of your application for each environment living on your computer side-by-side.