从Docker生成运行时,dotnet nuget推送失败

从Docker生成运行时,dotnet nuget推送失败,nuget,dockerfile,dotnet-cli,Nuget,Dockerfile,Dotnet Cli,我正在尝试使用docker和dotnet cli为dotnet库设置CI管道 我正在运行docker构建语句-构建此dockerfile FROM microsoft/dotnet COPY . ~/dotnetapp WORKDIR ~/dotnetapp ARG NUGET_SOURCE ARG NUGET_API ARG BUILD_VERSION RUN dotnet restore ./lib1/lib1.csproj RUN dotnet pack ./lib1/lib1.csp

我正在尝试使用docker和dotnet cli为dotnet库设置CI管道

我正在运行docker构建语句-构建此dockerfile

FROM microsoft/dotnet
COPY . ~/dotnetapp
WORKDIR ~/dotnetapp
ARG NUGET_SOURCE
ARG NUGET_API
ARG BUILD_VERSION

RUN dotnet restore ./lib1/lib1.csproj 
RUN dotnet pack ./lib1/lib1.csproj -o ./packaged -c Release /p:Version=0.0.${BUILD_VERSION}
RUN dotnet nuget push ./lib1/packaged/*.nupkg -k ${NUGET_API} -s ${NUGET_SOURCE}
Restore和Pack命令按预期执行,但推送到nuget服务器失败

info : An error occurred while sending the request.
info :   Server returned nothing (no headers, no data) 
info :   PUT https://www.myget.org/x/xxxxxxxxx/api/v2/package/
info : An error was encountered when fetching 'PUT https://www.myget.org/x/xxxxxxxxx/api/v2/package/'. The request will now be re
试过了

我尝试过多个nuget存储库,以及各种风格的bas docker图像,但都没有用

我错过了什么魔法咒语