docker

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 12, 2020 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultAddr = "http://localhost"

DefaultAddr is a default docker host and port which communicating with Docker deamon

Variables

View Source
var DefaultClient = &http.Client{
	Transport: &http.Transport{
		DialContext: func(_ context.Context, _, _ string) (net.Conn, error) {
			return net.Dial("unix", "/var/run/docker.sock")
		},
	},
}

DefaultClient is a default client which uses unix protocol

Functions

This section is empty.

Types

type Event

type Event struct {
	ID     string `json:"id"`
	Active bool   `json:"active"`
}

type Watcher

type Watcher struct {
	// contains filtered or unexported fields
}

func New

func New(client *http.Client, addr string) *Watcher

func (*Watcher) Container

func (w *Watcher) Container() *baker.Container

func (*Watcher) Start

func (w *Watcher) Start() error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL