2013年10月7日月曜日

WCFをBasic通信で行うために

・IISに基本認証を設定する

 認証→基本認証を有効にする
 ※基本認証がない場合は、役割の追加→サービスの追加→基本認証を追加する。

・web.configの書き換え

 Bindingのこの辺を書き換え 
  <security mode="TransportCredentialOnly">
    <transport clientCredentialType="Basic"/>
    <message clientCredentialType="UserName"/>
  </security>

・app.configも書き換え(こんな感じに)
  <system.serviceModel>
  <bindings>
   <basicHttpBinding>
    <binding name="BasicHttpBinding_Taurus" closeTimeout="00:01:00"
      openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"
      allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
      maxBufferSize="6553600" maxBufferPoolSize="524288" maxReceivedMessageSize="6553600"
      messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"
      useDefaultWebProxy="true">
     <readerQuotas maxDepth="32" maxStringContentLength="819200" maxArrayLength="1638400"
       maxBytesPerRead="4096" maxNameTableCharCount="16384" />
     <security mode="TransportCredentialOnly">
      <transport clientCredentialType="Basic" proxyCredentialType="None" realm="" />
      <message clientCredentialType="UserName" algorithmSuite="Default" />
     </security>

    </binding>
   </basicHttpBinding>
  </bindings>


※参照
10行でズバリ

2013年10月2日水曜日

Active Reportを含むプロジェクトをTFSでビルド

active reportをインストールした端末にtfsをインストールしないとできなさそう。
・active reportをインストール
・それぞれのプロジェクトにlicxファイルを追加
・TFSのビルド定義で
  1.プロセス→3.詳細→MSBuildプラットフォームをX86
  2.エージェントの設定にactive reportをインストールした端末のエージェントを設定

※追記
TFSをインストールしているサーバーにActive Reportsをインストールするには
ライセンスが必要になるので、すでにActive Reportsをインストールしている
開発PCをTFSのビルドエージェントとして登録すると、サーバーにActive Reportsを
インストールしなくてすむ。