2017-02-27 59 views
0

我的码头工人的版本是搬运工构建让未经授权的:认证所需

Docker version 1.12.2-cs2-ws-beta, build 050b611 

我试图使用命令来构建图像

docker build -t iis-dockerfile . 

的DockerFile含量

FROM microsoft/iss 
RUN echo "Hello World - Dockerfile" > C:\inetpub\wwwroot\index.html 

配置。 json是

{ 
    "auths": { 
     "https://index.docker.io/v1/": { 
      "auth": <somekey> 
     } 
    } 
} 

在运行搬运工构建,它提供了错误

Sending build context to Docker daemon 2.048 kB 
Step 1/2 : FROM microsoft/iss 
unauthorized: authentication required 

我已经做过搬运工登录。这就是config.json的创建方式。我是容器的新手,并按照入门教程https://blogs.msdn.microsoft.com/allthingscontainer/2016/09/15/windows-containers-getting-started-a-step-by-step-guide/。任何想法我怎么能解决这个问题。

另外我想到码头牵引正在为我工​​作。虽然这也要求认证

+0

您的docker文件的权限是什么? –

+0

“FileSystemRights:FullControl”适用于所有管理员,用户,系统 – Jitendra

+0

http://stackoverflow.com/questions/36663742/docker-unauthorized-authentication-required-upon-push-with-successful-login https:// github。 com/docker/hub-feedback/issues/645 您是否检查了上述链接?他们陈述类似的问题。 –

回答

1

只是一个观察。确保您的docker文件具有正确的基本映像名称。您确定要FROM microsoft/iss而不是FROM microsoft/iis

当我试图用正确的基础图像创建新的图像。它似乎工作。

Docker docker build -t test-iid . 
Sending build context to Docker daemon 344.9 MB 
Step 1/2 : FROM microsoft/iis 
latest: Pulling from microsoft/iis 
3889bb8d808b: Downloading 
3430754e4d17: Downloading 
7aee39cd34f9: Downloading [>             ] 540 kB/122.7 MB 
5b8e6b632025: Download complete 
e067d71858d2: Download complete 
+1

简单的错字打死了我的一天。谢谢 – Jitendra