Dockerizing the application

Now let's containerize our application by adding some additional files and modifying the ASP.NET Core build and publishing process:

  1. As the first step, right-click on the MusicStore web project and navigate to Add | New Folder, name it Docker. This folder will hold all the artifacts which provide the necessary support for converting the application into a Windows Server Container.
  2. Now add a new file called Dockerfile to the project. Right-click on the Docker folder we just created, navigate to Add | New Item....
A Dockerfile is a special type of file with no extension, which only the Docker daemon can understand. Docker daemon looks for this file for instructions while building an image.
  1. Select any file type ...

Get Learning Windows Server Containers now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.