【发布时间】:2014-06-30 15:29:29
【问题描述】:
我试图在 IIS 8.5 上部署一个 IIS 服务应用程序,但每次我尝试通过 http://localhost/test/WCFService.svc 连接到该服务时,我都会看到以下屏幕:
当我转到turn Windows features On or OFF 时,我有以下信息:
我的 web.config 如下所示:
<?xml version="1.0"?>
<configuration>
<appSettings>
<add key="aspnet:UseTaskFriendlySynchronizationContext" value="true" />
</appSettings>
<system.web>
<compilation debug="true" targetFramework="4.5" />
<httpRuntime targetFramework="4.5"/>
</system.web>
<system.serviceModel>
<behaviors>
<serviceBehaviors>
<behavior name ="MessageServaceBehavior">
<!-- To avoid disclosing metadata information, set the values below to false before deployment -->
<serviceMetadata httpGetEnabled="true" httpsGetEnabled="true"/>
<!-- To receive exception details in faults for debugging purposes, set the value below to true. Set to false before deployment to avoid disclosing exception information -->
<serviceDebug includeExceptionDetailInFaults="false"/>
</behavior>
</serviceBehaviors>
</behaviors>
<services>
<service name ="WCF_Connection.WCFService" behaviorConfiguration="MessageServaceBehavior">
<host>
<baseAddresses>
<add baseAddress="http://10.0.5.32:58632/WCF_Service/"/>
</baseAddresses>
</host>
<endpoint name ="getMessage" address="" binding="basicHttpBinding" contract="WCF_Connection.IWCFService"/>
<!--<endpoint name ="MessgaeServiceMex" address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/>-->
</service>
</services>
<protocolMapping>
<add binding="basicHttpsBinding" scheme="https" />
</protocolMapping>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
</system.serviceModel>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
<!-- To browse web app root directory during debugging, set the value below to true.
Set to false before deployment to avoid disclosing web app folder information.-->
<directoryBrowse enabled="true"/>
</system.webServer>
</configuration>
这是什么原因造成的,我该如何解决这个问题?
【问题讨论】:
-
尝试在互联网信息服务和互联网信息服务托管网络核心下安装所有功能,然后将您的网站复制到 wwwroot 文件夹
标签: wcf windows-8.1 web-config iis-8.5