Docker Community Forums

Share and learn in the Docker community.

Cannot Push an Image to a Private Repository on Docker Hub


(Imrankamaluddin) #1

OS Version = Windows 10 version 1709
OS Build = 16299.125
Docker Version = 17.12.0-ce-rc4-win44 (14896)

Here is my test Dockerfile:-:

Dockerfile to build Ubuntu image with SSH

Set base image

FROM ubuntu

Install OpenSSH Server

RUN apt-get update && apt-get install -y openssh-server
RUN mkdir /var/run/sshd
RUN echo ‘root:Docker!’ | chpasswd
RUN sed -i ‘s/PermitRootLogin prohibit-password/PermitRootLogin yes/’ /etc/ssh/sshd_config

SSH login fix. Otherwise user is kicked off after login

RUN sed ‘s@session\srequired\spam_loginuid.so@session optional pam_loginuid.so@g’ -i /etc/pam.d/sshd

ENV NOTVISIBLE "in users profile"
RUN echo “export VISIBLE=now” >> /etc/profile

EXPOSE 22
CMD ["/usr/sbin/sshd", “-D”]

Install Network Utils

RUN apt-get update
RUN apt-get install net-tools
RUN apt-get -y install dnsutils

Using the following command to build an image :-

     docker build -t <mydocker_Repository>:ubuntutest . 

and then to push the image to my private repository on Docker Hub:-

    docker push <mydocker_Repository>:ubuntutest 

When I try the above procedure, I consistently get the following error:-

“open \tmp\08749566094e421a6e77c6629fd157624086e80a03e8fa9e7200534c97b633f2-mount\etc\ld.so.cache: The system cannot find the path specified.”

When I try the same procedure above on Docker for Mac, it works as expected creating an image and pushing the image to my private repository. I can then pull the same image on to my Windows Laptop and execute it. It runs as expected.

Is this a known issue with the current Edge build for Docker for Windows as there seems to be a difference in functionality compared to Docker for Mac ?

Regards

Imran