We have a few console apps developed with .Net Framework. We used to run them on Windows, but now we'd like to try to use .Net Core for that. So far, this ridiculously simple way works fine (running Framework 4.5.1 app on Core 2.2):
Copy the app with all its dependencies to Linux.
Copy the
runtimeconfig.json
file from a Hello World .Net Core example to the app dir and rename it accordingly.Just run
dotnet ./app.exe
from that dir on Linux.
I find it really surprising that it works without rebuilding for the new target. But I suspect that there may be hidden problems or limitations of this approach. For one thing, obviously it won't run if the app uses something outside Core (say, WPF).
What are the exact conditions for running .Net Framework apps with .Net Core? Anything specific for Linux? Or for specific versions of Framework/Core?