2 つの IIS Web サイトで 1 セットのバイナリをホストするように IIS を構成しようとしています。したがって、URL にアクセスできるようにする必要があります。
- http://external.example.com/ADataService
- https://external.example.com/ADataService
- http://internal.example.com/ADataService
internal.example.com と external.example.com は異なる IIS サイトとして設定され、異なるアプリケーション プールを割り当てることができます。しかし、web.config に HTTPS サポートを追加すると、内部 HTTP サポートが機能しなくなりました。http://internal.example.com/ADataServiceがエラーを返すようになりました:
CustomBinding をバインディングするエンドポイントのスキーム https に一致するベース アドレスが見つかりませんでした。登録されているベース アドレス スキームは [http] です。
これが私たちのweb.configの詳細です
<system.serviceModel>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
<bindings>
<customBinding>
<binding name="jsonCustomMapper">
<webMessageEncoding webContentTypeMapperType="Service.JSONCustomMapper, Service" />
<httpTransport manualAddressing="true" />
</binding>
<binding name="httpsjsonCustomMapper">
<webMessageEncoding webContentTypeMapperType="Service.JSONCustomMapper, Service" />
<httpsTransport manualAddressing="true" />
</binding>
</customBinding>
</bindings>
<behaviors>
<endpointBehaviors>
<behavior name="jsonBehavior">
<webHttp />
</behavior>
</endpointBehaviors>
<serviceBehaviors>
<behavior name="defaultBehavior">
<serviceDebug includeExceptionDetailInFaults="true" />
</behavior>
</serviceBehaviors>
</behaviors>
<services>
<service name="Service.Service" behaviorConfiguration="defaultBehavior">
<endpoint address="json" binding="customBinding" bindingConfiguration="jsonCustomMapper" behaviorConfiguration="jsonBehavior" contract="Service.IJSONService" />
<endpoint address="json" binding="customBinding" bindingConfiguration="httpsjsonCustomMapper" behaviorConfiguration="jsonBehavior" contract="Service.IJSONService" />
</service>
</services>
</system.serviceModel>
私が理解multipleSiteBindingsEnabled="true"
していることから、HTTPS は混在していませんが、どのリソースが共有されるのかわかりません。internal.example.com と external.example.com を異なるアプリ プールでホストしている場合、プロセスが分離されると思いましたか?