go-dockerclient 0

Go HTTP client for the Docker remote API.

#go-dockerclient

Build Status Build Status

GoDoc

This package presents a client for the Docker remote API.

For more details, check the remote API documentation.

Example

package main

import (
        "fmt"
        "github.com/fsouza/go-dockerclient"
)

func main() {
        endpoint := "unix:///var/run/docker.sock"
        client, _ := docker.NewClient(endpoint)
        imgs, _ := client.ListImages(docker.ListImagesOptions{All: false})
        for _, img := range imgs {
                fmt.Println("ID: ", img.ID)
                fmt.Println("RepoTags: ", img.RepoTags)
                fmt.Println("Created: ", img.Created)
                fmt.Println("Size: ", img.Size)
                fmt.Println("VirtualSize: ", img.VirtualSize)
                fmt.Println("ParentId: ", img.ParentID)
        }
}

Developing

You can run the tests with:

go get -d ./...
go test ./...

Related Repositories

go-dockerclient

go-dockerclient

Go client for the Docker remote API. ...

dockerclient

dockerclient

Docker client library in Go ...

go-dockerclient

go-dockerclient

HTTP client for the Docker remote API. ...

coach

coach

Docker-Compose port to go, relying on fsouza/dockerclient ...

go-dockerclient-sort

go-dockerclient-sort

For sorting the results of Docker API calls made using https://github.com/fsouza/go-dockerclient ...


Top Contributors

fsouza andrewsmedina flaviamissi cezarsa gravis md5 cheneydeng benmccann jbdalido tarsisazevedo xh3b4sd fgrehm Sirupsen chuyeow aldrinleal mcuadros sweeney wiliamsouza kdomanski ncdc dqminh DavidHuie jwilder kidoman pmorie ekle artem-sidorenko blalor CMGS carlosdp