docker

package
v0.7.8 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ClientOpts added in v0.7.7

func ClientOpts() ([]client.Opt, error)

ClientOpts returns an appropiate slice of client.Opt values for connecting to a Docker client. It can support using SSH connections via the Docker CLI's connection helpers if the DOCKER_HOST environment variable is an SSH url, otherwise it will return client.FromEnv for a standard connection. This function returns an error if DOCKER_HOST is an invalid URL.

func GetHostEnv

func GetHostEnv() string

func IsLocalDockerEngineHost added in v0.7.8

func IsLocalDockerEngineHost(dockerHost string) bool

Checks whether the DOCKER_HOST looks like a local Docker Engine. A local Docker Engine has some additional APIs for VM management (i.e., Docker Desktop).

func IsLocalHost

func IsLocalHost(dockerHost string) bool

Checks whether the Docker daemon is running on a local machine. Remote docker daemons will likely need a port forwarder to work properly.

Types

This section is empty.

Jump to

Keyboard shortcuts

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