如何创建 Windows 安装程序 [英] How to create windows installer

查看:36
本文介绍了如何创建 Windows 安装程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

基本上,我们以手动安装程序(Windows powershell 脚本)的形式发布更改/修复.它将通过读取配置文件值在特定位置安装指定的 .dll 和 SQL 脚本文件(我们将在此文件中配置 .dll 和 Sql 脚本位置).相同的 powershell 脚本具有用于回滚特定更改集的卸载代码.

Basically we are releasing our changes/fixes in the form of manual installer (Windows powershell script). It will install specified .dll and SQL script files at particular locations by reading config file values (We will configure .dll & Sql script locations in this file). The same powershell script has uninstallation code to rollback particular chage set.

是否有任何选项或机制可以为上述要求创建 Windows 安装程序?

Is there any option or mechanism to create Windows installer for above requirement?

推荐答案

简短版本:已经有很多答案 - 我主要只是添加一些链接到现有的答案.这是我之前在主题.

更高的一目了然":上述答案具有更简单的格式列表视图当前最重要的部署工具.匆匆?测试这些,选择一个.下面是更多细节和一些进一步的讨论".

Higher "glanceability": The above answer features a simpler format with a list view of the most important current deployment tools. In a rush? Test these, chose one. Below are more details and some further "discussion".


部署工具

有许多工具可用于创建安装程序/setup.exe 文件的各种类型.以下是其中大部分内容的简要说明的链接:


Deployment Tools

There are many tools available to create create installers / setup.exe files of various kinds. Here are some links to brief descriptions of most of them:

  • Non-MSI installer tools: http://www.installsite.org/pages/en/tt_nonmsi.htm
  • Windows installer tools: http://www.installsite.org/pages/en/msi/authoring.htm
  • Sys-admin tools for deployment: http://www.installsite.org/pages/en/msi/admins.htm (for completeness, not really relevant for you)
  • UPDATE: On the topic of multi-platform installers: Does an universal cross-platform installer exists?

我建议去参加 MSI.使用什么具体工具不太明显.有关不同工具的优缺点描述的一些链接,请参阅下面的最后一节.

I would recommend to go for MSI. What specific tool to use is less obvious. See last section below for some links with descriptions of strengths and weaknesses of different tools.

自动更新?:创建自动更新包的各种方法.

MSI (Windows Installer)企业部署的标准,因为它提供了许多企业利益与之前安装相比的主要意义技术.好处集中在可靠的遥控器上管理标准化 - 至关重要的企业部署担心.

MSI (Windows Installer) is the standard for corporate deployment since it offers a number of corporate benefits of major significance compared to previous installation technologies. The benefits center around reliable remote management and standardization - crucial corporate deployment concerns.

简而言之,最重要、具体的好处可能是:

In brief the most important, specific benefits are probably:

  1. 可靠的静音运行(标准化且完全可抑制的 GUI)
  2. 隐式可用的卸载(处理旧设置时的噩梦)
  3. 透明度(安装程序的半透明和可检查性质 - 编译的 CA 除外)
  4. 提升安装权限(没有凌乱的临时管理员权限)
  5. 标准化命令行(无需寻找秘密"开关)
  6. 管理安装(文件提取 -企业重新包装必不可少)
  7. 详细日志(确实有用且详细:-))
  8. 标准化包定制(转换 - 数据库片段)
  9. 回滚支持(可以撤消安装失败的更改)
  10. 库存(管理和报告:完整注册安装的内容和位置)
  11. Active Directory/GP 集成
  1. Reliable silent running (standardized & completely suppressible GUI)
  2. Implicitly available uninstall (a nightmare when dealing with legacy setups)
  3. Transparency (installer's semi-transparent and inspectable nature - except compiled CAs)
  4. Elevated installation rights (no messy temporary admin rights)
  5. Standardized command line (no hunting for "secret" switches)
  6. Administrative installation (file extract - essential for corporate repackaging)
  7. Verbose logging (helpful and verbose indeed :-) )
  8. Standardized package customization (transforms - database fragments)
  9. Rollback support (can undo changes for failed installs)
  10. Inventory (management and reporting: full registration of what is installed and where)
  11. Active Directory / GP integration

总的来说,这产生了 MSI 的整体优势:可靠、远程大型系统管理员的部署管理,企业环境.关键的好处,尽管技术复杂性和古怪.

