mcr.microsoft.com/dotnet/core/sdk:2.2 .
它被卡住了 pip install --upgrade awscli ... 我想是因为 pip 皮普 我得到一个错误:
pip install --upgrade awscli
pip
皮普
Phase context status code: COMMAND_EXECUTION_ERROR Message: Error while executing command: apt-get install python3-dev. Reason: exit status 1
我的故障排除尝试包括:
Privileged
sudo
buildspec.yml
pip3
建筑规格yml :
建筑规格yml
version: 0.2 phases: pre_build: commands: - apt-get update --fix-missing - apt-get install -y apt-transport-https - apt-get update - apt-get install python3-dev - apt-get install python3-pip - pip3 install --upgrade awscli - dotnet restore AspNetCoreWebApplication/AspNetCoreWebApplication.csproj - dotnet restore AspNetCoreWebApplicationTest/AspNetCoreWebApplicationTest.csproj build: commands: .....the rest omitted for brevity......
我的问题是为什么这不起作用?
发现了问题。这些命令:
apt-get install python3-dev apt-get install python3-pip
需要包括 -y 自动对任何提示说是的标志 从命令中。
-y
添加这样的标志可以:
apt-get install -y python3-dev apt-get install -y python3-pip