简体   繁体   English

Visual Studio 2013-网站安装程序项目

[英]Visual Studio 2013 - Web Site installer project

I have two visual studio 2013 solutions: 1) Contains MVC application projects 2) Contains a mix of WCF and WebApi service projects. 我有两个Visual Studio 2013解决方案:1)包含MVC应用程序项目2)包含WCF和WebApi服务项目的混合。

I would like to create two installer projects one for each solution that will self extract and install the websites into IIS 7. 我想为每个解决方案创建两个安装程序项目,每个项目将自我提取并将网站安装到IIS 7中。

Also I would like these installer project to be built by our TFS build server so the output from the nightly build is two MSI files. 另外,我希望这些安装程序项目由我们的TFS构建服务器构建,因此夜间构建的输出是两个MSI文件。 Double clicking either of these project will setup the website and backend web service with minimal effort on the person doing install. 双击这两个项目中的任何一个都将以最小的工作量来安装网站和后端Web服务。

Anyone done this? 有人这样做吗? How did you do it? 你是怎么做到的?

Normal setup projects install ONE web application to one web site. 普通安装项目将一个Web应用程序安装到一个网站上。 I do not know of a third party setup project that will do this out of the box. 我不知道一个第三方安装项目可以直接执行此操作。

If you are up for the challenge, I would recommend checking out the WiX Toolset. 如果您准备好迎接挑战,我建议您查看WiX工具集。 You should be able to "script" everything in a WiX setup project and it will build your MSI files on your TFS build servers. 您应该能够“编写” WiX安装项目中的所有内容,它将在TFS构建服务器上构建MSI文件。

First find out how to create a WiX setup for 1 web application, then duplicate that code for each of your projects. 首先了解如何为1个Web应用程序创建WiX设置,然后为每个项目复制该代码。

I recommend this tutorial. 我推荐本教程。 http://www.codeproject.com/Articles/115036/Creating-WIX-Installer-for-ASP-NET-Web-Application http://www.codeproject.com/Articles/115036/Creating-WIX-Installer-for-ASP-NET-Web-Application

Based on this I created a simple web project installer. 基于此,我创建了一个简单的Web项目安装程序。

For MVC site, you should publish a web deploy package and import from IIS. 对于MVC网站,您应该发布Web部署程序包并从IIS导入。 This link is very useful. 该链接非常有用。

For other types of projects, you should use WiX projects to single click installations. 对于其他类型的项目,应使用WiX项目单击安装。

If you host the WCF services on the IIS, you should create second web package. 如果在IIS上托管WCF服务,则应创建第二个Web程序包。

If you on a windows service, you can use the WiX Toolset Visual Studio extension. 如果您使用Windows服务,则可以使用WiX Toolset Visual Studio扩展。 You just create a simple script and build it. 您只需创建一个简单的脚本并进行构建。 It will create msi files. 它将创建msi文件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM