Documentation ¶
Index ¶
- Variables
- func AddContainerToNetwork(pool *dockertest.Pool, network *dockertest.Network, testContainer string) error
- func DockerAllowLocalIPv6(config *docker.HostConfig)
- func DockerAllowNetworkAdministration(config *docker.HostConfig)
- func DockerRestartPolicy(config *docker.HostConfig)
- func ExecuteCommand(resource *dockertest.Resource, cmd []string, env []string, ...) (string, string, error)
- func GetFirstOrCreateNetwork(pool *dockertest.Pool, name string) (*dockertest.Network, error)
- func IsRunningInContainer() bool
- func RandomFreeHostPort() (int, error)
- func SaveLog(pool *dockertest.Pool, resource *dockertest.Resource, basePath string) error
- type ExecuteCommandConfig
- type ExecuteCommandOption
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrDockertestCommandFailed = errors.New("dockertest command failed") ErrDockertestCommandTimeout = errors.New("dockertest command timed out") )
View Source
var ErrContainerNotFound = errors.New("container not found")
Functions ¶
func AddContainerToNetwork ¶
func DockerAllowLocalIPv6 ¶
func DockerAllowLocalIPv6(config *docker.HostConfig)
func DockerAllowNetworkAdministration ¶
func DockerAllowNetworkAdministration(config *docker.HostConfig)
func DockerRestartPolicy ¶
func DockerRestartPolicy(config *docker.HostConfig)
func ExecuteCommand ¶
func GetFirstOrCreateNetwork ¶
func IsRunningInContainer ¶
func IsRunningInContainer() bool
func RandomFreeHostPort ¶
RandomFreeHostPort asks the kernel for a free open port that is ready to use. (from https://github.com/phayes/freeport)
Types ¶
type ExecuteCommandConfig ¶
type ExecuteCommandConfig struct {
// contains filtered or unexported fields
}
type ExecuteCommandOption ¶
type ExecuteCommandOption func(*ExecuteCommandConfig) error
func ExecuteCommandTimeout ¶
func ExecuteCommandTimeout(timeout time.Duration) ExecuteCommandOption
Click to show internal directories.
Click to hide internal directories.