Publishing your applications for deployment
There are three ways to publish and deploy a .NET Core application. They are:
- Framework-dependent deployment (FDD).
- Framework-dependent executables (FDEs).
- Self-contained.
If you choose to deploy your application and its package dependencies, but not .NET Core itself, then you rely on .NET Core already being on the target computer. This works well for web applications deployed to a server because .NET Core and lots of other web applications are likely already on the server.
Sometimes, you want to be able to give someone a USB stick containing your application and know that it can execute on their computer. You want to perform a self-contained deployment. While the size of the deployment files will be larger, you'll know that it will work.
Creating a console application to publish
Let's explore how to publish a console application.
- Create a new console application project named
DotNetCoreEverywhere...