I'll follow the multi-stage build approach for NerdDinner, so the Dockerfile for the dockeronwindows/ch-02-nerd-dinner images starts with a builder stage:
# escape=`FROM sixeyed/msbuild:netfx-4.5.2-webdeploy-10.0.14393.1198 AS builderWORKDIR C:\src\NerdDinnerCOPY src\NerdDinner\packages.config .RUN nuget restore packages.config -PackagesDirectory ..\packagesCOPY src C:\srcRUN msbuild .\NerdDinner\NerdDinner.csproj /p:OutputPath=c:\out\NerdDinner ` /p:DeployOnBuild=true ` /p:VSToolsPath=C:\MSBuild.Microsoft.VisualStudio.Web.targets.14.0.0.3\tools\VSToolsPath
The stage uses sixeyed/msbuild as the base image for compiling the application, which is an image I maintain on Docker Cloud. That image installs MSBuild, ...