在IIS-6上安装时,以下是一些注意事项:
aspnet_isapi.dll,支持通配符映射)。
到目前为止,我得到的是:
<iis:WebDirProperties Id='WebDirProperties' Script='yes' Read='yes
Execute='no' WindowsAuthentication='yes' AnonymousAccess='no'
AuthenticationProviders='NTLM,Negotiate' />
<!-- SO has some good posts on selecting the website from a dropdown -->
<iis:WebSite Id='SelectedWebSite' Directory='WWWROOT' SiteId='[WEBSITE_ID]' Description='[WEBSITE_DESCRIPTION]'>
<iis:WebAddress Id='AllUnassigned' Port='80' IP='*'/>
</iis:WebSite>
<Component Id="ProjWebApp" Guid="{B4BE9223-7109-4943-AE4E-8F72FA350D02}"
Win64="$(var.IsWin64)" NeverOverwrite="yes" Transitive="yes">
<CreateFolder/>
<iis:WebAppPool Id="ProjAppPool" Name="[APPPOOLNAME]" Identity="networkService"
ManagedRuntimeVersion="v4.0" ManagedPipelineMode="integrated" />
<iis:WebVirtualDir Id="ProjVDir" DirProperties="WebDirProperties"
Alias="[WEBAPPNAME]" Directory="WEBFILESDIR" WebSite="SelectedWebSite">
<iis:WebApplication Id="ProjApp" Name="[WEBAPPNAME]" WebAppPool="ProjAppPool">
<iis:WebApplicationExtension
CheckPath="no"
Script="yes"
Executable="[ASPNETISAPIDLL]"
Verbs="GET,HEAD,POST"
/>
</iis:WebApplication>
</iis:WebVirtualDir>
</Component>
<!-- other apps may start using it once installed so it must be permanent -->
<Component Id="EnableASPNet4Extension" Permanent="yes" Guid="{C8CDAB96-5DDC-4B4C-AD7E-CD09B59F7813}">
<iis:WebServiceExtension Id="ASPNet4Extension" Group="ASP.NET v4.0.30319"
Allow="yes" File="[ASPNETISAPIDLL]" Description="ASP.NET v4.0.30319"
UIDeletable="no"
/>
</Component>我有一个自定义操作可以在IIS中注册ASP.NET:
<?if $(var.Platform) = x64 ?>
<CustomAction Id="SetProperty_AspNetRegIIS_InstallNet40Cmd"
Property="AspNetRegIIS_InstallNet40Cmd"
Value=""[NETFRAMEWORK40FULLINSTALLROOTDIR64]aspnet_regiis.exe" -ir"/>
<?else?>
<CustomAction Id="SetProperty_AspNetRegIIS_InstallNet40Cmd"
Property="AspNetRegIIS_InstallNet40Cmd"
Value=""[NETFRAMEWORK40FULLINSTALLROOTDIR]aspnet_regiis.exe" -ir"/>
<?endif?>问题
这几乎成功了。在这一点上有两个问题:
aspnet_regiis.exe -s APP_PATH注册它,它会覆盖通配符映射(而且我不知道可以运行命令行来恢复它)。鉴于上述缺点,当IIS-6已经安装了ASP.NET 2时,如何使用WIX将ASP.NET MVC 3应用程序安装到IIS-6上,并进行适当的通配符映射?
发布于 2012-01-03 22:00:27
原来这是我的一个愚蠢的错误。当我没有包含的部分(自定义操作和属性定义)正确时,上述内容就足以使ASP.NET v4应用程序工作。
在我的例子中,我不小心引用了到aspnet_isapi.dll的路径,所以它实际上没有被正确地捕获。
IIS扩展不尊重IIS-6上的托管运行时版本,因此应用程序没有ASP.NET版本集。
这部分是对的。尽管在设置App时它不使用托管运行时版本,但一旦ASP.NET正确映射到,IIS实际上就会获取aspnet_isapi.dll版本。我一修好这条路,一切就都正常了。
如果在创建后使用aspnet_regiis.exe -s APP_PATH注册它,它会覆盖通配符映射(而且我不知道可以运行命令行来恢复它)。
如果需要的话,可以使用adsutil.vbs来管理它:
C:\Inetpub\AdminScripts>adsutil.vbs enum w3svc/998577302/root/AppName
KeyType : (STRING) "IIsWebVirtualDir"
...
ScriptMaps : (LIST) (1 Items)
"*,C:\WINDOWS\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD
,POST"通过在set中使用adsutil.vbs命令,您可以根据需要设置ScriptMaps属性。
https://stackoverflow.com/questions/8702587
复制相似问题