Docker Support
Last updated
Last updated
A Docker container image is a lightweight, standalone, executable package of software that includes everything needed to run an application: code, runtime, system tools, system libraries and settings.
Using Visual Studio Docker Tools, Wisej.NET 3 applications can be packaged and run in these containers.
When creating a cross-platform Wisej.NET 3 application, Visual Studio will prompt the user to add Docker support to the project.
To run the Wisej.NET application in a Docker container, change the runtime target to Docker.
When building and running a Docker project, the first TargetFramework is always used. If Docker can't run the first TargetFramework, it will target the second or third listed framework.
Docker can build images automatically by reading the instructions from a Dockerfile
. A Dockerfile
is a text document that contains all the commands a user could call on the command line to assemble an image. Using docker build
users can create an automated build that executes several command-line instructions in succession.
Below is a sample Dockerfile configured to run a Wisej.NET 3 application that targets .NET 5.
Be sure to update the Dockerfile if the TargetFramework is not .NET5.0.