使用WIX来安装同一IIS站点的并行版本 [英] Use WIX to install side by side versions of the same IIS site

查看:81
本文介绍了使用WIX来安装同一IIS站点的并行版本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以使用WIX来安装同一IIS网站的并行版本.包括单独升级它们的能力?我搜索过很多东西,在互联网上找不到任何东西.

Is it possible to use WIX to install side by side versions of the same IIS website. Including the ability to upgrade them individually? I've searched high and low and can't find anything on the internet for this.

为什么每次构建时都使用热量自动收集文件,所以不行吗?如果在开发过程中要添加很多视图,模型和控制器,那么在VS和源代码管理中已经处理过的情况下,必须手动更新WIX中的文件结构会很麻烦.

Also why is using heat to harvest files automatically with each build such a no no? Having to manually update the file structure in WIX when it's already handled in VS and source control is such a pain if you're adding views, models, controllers a lot during development.

我希望能够在TFS构建期间发布该站点,然后为安装程序收集输出.

I'd like to be able to publish the site during a TFS build and then harvest the output for the installer.

有比WIX更好的方法吗?像Octopus或Web Deploy这样的部署工具不是一个选项,因为它需要是安装程序.付费期权也已支付.

Is there a better way than WIX to do this? A deployment tool like Octopus or Web Deploy isn't an option though as it needs to be an installer. A paid for option is also out.

推荐答案

Windows Installer支持通过

Windows Installer supports installing multiple instances via instance transforms. Essentially, you can install the package with new product code upgrade codes, and the different products can be managed individually.

您在包中添加了 InstanceTransforms 元素,并为每个自定义实例添加子元素 Instance 元素除了默认实例之外,您还希望支持:

You add an InstanceTransforms element to your package, and add a child Instance element for each custom instance you want to support in addition to the default instance:

<InstanceTransforms Property="INSTANCEID">
    <Instance Id="P1" ProductCode="GUID1" UpgradeCode="GUID2" ProductName="My App P1" />
    <Instance Id="P2" ProductCode="GUID3" UpgradeCode="GUID4" ProductName="My App P2" />
</InstanceTransforms>

这最多可以安装三个副本:默认实例,再加上实例P1和P2.要安装每个,请使用以下命令之一:

This allows you to install up to three copies: the default instance, plus instances P1 and P2. To install each, use one of these commands:

msiexec /i MyApp.msi
msiexec /i MyApp.msi MSINEWINSTANCE=1 TRANSFORMS=":P1"
msiexec /i MyApp.msi MSINEWINSTANCE=1 TRANSFORMS=":P2"

然后在非文件组件上添加Component/@MultiInstance="yes"属性.这将为每个转换创建一个新的组件guid,因此您可以安装该组件的多个副本(每个转换一个).

Then on your non-file components, add the Component/@MultiInstance="yes" attribute. This will create a new component guid for each transform, so you can install multiple copies of the component (one for each transform).

此博客文章"已重新访问:多实例安装和修补程序"更详细地说明了如何使用InstanceTransforms元素和Component/@MultiInstance属性.

This blog post "Revisited: Multiple Instance installations and patches" describes using the InstanceTransforms element and the Component/@MultiInstance attribute in more detail.

这篇关于使用WIX来安装同一IIS站点的并行版本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