docker

package
v0.0.0-...-dae269f Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2023 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Docker

type Docker struct {
	component.Base
}

func (*Docker) APIClient

func (docker *Docker) APIClient() (DockerClient, error)

func (*Docker) Containers

func (docker *Docker) Containers(ctx context.Context, path string, services ...string) (containers []types.Container, err error)

Containers loads the compose project at path, connects to the docker daemon, and then lists all containers belonging to the given services. If services is empty, all containers belonging to any service are returned.

func (*Docker) CreateNetwork

func (docker *Docker) CreateNetwork(ctx context.Context, name string) (id string, exists bool, err error)

CreateNetwork creates a docker network with the given name unless it already exists. The new network will be of default type. exists indicates if the network already exists.

func (*Docker) Ping

func (docker *Docker) Ping(ctx context.Context) (types.Ping, error)

Ping pings the docker daemon to check if it is properly working

type DockerClient

type DockerClient = *client.Client

DockerClient is a client to the docker api

Jump to

Keyboard shortcuts

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