

本文属于机器翻译版本。若本译文内容与英语原文存在差异，则一律以英文原文为准。

# 从 .NET on Windows Server 平台迁移到 Elastic Beanstalk s上的 .NET Core on Linux 平台
<a name="dotnet-linux-migration"></a>

您可以将在 [.NET on Windows Server](https://docs.aws.amazon.com/elasticbeanstalk/latest/platforms/platforms-supported.html#platforms-supported.net) 平台上运行的应用程序迁移到 .NET Core on Linux 平台。以下是从 Windows 平台迁移到 Linux 平台时的一些注意事项。

## 迁移到 .NET Core on Linux 平台的注意事项
<a name="dotnet-linux-migration.considerations"></a>


|  **领域**  |  **更改和信息**  | 
| --- | --- | 
|  应用程序配置  |  在 Windows 平台上，您可以使用[部署清单](dotnet-manifest.md)来指定在您的环境中运行的应用程序。这些 .NET Core on Linux 平台使用 [Procfile](dotnet-linux-procfile.md) 指定在环境实例上运行的应用程序。有关捆绑应用程序的详细信息，请参阅[捆绑适用于 .NET Core on Linux Elastic Beanstalk 平台的应用程序](dotnet-linux-platform-bundle-app.md)。  | 
|  代理服务器  |  在 Windows 平台上，您可以使用 IIS 作为应用程序的代理服务器。默认情况下，.NET Core on Linux 平台使用 nginx 作为反向代理。您可以选择不使用代理服务器，并使用 Kestrel 作为应用程序的 Web 服务器。要了解更多信息，请参阅[配置代理服务器](dotnet-linux-platform-nginx.md)。  | 
|  路由  |  在 Windows 平台上，您可以在应用程序代码中使用 IIS，并添加[部署清单](dotnet-manifest.md)来配置 IIS 路径。对于 .NET Core on Linux 平台，您可以在应用程序代码中使用 [ASP .NET Core 路由](https://docs.microsoft.com/en-us/aspnet/core/fundamentals/routing?view=aspnetcore-3.1)，并更新环境的 nginx 配置。要了解更多信息，请参阅[配置代理服务器](dotnet-linux-platform-nginx.md)。  | 
|  日志  |  Linux 和 Windows 平台会流式传输不同的日志。有关详细信息，请参阅[Elastic Beanstalk 是如何设置日志 CloudWatch 的](AWSHowTo.cloudwatchlogs.md#AWSHowTo.cloudwatchlogs.loggroups)。  | 