Using Docker API to pull from a private registry

What is the syntax to pull an image from a private registry?

I am trying to reproduce the below command with the API:

  • Docker swarm for usb devices
  • Docker command can't connect docker daemon using Hypriot Docker
  • docker-compose down - network is external, skipping
  • Could not find entity for dockerfile/elasticsearch
  • Fig support on Boot2Docker / Windows platform
  • Migrating a service from one docker container to another with zero downtime
  • docker pull localhost:5000/oillio/my_app:1.0-SNAPSHOT

    It looks like I am supposted to use the images/create call. There are 4 parameters, fromImage, fromSrc, repo, tag, and registry. I can’t for the life of me figure out how to set those parameters to reproduce the above command.

  • Docker on Windows Server 2016 & microsoft-build-tools
  • “Error: spawn mongoexport ENOENT” when running dockerized node app
  • Can't ping docker IPv6 container
  • Flask, Gunicorn, NGINX, Docker : What is properly the way to config SERVER_NAME and proxy_pass?
  • curl command for docker inspect
  • syntax error in wercker file when using wercker login command
  • One Solution collect form web for “Using Docker API to pull from a private registry”

    Something similar to this has worked for me:

    curl -X POST localhost:2375/images/create?fromImage=localhost:5000/oillio/my_app&tag=1.0-SNAPSHOT

    Where localhost:2375 is my private server

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.