我的 Azure 管道开始失败。我的错误如下:
Node.js version v16.20.2 detected.
The Angular CLI requires a minimum Node.js version of v18.13.
我没有改变任何东西。这是我的管道的一部分:
pool:
vmImage: 'ubuntu-latest'
steps:
- task: NodeTool@0
inputs:
versionSpec: '16.x'
displayName: 'Install Node.js'
- script: |
sudo npm install -g @angular/cli
npm install
ng build -c=release --output-path=web/wwwroot
displayName: 'npm install and build'
两周前该脚本有效。
我的问题是,如何在Azure管道中修复它?我正在使用 Microsoft 托管代理
你可以尝试改变一下吗
来自
sudo npm install -g @angular/cli
至
sudo npm install -g @angular/cli npm@latest