开发者

How do I get my Wix installer to use an existing application pool in IIS6?

开发者 https://www.devze.com 2023-01-07 06:25 出处:网络
I am b开发者_StackOverflow社区uilding a simple installer for a web application using Wix. I wish to use an existing app pool. The following code works as I want when installing the application.

I am b开发者_StackOverflow社区uilding a simple installer for a web application using Wix. I wish to use an existing app pool. The following code works as I want when installing the application.

<iis:WebAppPool Id='MyAppPool' Name='CRMAppPool'  />

This will set up the virtual directory using the existing CRMAppPool.

The problem is when, I uninstall the application, it deletes the app pool.

How can I prevent this?


Put the WebAppPool element in it's own component and mark the component as permanent. The permananent attribute will ensure that the component is not removed upon uninstallation.


First I'd like to ask why you want to do this. I've always been really paranoid about sharing app pools once I first learned years ago that a .NET 1.1 webapp could JIT and then a .NET 2.0 webapp would fail.

Assumming you've considered all of this and really do want to share the app pool, I wouldn't do it with a permanent component and described above. I would instead do it with a shared component. Since App Pool's can't really be keyfiles I would create a fake registry key that services as the keyfile and put the app pool in as a companion resource.

I would then duplicate this component across all of my installs so that MSI can reference count the component and when the last install comes off the machine it will remove the app pool.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号