Node.js Azure Function的Azure DevOps Pipeline随机失败求助
Node.js Azure Function部署随机失败问题
我用Node.js编写的Azure Function,对应的Azure DevOps Pipeline部署会随机失败,大概每5次部署就有3次失败,报错信息如下:
Deployment has been stopped due to SCM container restart. The restart can happen due to a management operation on site. Do not perform a management operation and a deployment operation in quick succession. Adding a small delay can help avoid any conflicts.
补充信息:
- 近期围绕报表生成用的Puppeteer做了代码修改,无法提供具体代码;
- Puppeteer版本为
"puppeteer": "^21.3.1"; - 当前Pipeline步骤如下:
steps: - task: PowerShell@2 inputs: targetType: 'inline' script: | New-Item -Path $(Build.SourcesDirectory)/.deployment -ItemType File '[config] SCM_DO_BUILD_DURING_DEPLOYMENT = true' | out-file -filepath $(Build.SourcesDirectory)/.deployment - task: ArchiveFiles@2 displayName: 'Zip source' inputs: rootFolderOrFile: '$(Build.SourcesDirectory)' includeRootFolder: false archiveType: 'zip' archiveFile: '$(Build.ArtifactStagingDirectory)/source.zip' replaceExistingArchive: true - task: PublishBuildArtifacts@1 displayName: 'Publish zip' inputs: PathtoPublish: '$(Build.ArtifactStagingDirectory)/source.zip' ArtifactName: 'report-source' publishLocation: 'Container'
已尝试的解决操作:
- 在Function App配置中添加
WEBSITES_CONTAINER_START_TIME_LIMIT:1800,无改善; - 在DevOps Release发布步骤前添加30秒等待任务,无改善。
内容的提问来源于stack exchange,提问作者Cata Hotea
相关产品推荐
相关产品推荐

