简体   繁体   English

Azure Web 应用部署槽,我可以将槽应用换成主生产,然后删除旧的吗?

[英]Azure Web App deployment slots, can I swap a slot app for the main production, then delete the old one?

I think I misunderstood Azure Web App deployment slots and have used them incorrectly.我想我误解了 Azure Web 应用程序部署槽并错误地使用了它们。

We have a .NET Core 2.1 Web App that we wanted to upgrade to Core 3.1.我们有一个 .NET Core 2.1 Web 应用程序,我们想升级到 Core 3.1。 Rather than upgrade the existing we wrote a new one from the ground up so we could refactor it a little at the same time.我们没有升级现有的,而是从头开始编写了一个新的,以便我们可以同时对其进行一些重构。

So I created a new deployment slot in Azure and added the new Web App via its (different) GitHub repo.因此,我在 Azure 中创建了一个新的部署槽,并通过其(不同的)GitHub 存储库添加了新的 Web 应用程序。 That's fine, the new slot Web App loaded fine and after testing we decided to switch to the new version.没关系,新插槽 Web 应用程序加载正常,经过测试我们决定切换到新版本。

On the go-live I removed all the custom domains from the 2.1 version, and added them to the 3.1 version, along with SSL (there are lots of domains that use the same web app via DNS mappings, which I updated to point to the new slot's CNAME), tested this and it all worked fine.在上线时,我从 2.1 版本中删除了所有自定义域,并将它们与 SSL 一起添加到 3.1 版本中(有很多域使用相同的 web 应用程序,通过 ZED5F2BDECBD4BD6349D09412 映射更新到 IDFF 点到 AFF1新插槽的 CNAME),对此进行了测试,一切正常。 I hit 'swap slots' and essentially nothing happened - the 2.1 app stays as 'Production', and 3.1 is still the a 'slot app'.我点击了“交换插槽”,但基本上什么也没发生 - 2.1 应用程序保持“生产”状态,而 3.1 仍然是“插槽应用程序”。

Now I've stopped the 2.1 app, and all our traffic is flowing to the 3.1 slot version, but this strikes me as a problem.现在我已经停止了 2.1 应用程序,我们所有的流量都流向了 3.1 插槽版本,但这让我觉得是个问题。 I need to get rid of the 2.1 version!我需要摆脱2.1版本!

Any ideas how to solve this?任何想法如何解决这个问题? ie how to make (from the pic) 'eadgen-GenV2' the main/production slot, so I can delete the original 'eadgen'?即如何使(从图片)“eadgen-GenV2”成为主要/生产槽,所以我可以删除原来的“eadgen”?

天蓝色插槽

ref: my original question about this!参考: 我关于这个的原始问题!

eadgen is your default slot and eadgen-GenV2 is a temporary slot, I think you can only delete the temporary slot. eadgen 是您的默认插槽,而 eadgen-GenV2 是临时插槽,我认为您只能删除临时插槽。 You can try to use this:你可以尝试使用这个:

在此处输入图像描述

What will be swapped is:将被交换的是:

General settings, such as framework version, 32/64-bit, web sockets App settings (can be configured to stick to a slot)通用设置,如框架版本,32/64位,web sockets 应用设置(可配置为粘到插槽)

Connection strings (can be configured to stick to a slot)连接字符串(可以配置为粘在插槽上)

Handler mappings处理程序映射

Public certificates公共证书

WebJobs content网络工作内容

Hybrid connections混合连接

Virtual network integration虚拟网络集成

Service endpoints服务端点

Azure Content Delivery Network Azure 内容分发网络

From the description of the documentation it seems to be able to change the framework version.从文档的描述看来,它似乎能够更改框架版本。

This is the doc:这是文档:

https://docs.microsoft.com/en-us/azure/app-service/deploy-staging-slots#swap-two-slots https://docs.microsoft.com/en-us/azure/app-service/deploy-staging-slots#swap-two-slots

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Azure Web应用程序-其他部署插槽会影响生产插槽吗? - Azure web app - Additional deployment slots affect production slot? Azure Web App插槽,为什么Source在交换时默认为生产 - Azure Web App slots, why does Source default to production on a swap 如何配置交换插槽功能? 目前,在部署之后,我仍然看到旧版本的Web应用 - How to configure swap slot feature? Currently after deployment still i am seeing old version of web app 暂存与生产槽 - Azure Web 应用程序部署 - Staging vs Production slot - Azure Web app deployment Azure 插槽:我可以只交换应用程序设置/连接字符串吗? - Azure slots :Can i swap only app settings/connection strings? Azure Powershell脚本,用于交换Azure App Service(网站)部署插槽 - Azure Powershell script to swap Azure App Service (website) deployment slots Azure Web App-将具有自定义域的生产插槽备份还原到部署插槽 - Azure Web App - Restore production slot backup with custom domain to a deployment slot 具有数据库迁移的Azure Web App部署槽 - Azure Web App deployment slots with database migration Azure Function 应用程序 - 交换部署插槽卡住然后完全崩溃 - Azure Function App - Swap deployment Slots stuck then crashing completely 强制Azure Web应用程序的生产槽始终打开 - Force production slot of an Azure web app to be always on
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM