Unable to push docker image to Openshift Origin Docker registry

I was trying to deploy a docker image I have created via Openshift. I followed the instructions in: http://www.opensourcerers.org/importing-an-external-docker-image-into-red-hat-openshift-v3/

However, as I tried to push my docker image to the Openshift registry, it did not succeed, as shown below

  • docker compose, vagrant and insecure Repository
  • docker: command not found with Jenkins build and publish plugin on Mac
  • After installing docker on centos7,Failed to start docker.“Job for docker.service failed.”
  • Docker exposing ports madness
  • Problems with Dockerbeats dashboard containerName field
  • Docker with Microsoft SQL Server and .net desktop application
  • [root@mymachine ~]# docker push

    The push refers to a repository

    0a4a35d557a6: Preparing

    025eba1692ec: Preparing

    5332a889b228: Preparing

    e7b287e8074b: Waiting

    149636c85012: Waiting

    f96222d75c55: Waiting

    no basic auth credentials

    Following are the docker version and openshift versions:

    [root@mymachine ~]# docker –version

    Docker version 1.11.0, build 4dc5990

    [root@mymachine ~]# oc version

    oc v1.2.0

    kubernetes v1.2.0-36-g4a3f9c5

    Could someone help me out with this? Not sure what it means by “no basic auth credentials” since the openshift user and server user are root users with all privileges.

  • Where does docker-machine save the configuration on a remote Ubuntu host running systemd?
  • I can not remove a directory in a docker container
  • Jenkins pipeline docker.image call generates a timeout
  • Using docker-selenium to test internal host behind VPN
  • Error when run clickhouse docker image on mac os
  • Docker DNS issue on local machine
  • One Solution collect form web for “Unable to push docker image to Openshift Origin Docker registry”

    After performing oc login to authenticate on your cluster you have to go inside your default project

    $ oc project default

    Check the service ip of your registry:

    $ oc get svc
    NAME              CLUSTER-IP       EXTERNAL-IP   PORT(S)                   AGE
    docker-registry   172.30.xx.220   <none>        5000/TCP                  76d
    kubernetes       <none>        443/TCP,53/UDP,53/TCP     76d
    router            172.30.xx.xx     <none>        80/TCP,443/TCP,1936/TCP   76d

    Check your token:

    $ oc whoami -t

    Now you can authenticate on your registry:

    docker login -u test -e any@mail.com -p trSZhNVi8F_N3Pxxx 172.30.xx.220:5000
    WARNING: login credentials saved in /root/.docker/config.json
    Login Succeeded
    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.