Questions tagged [docker-api]

Use this tag with the Docker Engine API.

Docker runs as a client-server accepting request via the Docker Engine API.

Image

189 questions
4
votes
1 answer

How to delete a docker image in dockerhub with a particular tag or set of tags using CLI?

I have docker images like this user/image:1.0 user/image:2.0 user/image:2.1 . . user/image:2.9 user/image:3.0 I want to delete images from user/image:2.1 to user/image:2.9 USING CLI by calling docker api. Basically I want to delete an image from…
srikanth peetha
  • 229
  • 1
  • 3
  • 17
4
votes
3 answers

Access docker remote API from container

I'm trying to access Docker remote API from within a container because I need to start other containers. The host address is 172.19.0.1, so I'm using http://172.19.0.1:2375/images/json to get the list of images (from host,…
fra
  • 3,488
  • 5
  • 38
  • 61
4
votes
1 answer

"404 page not found" when exec `curl --unix-socket /var/run/docker.sock http:/containers/json`

docker version: 1.11.2 curl version: 7.50.3 (x86_64-pc-linux-gnu) libcurl/7.50.3 OpenSSL/1.0.1e zlib/1.2.7 /usr/local/sbin/bin/curl --unix-socket /var/run/docker.sock http://images/json -v * Trying /var/run/docker.sock... * Connected to images…
workhardcc
  • 1,270
  • 3
  • 12
  • 21
4
votes
2 answers

Can't return list of docker repository images through API

Following the docs at https://docs.docker.com/v1.7/reference/api/docker-io_api/#list-library-repository-images I'm having some problems on returning the list if images to several repositories. Not sure if there's something missing, or is there any…
pedrorijo91
  • 7,635
  • 9
  • 44
  • 82
4
votes
1 answer

How to connect to an existing docker network with docker remote API (through dockerode)

I use docker-compose to create a "park" of container inter-linked. Nothing special here, I have API/Frontend/Backend etc.. There is my docker-compose.yml : version: "2" services: api: build: ./deimos_api/docker ports: …
Cyril ALFARO
  • 1,616
  • 17
  • 35
3
votes
1 answer

`docker system df` vs `/system/df` (docker api endpoint)

I am writing a program in Go to get the total disk usage in GB from my docker host machine. For that, I am using the func DiskUsage() from go lib: https://pkg.go.dev/github.com/docker/docker/client#Client.DiskUsage. Taking a look into the code,…
3
votes
0 answers

Cloning GIT repo for a stack doesnt copy over config files

Not sure if this should be happening, I have a docker compose file that uses several containers, two of these containers have configuration files (nginx being one of them) and are defined in the compose file. However when I use portainer with the…
Neo
  • 2,305
  • 4
  • 36
  • 70
3
votes
2 answers

Is there an HTTP api to access docker buildx in Docker 19.03?

I am playing around with Docker buildx to build some images for linux/arm/v7. However, I would like to do it programmatically. I know that there is an HTTP api to interact with the Docker daemon for standard functions, however the Docker docs do not…
PptSbzzgt
  • 351
  • 1
  • 3
  • 10
3
votes
0 answers

Docker Engine API - Connection reset by peer

I'm trying to make requests to the Docker API remotely. I have the docker engine running on virtual machine, and I'm making the requests from docker containers. Firstly, I've done this to make the Docker daemon listen on a specific IP and…
MLGonc
  • 99
  • 2
  • 12
3
votes
2 answers

Retrieve Docker image tags from a 3rd party repo

For Docker images that come straight from Docker Hub, I can retrieve the current list of tags for an image by hitting their repository API. For example, https://registry.hub.docker.com/v1/repositories/python/tags will give me a list of tags that can…
djsumdog
  • 2,560
  • 1
  • 29
  • 55
3
votes
1 answer

Push Private Image to Docker Registry via Docker API

I'm using the Docker SDK for Python to push a local image repository into a Docker Registry (DockerHub in my case.) I use the "push" method on "client.images" described on documentation here. Unfortunately all published repositories are public.…
CoderOfTheNight
  • 944
  • 2
  • 8
  • 21
3
votes
1 answer

How to use Docker api engine to exec cmd in container

How to use Docker api engine to exec command in container. I want to use the api docker to exec cmds in container via http calls
3
votes
3 answers

Error: connect ENOENT /var/run/docker.sock when using node-docker-api

I have been trying to call docker from my Node.js application, and to do so I am using node-docker-api as described in the npm module documentation https://github.com/AgustinCB/docker-api. To test if I am able to interact with docker from Node.js I…
abhi
  • 1,920
  • 6
  • 24
  • 27
3
votes
1 answer

Getting file context from mounted file with Go Docker API

I'm trying to get mounted file content using Go docker API: File secret.txt stores a line TOKEN=MY_TOKEN Code: cli, err := client.NewEnvClient() if err != nil { panic(err) } defer cli.Close() ctx := context.Background() _, err =…
creaturek
  • 75
  • 7
3
votes
4 answers

Docker - Enable Remote HTTP API with SystemD and "daemon.json"

Disclaimer: On a old machine with Ubuntu 14.04 with Upstart as init system I have enabled the HTTP API by defining DOCKER_OPTS on /etc/default/docker. It works. $ docker version Client: Version: 1.11.2 (...) Server: Version: 1.11.2 …
Paulo Oliveira
  • 2,411
  • 1
  • 31
  • 47
1
2
3
12 13