Kenfe-Mickaël Laventure 4c7160ed7b Merge pull request #26718 from ncdc/add-logs-to-container-attach-options
Add Logs to ContainerAttachOptions
2016-10-27 13:32:50 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-16 11:56:15 -07:00
2016-09-22 14:42:06 -04:00
2016-09-22 14:42:06 -04:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-19 11:19:55 -07:00
2016-09-07 11:05:58 -07:00
2016-10-25 06:43:54 +00:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-10-25 06:43:54 +00:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-10-24 15:20:01 -07:00
2016-10-24 15:20:01 -07:00
2016-10-10 09:27:07 +01:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00
2016-09-07 11:05:58 -07:00

Go client for the Docker Remote API

The docker command uses this package to communicate with the daemon. It can also be used by your own Go applications to do anything the command-line interface does  running containers, pulling images, managing swarms, etc.

For example, to list running containers (the equivalent of docker ps):

package main

import (
	"context"
	"fmt"

	"github.com/docker/docker/api/types"
	"github.com/docker/docker/client"
)

func main() {
	cli, err := client.NewEnvClient()
	if err != nil {
		panic(err)
	}

	containers, err := cli.ContainerList(context.Background(), types.ContainerListOptions{})
	if err != nil {
		panic(err)
	}

	for _, container := range containers {
		fmt.Printf("%s %s\n", container.ID[:10], container.Image)
	}
}

Full documentation is available on GoDoc.

Description
The Docker CLI
Readme Pixar 258 MiB
Languages
Go 91.4%
Shell 5.6%
Go-Checksums 1.3%
Dockerfile 1.2%
Makefile 0.3%
Other 0.2%