1 個回答
- 最新
- 最多得票
- 最多評論
0
I found that this is caused by a behavior of CodeBuild when running on Windows. The behavior is that Codebuild invokes a brand new process for every line that starts with '-' in the buildspec.
This appears to be an undocumented defect in codebuild that was confirmed by an AWS support engineer.
Your updated buildspec would be:
version: 0.2
env:
shell: powershell.exe
phases:
build:
commands:
- |
Write-Host "env:Path before..."
Write-Host "$env:Path"
Write-Host "Installing required tools..."
Invoke-WebRequest -Uri https://win.rustup.rs/ -OutFile rustup-init.exe
./rustup-init.exe -y
Write-Host "env:Path after"
Write-Host "$env:Path"
cargo -V
已回答 1 個月前
相關內容
- AWS 官方已更新 1 年前