Altogether this yields MSI's overall benefit: reliable, remote management of deployment for busy system administrators in large, corporate environments. Crucial benefits, despite the technology's complexity and quirkiness.

许多人发现该技术难以处理 - 有一些常见的陷阱(我写了这里是对一些 MSI 反模式的非常奇怪的临时描述 - 脱离了问题的上下文,但确实存在 - 有时会写一些东西一时兴起,让写文章的人也感到惊讶 - 很好,但不是,只是实用的细节.第一个链接也是如此).

Many find the technology challenging to deal with - there are some common pitfalls (and I wrote a very odd, ad-hoc description of some MSI anti-patterns towards the bottom here - out of context for the question, but there it is - sometimes things get written in the spur of the moment to the surprise of whoever is writing too - great it is not, just pragmatic details. Same goes for the first link).

链接的服务器故障答案(以上和此处)更详细地描述了这些企业 MSI 优势以及一些需要注意的挑战.

The linked serverfault answer (above and here) features a much more elaborate description of these corporate MSI benefits along with some challenges to be aware of.

相同的服务器故障问题有第二个答案,描述了 MSI 文件中的常见设计错误.一个非常混乱的脑残粉".

The same serverfault question has a second answer describing common design errors in MSI files. A really messy "brain dump".

我应该指出,微软现在的新打包平台是 MSIX 基于 AppX 应用程序框架.然而,MSI 在企业部署领域具有很高的渗透率,因此 MSI 的相关性还有多久还有待观察.所有已建立的部署工具都致力于支持 MSIX 和 AppX 以及其他部署技术(也包括虚拟化).

I should point out that the new platform for packaging from Microsoft now is MSIX based on the AppX application framework. However MSI has high penetration in the corporate deployement world, so it remains to be seen how long MSI will be relevant. All established deployment tools are working to support MSIX and AppX and other deployment technologies (also virtualization).

插入一些链接:


AppV

在真实的企业界AppV(应用程序虚拟化/应用程序流)已经变成了一种常见的部署解决方案(Tim Mangan 的博客).


AppV

And in the real, corporate world AppV (application virtualization / application streaming) has turned into a common deployment solution (Tim Mangan's blog).

MSI 创建的行业领导者通常是高级安装程序InstallshieldPACE Suite,以及开源解决方案WiX(及其商业分支Firegiant) - 您似乎对它有些熟悉.

Industry leaders for MSI creation are generally Advanced Installer, Installshield, PACE Suite, and the open source solution WiX (with its commercial branch Firegiant) - which you seem somewhat familiar with.

我只是给你一些以前写过的答案的链接,以及一些关于这些不同工具的观点和事实 - 它旨在作为最大努力"帮助人们决定他们需要什么工具,而不是声称自己是正确的".这始终是一项危险的努力——多年的经验意味着获得知识,但也预示着后天养成的坏习惯和怪癖.什么结果是来自一个有缺陷的专业人士的诚实意见,他只能提供帮助:

I'll just give you some links to previously written answers with some opinions and facts in an indiscreet mix about these different tools - it is intended as a "best effort" to help people decide what tool they need, without claiming to be "right". This is always a dangerous endeavor - years of experience mean acquired knowledge, but also bodes for acquired bad habits and quirks. What results are honest opinions from a flawed professional who can only offer a willingness to help:

  • What installation product to use? InstallShield, WiX, Wise, Advanced Installer, etc - a subjective attempt at an objective evaluation of the strengths and weaknesses of the currently established deployment products.
  • Quick start for WiX - a messy little answer with suggestions on how to hit the ground running with WiX that has been upvoted more than usual. It must have been helpful. I like the "hello world" style sample I link to on codeproject which other have mentioned as well.
  • Windows Installer and the creation of WiX (quick and unofficial overview of how WiX came about and how it works. Also a part on "the unavoidable complexity of deployment").
  • How can I compare the content of two (or more) MSI files? (some brief information on the MSI format, how to inspect MSI files and retrieve and inspect the content in them using free tools).
  • How do I avoid common design flaws in my WiX / MSI deployment solution? (some well-meant but messy advice on how to avoid problems in your MSI-based deployment solution).

这篇关于如何创建 Windows 安装程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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