title: docker + dotnet watch
body: <p>I use Visual studio Code.</p>
  
  <p>I create a new projet dotnet new webapi. I have referenced dotnet-watch in my .csproj :
      <code>&lt;ItemGroup&gt;
          &lt;DotNetCliToolReference Include="Microsoft.DotNet.Watcher.Tools" Version="2.0.0" /&gt;
          &lt;DotNetCliToolReference Include="Microsoft.Extensions.SecretManager.Tools" Version="2.0.0" /&gt;
          &lt;DotNetCliToolReference Include="Microsoft.Extensions.Caching.SqlConfig.Tools" Version="2.0.0" /&gt;
      &lt;/ItemGroup&gt;</code></p>
  
  <p>Then, I Build my DockerFile. </p>
  
  <p>I notice strange behavior. The docker image detects the changes and rebuilds the solution. The binary files have been updated in bin and obj directory but when I call the api, it is as if there had never been any change.</p>
  
  <pre><code>FROM microsoft/aspnetcore-build:2.0
  
  COPY . /app
  WORKDIR /app
  
  ENV ASPNETCORE_URLS=http://*:5000
  EXPOSE 5000
  
  ENV DOTNET_USE_POLLING_FILE_WATCHER=1
  ENV ASPNETCORE_ENVIRONMENT=Development
  </code></pre>
  
  <p>Docker command : docker run -i -p 5000:5000 -v $(pwd):/app -t docker-todoapi</p>
  
  <p>finally in the container terminal : docker restore and docker Watch run</p>