IIS服务的部署

时间:2023-03-09 09:10:36
IIS服务的部署

1.安装 C:\Windows\Microsoft.NET\Framework\v4.0.30319 aspnet_regiis -i
2.添加应用程序,选择Asp.net4.0
3.应用目录 IIS_Users 增加读写权限

如果是本机的最佳方案,直接用VisualStudio2010以上版本的工具直接部署,到IIS上,问题就比较少。

另外部署到默认的网站下,也会较少有权限等问题。

还有一定要修改配置:

服务端的:

<serviceBehaviors>
<behavior>
<!-- 为避免泄漏元数据信息,请在部署前将以下值设置为 false 并删除上面的元数据终结点 -->
<serviceMetadata httpGetEnabled="true"/>
<!-- 要接收故障异常详细信息以进行调试,请将以下值设置为 true。在部署前设置为 false 以避免泄漏异常信息 -->
<serviceDebug includeExceptionDetailInFaults="true"/>
<serviceThrottling maxConcurrentCalls="2147483647" maxConcurrentInstances="2147483647" maxConcurrentSessions="2147483647"/>
</behavior>
</serviceBehaviors>

客户端的:

<basicHttpBinding>
<binding name="BasicHttpBinding_IFileManageService" maxBufferSize="65536000" maxBufferPoolSize="52428800"
maxReceivedMessageSize="65536000">
<readerQuotas maxDepth="32" maxStringContentLength="65536000"
maxArrayLength="65536000" maxBytesPerRead="65536000" maxNameTableCharCount="65536000" />
</binding>
</basicHttpBinding>