- Build the shutdown project in Debug mode. This is required as docker file uses ./bin/Debug/net8.0 to copy from.
- Build the docker image. For this navigate to the Shutdown project location
docker build . -t shutdown-trial - Run a container using the image shutdown-trial
- Stop the container after starting
This does not write "Stopping my Application..." to the console when using mcr.microsoft.com/dotnet/runtime:8.0-windowsservercore-ltsc2019
Writes "Stopping my Application..." to the console.