[英]asp.net core 3.1 self-contained single file + linux-x64, ubuntu 20.04 can't run app
I read Running a self-contained ASP.NET Core application on Ubuntu and publish setting like below我阅读了 Running a self-contained ASP.NET Core application on Ubuntu并发布如下设置
and upload to ubuntu without do.net sdk/runtime, and command app_name
but ubuntu show app_name: command not found
并上传到 ubuntu 没有 do.net sdk/runtime,和命令app_name
但 ubuntu show app_name: command not found
and upload to ubuntu without do.net sdk/runtime, and command app_name but ubuntu show app_name: command not found并上传到 ubuntu 没有 do.net sdk/runtime,和命令 app_name 但 ubuntu show app_name: command not found
It means that do.net
command has not been recognized by Ubuntu 22.04 (LTS)
.这意味着do.net
命令尚未被Ubuntu 22.04 (LTS)
识别。 In this scenario please Install the SDK
(which includes the runtime)
if you want to develop .NET apps
Or, if you only need to run apps, install the Runtime
.在这种情况下,如果您想开发.NET apps
,请Install the SDK
(which includes the runtime)
或者,如果您只需要运行应用程序, install the Runtime
。
If you're installing the Runtime, Microsoft's suggestion is to install the ASP.NET Core Runtime as it includes both .NET and ASP.NET Core runtimes.如果您要安装运行时,Microsoft 建议安装 ASP.NET 核心运行时,因为它包括 .NET 和 ASP.NET 核心运行时。 You can see here
你可以here
看到
How would you check whether install succeeded:你将如何检查是否安装成功:
You can see which versions of the .NET SDK
are currently installed with a terminal.可以用终端查看.NET SDK
当前安装了哪些版本。 Open a terminal and run the following command.打开终端并运行以下命令。
do.net --list-sdks
To check SDK Version List do.net --list-sdks
查看SDK版本列表
do.net --list-runtimes
To check DotNet Runtime Version do.net --list-runtimes
检查 DotNet 运行时版本
do.net --version
To check Lastest Installed Version do.net --version
检查最新安装的版本
If you still encounter command not found
means your installation didn't get succeeded.如果还是遇到command not found
,说明你的安装没有成功。 For more details please check our official document here
有关详细信息,请official document here
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.