【发布时间】:2015-01-13 13:13:20
【问题描述】:
我正在开发一个新的 Wix 安装程序。
- 我想要做的是将 .exe 复制到一个目录中。
- 创建一个新用户。
-
使用该新用户安装 Windows 服务。
<!-- Create User --> <util:User Id="UpdateUserLogonAsService" UpdateIfExists="yes" CreateUser="yes" Name="ServiceUser" PasswordNeverExpires="yes" Password="secret" /> <ServiceInstall Id="ServiceInstaller" Type="ownProcess" Vital="yes" Name="Windows:service" DisplayName="Windows service install" Description="test" Start="auto" Account="ServiceUser" Password="secret" ErrorControl="ignore" Interactive="no" /> <ServiceControl Id="StartService" Start="install" Stop="both" Remove="uninstall" Name="Windows:service" Wait="yes" />
创建用户有效,只要我使用当前的登录名和密码,安装服务就有效。但是,一旦我尝试使用新用户,我就会收到以下错误消息。
确认您有足够的权限安装系统服务
我已尝试以管理员身份运行 msi,但它并没有改变仍然出现错误。我猜这与我没有权限安装服务以在其他用途下运行有关。但这是一个猜测。
【问题讨论】:
标签: wix windows-installer wix3.5