好的,所以我以前可以在项目属性对话框中更改 SSL 端口号,但是在 asp.net 5 RC1 更新后,SSL 字段是只读的:
当我尝试直接编辑 .xproj 时,它会忽略 SSLPort 值:
<PropertyGroup>
<SchemaVersion>2.0</SchemaVersion>
<DevelopmentServerPort>17204</DevelopmentServerPort>
<SSLPort>44303</SSLPort>
</PropertyGroup>
当我更改绑定并启动项目时,它还会将应用程序主机配置文件 ($[solutionDir].vs\config\applicationhost.config) 中的端口重置回原始值。
<site name="WebApplication1" id="8">
<application path="/" applicationPool="Clr4IntegratedAppPool">
<virtualDirectory path="/" physicalPath="C:\WebApplication1\wwwroot" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:17833:localhost" />
<binding protocol="https" bindingInformation="*:44303:localhost" />
</bindings>
</site>
是什么赋予了? Visual Studio 从哪里获取此值?如何更改它?
Open launchSettings.json
在下面./Properties
文件夹。这intiisSettings > iisExpress > sslPort 中的值是读取的位置。您可以将该值更改为您想要的任何值。
{
"iisSettings": {
"iisExpress": {
"sslPort": <ssl-port-value>
}
}
}
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)