ServiceInstall reinstalling on every run #8963
Replies: 1 comment
-
It's not really the current design intent of the ServiceInstall element. And it would depend on how you've authored your upgrade packages around what occurs there. There are likely other ways to handle this, like having a condition to prevent the uninstall action of the ServiceInstall if it's a UPGRADE type of action. You would need to spin the ServiceInstall out into its own Component (away from the versioned files) however.. and hence would likely need to connect it to a registry value KeyPath or something similar (which is file version agnostic). |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I am at a loss right now, and maybe think this is a shortcoming in MSI in general, so would be glad to get some help for this.
I have the following service install
My "issue" is that i have created a single.exe file .net 9 self-contained project. This exe should be installed as a service.
But it should also be possible for users to change service settings in windows (Log-on as etc), and then when installing an update to the MSI, The service should stop, overwrite the .exe file with the new version inside the new MSI, and then start the service.
I have tried with the above, custom actions hack (only install service through sc.exe if it doesn't already exist). And i really can't get this to work.
Can this be done somehow? Because the inside the component with the service i have read have to be part of the service component.
Beta Was this translation helpful? Give feedback.
All reactions