1

I'm writing an MSBuild installer for a web application that's hosted on IIS7.5

Up until now, setting up the web app has been a manual process using IIS Manager.

The process involves setting up credentials for the application's Physical Path but I'm struggling to find out how to do this with the extension pack.

Does anyone know:

  1. if it's possible to achieve this?
  2. how?
  3. which version of the extension pack supports it?

Tia, Mike

4

1 回答 1

0

我找到了一种使用扩展包设置虚拟目录默认值的方法我已经发布了我的答案,以防它帮助其他任何人。Mitul 的评论也值得任何需要更精细控制的人尝试。

我们使用的扩展包版本相当旧。在当前版本中,可以使用 Iis7Website 类的 ConnectAsUser 和 ConnectAsUserPassword 属性来设置网站虚拟目录的默认用户名和密码:

<MSBuild.Web.ExtensionPack.Web.Iis7WebSite
    ConnectAsUser="foo"
    ConnectAsUserPassword="sesame"
    ...other properties>
</MSBuild.Web.ExtensionPack.Web.Iis7WebSite>

谢谢,迈克

于 2015-10-18T14:57:12.170 回答