Yaptığım bazı dağıtımlarda bir App Service
2 yuva içeren kaynak (a production
ve staging
yuvalar), yuvaların değiştirilmesinden sonra sahneleme webjobu durmuyor.
Temel olarak boru hattımda aşağıdaki görevler var:
## Start App Service (staging)
- task: AzureAppServiceManage@0
displayName: 'Start Azure App Service: some-app-webjob (staging)'
inputs:
azureSubscription: 'xxx'
Action: 'Start Azure App Service'
WebAppName: 'some-app-webjob'
SpecifySlotOrASE: true
ResourceGroupName: 'some-rg-app-webjob'
Slot: staging
##Start staging continuous webjob
- task: AzureAppServiceManage@0
displayName: 'Start all continuous webjobs: some-app-webjob (staging)'
inputs:
azureSubscription: 'Subscrição do Visual Studio Enterprise(c9f20c2b-15cf-41fb-8122-ddf095c6db02)'
Action: 'Start all continuous webjobs'
WebAppName: 'some-app-webjob'
SpecifySlotOrASE: true
ResourceGroupName: 'some-rg-app-webjob'
Slot: 'staging'
## Swap Slots (staging to production)
- task: AzureAppServiceManage@0
displayName: 'Swap Slots: some-app-webjob'
inputs:
azureSubscription: 'xxx'
WebAppName: 'some-app-webjob'
ResourceGroupName: 'some-rg-app-webjob'
SourceSlot: staging
TargetSlot: production
# Stop WebJobs running Staging
- task: AzureAppServiceManage@0
displayName: 'Stop all continuous webjobs: some-app-webjob (staging)'
inputs:
azureSubscription: 'xxx'
Action: 'Stop all continuous webjobs'
WebAppName: 'some-app-webjob'
SpecifySlotOrASE: true
ResourceGroupName: 'some-rg-app-webjob'
Slot: staging
## Stop App Service (staging)
- task: AzureAppServiceManage@0
displayName: 'Stop Azure App Service: some-app-webjob (staging)'
inputs:
azureSubscription: 'xxx'
Action: 'Stop Azure App Service'
WebAppName: 'some-app-webjob'
SpecifySlotOrASE: true
ResourceGroupName: 'some-rg-app-webjob'
Slot: staging
Yuvama bakmaya gidersem, uygulama hizmeti durdurulur. Ama bazen workjob olmamalı süre çalışmasını sağlar. yana üretim ile takas sonra sürekli webjobs üst gereken bir görev var.
Velhasılı kelam bu olabilir :
- yuva evreleme çalışan sürekli webjob
- slot üretiminde sürekli webjob çalışması
Aradıktan sonra bu github iş parçacığını buldum https://github.com/projectkudu/kudu/issues/1886 Webjobs'un siteyi durdur komutundan etkilenmeyen scm sitesinde çalıştığını gösterir. Yine de, tüm sürekli web işlerini durduran bir görevim var.
Bunun olması için herhangi bir sebep var mı? Bunu nasıl önleyebiliriz? Dağıtımdan sonra eski kodla çalışan bir web işi istemiyorum.
WEBJOBS_STOPPED
evreleme yuvasına uygulanan mükemmel bir çözümdür. Değiştirilen web işini incelikle durduruyor mu?